Skip to content
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

o/snapstate, o/hookstate: run component remove hooks #14539

Merged
merged 7 commits into from
Sep 30, 2024

Conversation

andrewphelpsj
Copy link
Member

This change lets us run component remove hooks.

Snap: snap,
Component: component,
Hook: "remove",
Optional: true,
Copy link
Collaborator

Choose a reason for hiding this comment

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

what's the IgnoreError setting on the snap remove hooks, we should be consistent?

Copy link
Collaborator

@pedronis pedronis left a comment

Choose a reason for hiding this comment

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

thank you

@pedronis pedronis added this to the 2.66 milestone Sep 30, 2024
Copy link

codecov bot commented Sep 30, 2024

Codecov Report

Attention: Patch coverage is 59.45946% with 15 lines in your changes missing coverage. Please review.

Project coverage is 78.86%. Comparing base (ac897ee) to head (43ab9ae).
Report is 43 commits behind head on master.

Files with missing lines Patch % Lines
overlord/hookstate/hooks.go 7.14% 13 Missing ⚠️
overlord/snapstate/snapstate.go 80.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #14539      +/-   ##
==========================================
+ Coverage   78.85%   78.86%   +0.01%     
==========================================
  Files        1079     1082       +3     
  Lines      145615   145961     +346     
==========================================
+ Hits       114828   115118     +290     
- Misses      23601    23648      +47     
- Partials     7186     7195       +9     
Flag Coverage Δ
unittests 78.86% <59.45%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

Copy link
Member

@alfonsosanchezbeato alfonsosanchezbeato left a comment

Choose a reason for hiding this comment

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

LGTM, thanks

Comment on lines 18 to 20
if snap list test-snap-component-hooks; then
snap remove test-snap-component-hooks || true
fi

Choose a reason for hiding this comment

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

nitpick^2: I would go for just snap remove test-snap-component-hooks || true

@andrewphelpsj andrewphelpsj merged commit 2e09611 into canonical:master Sep 30, 2024
54 of 56 checks passed
@andrewphelpsj andrewphelpsj deleted the remove-component-hooks branch September 30, 2024 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants