You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Let PHLEX_REGISTER_SOURCE plugins see the job's stage #957
Sources registered with PHLEX_REGISTER_SOURCE build their own provider_bundles, and each provider_bundle carries a stage string. The plugin has no way to learn the stage configured for the job. source_graph_proxy is built from graph_registration_bundle::stage, but it only exposes add_source. Also, unlike provide() (registration_api.hpp), the bundles a source returns don't get "CURRENT" replaced with the job's stage.
So in aegir every generator source block repeats the stage from the top-level config:
The plugin reads that key, and we reject "CURRENT" because it would end up as a literal stage name. When the two values differ, for example after phlex --stage foo, the generator products are labelled simulation and everything downstream is labelled foo.
Either of these would let us drop the duplicated key:
a stage() accessor on source_graph_proxy, or
replacing "CURRENT" in the stage of the bundles a source returns, the way provide() already does.
#923 fixed the same gap for PHLEX_REGISTER_PROVIDERS providers.
Activity
beojan commentedon Oct 26, 2026
Hi Oliver,
Would it be possible for you to implement these providers as explicit providers using
PHLEX_REGISTER_PROVIDERS?Sources generate implicit providers, which are really more suitable for reading in products produced in a previous stage.
olantwin commentedon Oct 27, 2026
Yes, that should be possible. I'll give it a try.
I guess I'm still wrapping my head around when it's best to use providers and when it's best to use sources.