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

Fix/Placement sorting #480

Merged
merged 2 commits into from
Aug 1, 2023

Conversation

carpawell
Copy link
Member

Closes #438.

@carpawell carpawell marked this pull request as draft July 31, 2023 14:27
@carpawell
Copy link
Member Author

carpawell commented Jul 31, 2023

Fixed the tests, see the last commit.

@carpawell carpawell marked this pull request as ready for review July 31, 2023 15:54
@carpawell carpawell marked this pull request as draft July 31, 2023 15:56
@carpawell
Copy link
Member Author

Woops, wrong push.

Do not return next element if `0` is being facing. Also, add a public key to
the test nodes. It is used in `Hash()` method and, therefore, is the main
start point in the HWR sorting, without it, every node is considered the
same, so it is hard to pick a good test value, cause sorting is random for
the same hashes.
Closes nspcc-dev#438.

Signed-off-by: Pavel Karpy <[email protected]>
@carpawell carpawell marked this pull request as ready for review July 31, 2023 16:43
@roman-khimov roman-khimov merged commit e3b3936 into nspcc-dev:master Aug 1, 2023
5 checks passed
@carpawell carpawell deleted the fix/placement-sorting branch August 1, 2023 10:16
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.

Placement functions are buggy
3 participants