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

refactor(settings): change wallets and reward lock to use injected settings #1148

Merged
merged 1 commit into from
Oct 17, 2024

Conversation

glevco
Copy link
Contributor

@glevco glevco commented Oct 8, 2024

Depends on #1146

Motivation

Remove global settings from reward lock and test wallets. This will be useful for Feature Activation for Transaction tests.

Acceptance Criteria

  • Move HathorSettings.HATHOR_TOKEN_UID to a constant.
  • Change reward lock functions to use injected settings.
  • Change test wallets to use injected settings.

Checklist

  • If you are requesting a merge into master, confirm this code is production-ready and can be included in future releases as soon as it gets merged

Copy link

codecov bot commented Oct 8, 2024

Codecov Report

Attention: Patch coverage is 95.83333% with 1 line in your changes missing coverage. Please review.

Project coverage is 84.38%. Comparing base (349555f) to head (391c9f0).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
hathor/manager.py 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1148      +/-   ##
==========================================
- Coverage   84.45%   84.38%   -0.07%     
==========================================
  Files         317      317              
  Lines       24365    24368       +3     
  Branches     3708     3708              
==========================================
- Hits        20577    20563      -14     
- Misses       3076     3086      +10     
- Partials      712      719       +7     

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

@glevco glevco marked this pull request as ready for review October 8, 2024 19:32
msbrogli
msbrogli previously approved these changes Oct 10, 2024
hathor/conf/settings.py Show resolved Hide resolved
@glevco glevco force-pushed the refactor/static-metadata/undo-feature-states branch 2 times, most recently from b1d9f54 to f179ea7 Compare October 10, 2024 19:45
@glevco glevco force-pushed the refactor/settings/wallets-and-reward-lock branch from 5d41130 to 5b442d6 Compare October 10, 2024 22:23
jansegre
jansegre previously approved these changes Oct 11, 2024
@glevco glevco force-pushed the refactor/static-metadata/undo-feature-states branch from f179ea7 to b8584e2 Compare October 11, 2024 16:49
@glevco glevco force-pushed the refactor/settings/wallets-and-reward-lock branch from 5b442d6 to b8c3f63 Compare October 11, 2024 16:53
@glevco glevco force-pushed the refactor/static-metadata/undo-feature-states branch from b8584e2 to 2d27cd1 Compare October 11, 2024 16:53
@glevco glevco force-pushed the refactor/settings/wallets-and-reward-lock branch from b8c3f63 to 7048b1d Compare October 11, 2024 16:54
Base automatically changed from refactor/static-metadata/undo-feature-states to master October 14, 2024 03:37
@glevco glevco dismissed stale reviews from jansegre and msbrogli October 14, 2024 03:37

The base branch was changed.

@glevco glevco force-pushed the refactor/settings/wallets-and-reward-lock branch from 7048b1d to 82f8e5d Compare October 14, 2024 03:43
Copy link

github-actions bot commented Oct 14, 2024

🐰 Bencher Report

Branchrefactor/settings/wallets-and-reward-lock
Testbedubuntu-22.04
Click to view all benchmark results
BenchmarkLatencyBenchmark Result
nanoseconds (ns)
(Result Δ%)
Lower Boundary
nanoseconds (ns)
(Limit %)
Upper Boundary
nanoseconds (ns)
(Limit %)
sync-v2 (up to 20000 blocks)📈 view plot
🚷 view threshold
101,435,075,123.16
(-0.44%)
91,692,692,801.72
(90.40%)
112,068,846,757.65
(90.51%)
🐰 View full continuous benchmarking report in Bencher

@glevco glevco force-pushed the refactor/settings/wallets-and-reward-lock branch from 82f8e5d to 391c9f0 Compare October 17, 2024 13:49
@glevco glevco merged commit 026cb7b into master Oct 17, 2024
13 checks passed
@glevco glevco deleted the refactor/settings/wallets-and-reward-lock branch October 17, 2024 17:56
@jansegre jansegre mentioned this pull request Nov 21, 2024
2 tasks
@jansegre jansegre mentioned this pull request Dec 11, 2024
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants