-
Notifications
You must be signed in to change notification settings - Fork 457
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(remote): fallback to legacy snapcraft if under shallow git clone #4498
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #4498 +/- ##
==========================================
+ Coverage 89.18% 89.20% +0.01%
==========================================
Files 321 321
Lines 21727 21755 +28
==========================================
+ Hits 19378 19407 +29
+ Misses 2349 2348 -1 ☔ View full report in Codecov by Sentry. |
8a70c19
to
7d482c8
Compare
Git shallow clone is not pushable by design. Fallback to legacy remote build which has workaround. This only support core20 and core22. Any other bases and devel will report error.
7d482c8
to
4527498
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good start but there are a few code smells. The business logic in the flowchart had 4 checks and 2 outcomes (either running the new or legacy remote-build).
The code here is now out-of-order with the flowchart, introduces more checks, and adds more outcomes (raising exceptions within the business logic).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Just a minor comment about an emit and an error class.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Shallow git repos are not designed to be pushed, so the new remote-builder now raises an error for shallowly cloned repos. core20 and core22 projects in shallow clone repos fall back to the legacy remote-builder to retain compatibility.
Git shallow clone is not pushable by design. Fallback to legacy remote build which has workaround. This only support core20 and core22. Any other bases and devel will report error.