Repository navigation
Fix false missing-artifact warning after build-output publication - #7238
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Redis fallback artifact producer src/ModularPipelines.Build/Helpers/BuildOutputSharing.cs, src/ModularPipelines.Build/Modules/BuildSolutionsModule.cs, src/ModularPipelines.Build/Modules/PublishRedisBuildOutputModule.cs, test/ModularPipelines.Build.UnitTests/BuildOutputPublicationTests.cs, test/ModularPipelines.UnitTests/Build/BuildOutputSharingTests.cs |
BuildOutputSharing exposes whether Redis fallback applies. PublishRedisBuildOutputModule declares the build-output artifact, while BuildSolutionsModule no longer does. Tests cover producer selection, artifact ownership, publication counts, and missing-output diagnostics. |
Worker dependency and pipeline registration src/ModularPipelines.Build/Modules/UnitTests/RunUnitTestModule.cs, src/ModularPipelines.Build/Program.cs, test/ModularPipelines.Build.UnitTests/BuildOutputPublicationTests.cs |
The pipeline registers the Redis publication module. Workers add an optional dependency on it and restore using its module ID. Tests check the producer and worker dependency declarations. |
Priority:
Estimated code review effort: 3 (Moderate) | ~20 minutes
Change: Bug fix · Severity of issue fixed: Low
Possibly related issues
- CI: successful GitHub build-output publication emits a false missing-artifact warning — the changes move the artifact declaration to the Redis fallback producer and add logger coverage for transport and fallback lifecycle cases.
Merge Risk: 
Minimal · up to 018ca
-
No actionable merge-blocking risk remains in the reviewed publication and worker paths; the change is ready for normal checks.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passed-
Full details: Title check
-
Explanation
The title names the main change: it fixes a false missing-artifact warning that appeared after build-output publication. The changeset adds a dedicated Redis build-output producer that runs only for distributed fallback, removes the artifact declaration from BuildSolutionsModule, and adds tests for the warning and artifact lifecycle. The title is specific and matches the linked issue objective.
Full details: Linked Issues check
-
Explanation
Issue
#7237coding requirements are met.BuildSolutionsModuleno longer declares the archive.PublishRedisBuildOutputModuledeclares it only for Linux distributed Redis fallback runs and depends onBuildSolutionsModule. Workers retain the required build dependency and add an optional dependency on the Redis producer. The lifecycle tests useRecordingLoggerand verify no warning after external publication, one external upload, no Redis upload, Redis reference/download behavior, and the warning and failure for a genuinely missing required output. The run-condition tests cover transport and instance-count cases.
Full details: Out of Scope Changes check
-
Explanation
The changes remain within issue
#7237scope. Source changes coordinate build-output publication, artifact declaration, producer conditions, and worker dependencies. Tests cover the required publication and lifecycle behavior. The change does not globally suppress missing-artifact diagnostics or execute the full build pipeline.
-
-
Finishing Touches: 💡 1
-
📝 Generate docstrings: 💡
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
A rabbit checks the build-output trail,
The Redis path now has its own detail.
When transport takes the archive away,
No false missing warning joins the day.
Workers wait for fallback when required,
And tests keep each path verified.
Comment @coderabbitai help to get the list of available commands.
There was a problem hiding this comment.
Claude Review
The PR moves the Redis-fallback build-output artifact upload off BuildSolutionsModule and onto a new PublishRedisBuildOutputModule. That module depends on BuildSolutionsModule and runs only on Linux, with the ci-master capability, and only when distributed runs have no external transport. RunUnitTestModule now optionally depends on the new module and restores from its artifact. I checked the diff and the current BuildOutputSharing source. I found no actionable defects. I could not run the tests.
Review evidence
src/ModularPipelines.Build/Modules/PublishRedisBuildOutputModule.cs: The new producer module depends on BuildSolutionsModule and carries the ProducesArtifact attribute. It is gated by the UsesRedisBuildOutput run condition, which returns IsEnabled && transport is null. The condition is marked IPlanningSafe, and the body is a no-op.
src/ModularPipelines.Build/Helpers/BuildOutputSharing.cs: UsesRedisFallback is consistent with PublishAsync: with no transport it does nothing, and with a transport it publishes and deletes the local archive. RestoreAsync still downloads from the producer module id that the caller passes in, so the caller must pass the new module's id.
src/ModularPipelines.Build/Modules/UnitTests/RunUnitTestModule.cs: The optional DependsOn on PublishRedisBuildOutputModule makes workers wait for the Redis upload when that module runs. When the module is skipped, the dependency is optional, so workers are not blocked. RestoreAsync now uses the new module's id, which matches the module that owns the artifact.
test/ModularPipelines.Build.UnitTests/BuildOutputPublicationTests.cs: The tests cover the run-condition matrix of instance count and transport, and that only the new module declares the artifact. They also check the dependency attributes. They are reflection-based, so they do not exercise a real pipeline run.
src/ModularPipelines.Build/Modules/BuildSolutionsModule.cs: The ProducesArtifact attribute is removed, so the external-transport path no longer triggers a spurious missing-artifact warning or failure after the archive is deleted.
No actionable findings.
Optional follow-up notes
PublishRedisBuildOutputModule.ExecuteAsync is a no-op. The framework uploads the artifact only because of the attribute, so the design relies on the ProducesArtifact lifecycle running after a module with an empty body. The tests cover the attributes but not that end-to-end behavior, so a pipeline-level test or a CI run on a multi-instance Redis setup would be a useful follow-up.
UsesRedisBuildOutput resolves BuildOutputSharing through GetRequiredService. This assumes the service is registered in every pipeline configuration, including planning. The tests mock the context, so they do not confirm the registration.
[Medium impact] The PR appears safe to merge; no actionable issues were found. SummaryMoves the Redis artifact declaration from
No actionable issues were found. Tests were not run during this review.
|
|
Reviewed head Disposition of optional Claude notes: an additional pipeline-level Redis test is non-blocking here. CodeRabbit's optional docstring suggestion is non-blocking wording work for internal build tooling and tests; declining it for this focused diagnostic fix. All applicable CI checks and the reviews completed on the current head, including the distributed full pipeline. |
Successful external build-output publication deletes the local archive, but
BuildSolutionsModulestill declared it as an artifact, causing a false missing-output warning.Move the Redis artifact declaration to a dedicated producer that runs only for distributed builds without an external transport. Test workers wait for that optional producer and restore its accepted artifact reference; their required build dependency remains in place. External publication still uploads once and deletes its archive.
Validation:
Closes #7237
Summary by CodeRabbit