-
Notifications
You must be signed in to change notification settings - Fork 250
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: populate default values for contract_metadata #1249
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1249 +/- ##
=======================================
Coverage 80.07% 80.07%
=======================================
Files 102 102
Lines 14598 14598
=======================================
Hits 11690 11690
Misses 2908 2908 ☔ View full report in Codecov by Sentry. |
/compare |
Contract size reportSizes are given in bytes.
|
Hey, first of all, thanks for the contribution. Please provide example to see how it helps. It would be nice to have a test repo with test contract to make review faster |
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.
@frol, judging from Shitzu-Apes/validator-rewards#2, logic has to be changed to such, that if std::env::var("NEP330_LINK")
is set, then it should override value from darling
. For such cases, when a legacy contract is updated with a link
attribute lingering somewhere in src/lib.rs
, forgotten or not. What do you think?
@mitinarseny can you add a unit test, demonstrating how parsing changes prior and after the change? It appears that both with |
Add
#[darling(default)]
attribute forlink
andversion
to make it possible to derive them from env:As current implementation returns an error: