-
Notifications
You must be signed in to change notification settings - Fork 375
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(gno.land): refine error message for addpkg operation #2409
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2409 +/- ##
==========================================
+ Coverage 60.21% 60.23% +0.01%
==========================================
Files 561 561
Lines 75071 75074 +3
==========================================
+ Hits 45205 45218 +13
+ Misses 26485 26480 -5
+ Partials 3381 3376 -5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
What are the cases where addpkg
can fail? I'm wondering if there are other cases, such as an empty file (I guess it's caught by msg.Package.Validate()
), or other cases? What if we have two files with identical names in the same package?
Just running thoughts, we should clearly define the failure cases and improve more of these errors. It might be out of scope for this PR, but it would be great to have an analysis of this. Approving.
This PR introduces
PkgExistError
to replaceInvalidPkgPathError
for situations where a package already exists during theaddpkg
operation, enhancing clarity and specificity.