Skip to content

Conversation

@amanycodes
Copy link
Contributor

@amanycodes amanycodes commented Aug 27, 2025

The package manager shell commands now always exit with code 0. A marker file is now created within the build context only if upgradable packages are detected. That is read and if no upgradable packages found the sentinel error propagates to patchSingleArchImage and it catches this error and logs the user that the package is not upgradable (in summary table if multi-arch setting).

Attempt to close #1223

@codecov
Copy link

codecov bot commented Aug 27, 2025

Codecov Report

❌ Patch coverage is 32.98969% with 65 lines in your changes missing coverage. Please review.
✅ Project coverage is 39.31%. Comparing base (4bee93a) to head (4c94764).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
pkg/pkgmgr/dpkg.go 17.85% 22 Missing and 1 partial ⚠️
pkg/patch/multi.go 10.00% 16 Missing and 2 partials ⚠️
pkg/patch/single.go 0.00% 11 Missing and 1 partial ⚠️
pkg/pkgmgr/rpm.go 70.00% 5 Missing and 4 partials ⚠️
pkg/pkgmgr/apk.go 57.14% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1274      +/-   ##
==========================================
- Coverage   39.49%   39.31%   -0.19%     
==========================================
  Files          42       42              
  Lines        5879     5927      +48     
==========================================
+ Hits         2322     2330       +8     
- Misses       3361     3396      +35     
- Partials      196      201       +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@amanycodes amanycodes marked this pull request as ready for review August 27, 2025 21:26
@amanycodes
Copy link
Contributor Author

@ashnamehrotra @robert-cronin I think the pipeline looks fine. The sentinel error is being outputted but the build is still failing when no upgradable packages are present, even though now the shell give exit code 0. I'm confused as to whether I'm not catching the sentinel error at the correct point in the control flow? Would love to have some eyes on this, Thanks!

@ashnamehrotra
Copy link
Contributor

@amanycodes can we add a CI test for this?

We still want the error on the copa side which is correct, since we do not want to create a "patched" tag when the image is unchanged. We just want to have the exit code changed to "0" so that when copa is running in a pipeline it wouldnt cause a CI failure. Does that make sense?

@ashnamehrotra
Copy link
Contributor

@amanycodes are you still working on this?

@amanycodes
Copy link
Contributor Author

Hi @ashnamehrotra , I'm back from midsems, and have started working on it.

Signed-off-by: amanycodes <amanycodes@gmail.com>
@amanycodes amanycodes reopened this Oct 1, 2025
amanycodes and others added 3 commits October 1, 2025 23:37
Signed-off-by: amanycodes <amanycodes@gmail.com>
Signed-off-by: amanycodes <amanycodes@gmail.com>
@robert-cronin robert-cronin moved this from ✅ Done to 👀 In review in Copacetic Workboard Oct 6, 2025
@robert-cronin robert-cronin modified the milestones: v0.12.0, v0.13.0 Oct 6, 2025
Copy link
Contributor

@ashnamehrotra ashnamehrotra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM after rebase

Signed-off-by: Aman <95525722+amanycodes@users.noreply.github.com>
@sozercan
Copy link
Member

sozercan commented Oct 22, 2025

@amanycodes looks like there are some test failures, can you ptal?

@ashnamehrotra ashnamehrotra merged commit 0c86ad6 into project-copacetic:main Oct 29, 2025
36 of 37 checks passed
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Copacetic Workboard Oct 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[REQ] Fix Error Output for no packages to update

4 participants