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

Alter SimpleBoxSelector algo to sort inputs by target tokens; #175

Merged
merged 2 commits into from
Jan 19, 2021

Conversation

greenhat
Copy link
Member

@greenhat greenhat commented Jan 19, 2021

Close #174

Summary

  • Sort inputs by target tokens amount, putting inputs with largets target tokens first.
  • While going through sorted inputs having only target tokens missing skip the input if it does not have any of the target tokens.

@coveralls
Copy link

coveralls commented Jan 19, 2021

Pull Request Test Coverage Report for Build 496425880

  • 57 of 62 (91.94%) changed or added relevant lines in 1 file are covered.
  • 2 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.04%) to 84.434%

Changes Missing Coverage Covered Lines Changed/Added Lines %
ergo-lib/src/wallet/box_selector/simple.rs 57 62 91.94%
Files with Coverage Reduction New Missed Lines %
ergo-lib/src/types/scontext.rs 1 93.33%
ergo-lib/src/wallet/box_selector/simple.rs 1 95.9%
Totals Coverage Status
Change from base Build 493074853: -0.04%
Covered Lines: 3477
Relevant Lines: 4118

💛 - Coveralls

@greenhat greenhat merged commit 49c9d0d into develop Jan 19, 2021
@greenhat greenhat deleted the i174-improve-box-selector branch January 19, 2021 16:26
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.

Improve box selector behaviour when selecting token(s)
3 participants