Repository navigation
Conversation
Open Climate Service's aggregate_to_dhis2_json workflow no longer takes data_element_id and period_type (dhis2/open-climate-service f548922). It takes a named export from the instance config, which owns the data element mapping and the period type. The step now passes that export instead. BREAKING CHANGE: climate-openeo-create's config replaces variable.dataElement with exportId, the id of an export under exports in the OCS instance config.
A named DHIS2 export is saved as export-<id>.json beside a manifest, so the hardcoded result.json is a 404. Take the file name from the job's result asset, or its first data asset.
A scheduled pipeline has a fixed config, so a fixed period id fetches the same dates on every run. With lastDays and no id, the step covers the lastDays days up to and including yesterday (UTC), worked out when it runs. An id still takes precedence, so a manual run can override a rolling config through its context.
Allen7702
added a commit
that referenced
this pull request
Oct 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This is only an idea for how to make scheduled climate pipelines work, from setting CAPS up on our climate-demo server. We may well have misunderstood how pipelines are meant to get their periods, so please treat it as a question as much as a change.
What we ran into:
climate-openeo-createtakes a fixedperiod(id/endId). For a pipeline on a weekly schedule we could not find anything that moves that window forward (the scheduler'sinputContextis static, and the step does not read theopen-climate-service-syncoutput), so every run would fetch the same dates.prediction-triggerhasperiodOffsetfor this; the climate step has nothing similar.The idea: let the period carry
lastDaysinstead ofid. Without anid, the step covers thelastDaysdays up to and including yesterday (UTC), worked out when it runs. A window wider than a week (we use 35, and 70 for CHIRPS, which publishes about a month late) also picks up late and revised source data, and re-uploading overlapping days is harmless withCREATE_AND_UPDATE. Anidstill takes precedence, so a manual run can override a rolling config through its context, which we used for a year-by-year backfill.Builds on #8 (its first two commits are #8's); only the last commit is new here.
Type of change
feat— new capability (minor)fix— bug fix (patch)docs— documentation onlyrefactor/chore/ci/testfeat!/BREAKING CHANGE:in the commit)How to verify
bunx --bun vitest run src/tests/unit(370 passed);tsc --noEmit,eslint,prettier --checkcleanclimateOpenEoConfig.test.ts:lastDaysalone is valid, neitheridnorlastDaysis invalid,lastDays: 35on 2026-10-09 gives 2026-09-04..2026-10-08, andidwins overlastDays.lastDays, analytics, chap prediction).Checklist
main)bun run lintandbun run typecheckpass locallybun run test/make test).env, or production credentials in the diff