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

[Merged by Bors] - Refactor NIPostBuilder and activation.Builder for multiple identities. #5484

Closed
wants to merge 32 commits into from

Conversation

fasmat
Copy link
Member

@fasmat fasmat commented Jan 23, 2024

Motivation

This adds multi-smesher support to the activation package. Specifically to the activation.Builder and activation.NIPostBuilder services.

Description

Closes #5149

Requires API changes: spacemeshos/api#302

  • Extend NIPostBuilder to be able to create ATXs for different identities
  • Extend activation.Builder to handle multiple identities concurrently

Test Plan

  • new tests have been added to verify multi-smeshing works in the activation package

TODO

  • Explain motivation or link existing issue(s)
  • Test changes and document test plan
  • Update documentation as needed
  • Update changelog as needed

@fasmat fasmat self-assigned this Jan 23, 2024
Copy link

codecov bot commented Jan 23, 2024

Codecov Report

Attention: 39 lines in your changes are missing coverage. Please review.

Comparison is base (6510e12) 79.6% compared to head (512cd65) 79.6%.

Files Patch % Lines
activation/activation.go 68.5% 17 Missing and 11 partials ⚠️
timesync/clock.go 61.1% 7 Missing ⚠️
activation/nipost.go 88.4% 0 Missing and 3 partials ⚠️
signing/signer.go 83.3% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           develop   #5484   +/-   ##
=======================================
  Coverage     79.6%   79.6%           
=======================================
  Files          268     268           
  Lines        26707   26746   +39     
=======================================
+ Hits         21265   21312   +47     
+ Misses        3919    3915    -4     
+ Partials      1523    1519    -4     

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

@fasmat fasmat force-pushed the 5149-multi-smesher-activation branch 7 times, most recently from 38acb54 to 537e610 Compare January 30, 2024 09:03
@fasmat fasmat changed the title WiP: Refactor NIPostBuilder and activation.Builder for multiple identities. Refactor NIPostBuilder and activation.Builder for multiple identities. Jan 30, 2024
@fasmat fasmat marked this pull request as ready for review January 30, 2024 13:33
spacemesh-bors bot pushed a commit that referenced this pull request Jan 31, 2024
## Motivation

The ATX handler should not create malfeasance proofs against the node itself. In case we have a bug somewhere that would publish 2 ATXs in a single epoch fail validation, but do not mark yourself as malicious

Merge after #5484
@fasmat fasmat force-pushed the 5149-multi-smesher-activation branch from 3a76125 to e8c94ad Compare January 31, 2024 09:43
fasmat added a commit that referenced this pull request Jan 31, 2024
The ATX handler should not create malfeasance proofs against the node itself. In case we have a bug somewhere that would publish 2 ATXs in a single epoch fail validation, but do not mark yourself as malicious

Merge after #5484
@fasmat fasmat force-pushed the 5149-multi-smesher-activation branch from 4fe5ca3 to e866570 Compare January 31, 2024 10:21
fasmat added a commit that referenced this pull request Jan 31, 2024
The ATX handler should not create malfeasance proofs against the node itself. In case we have a bug somewhere that would publish 2 ATXs in a single epoch fail validation, but do not mark yourself as malicious

Merge after #5484
@fasmat fasmat force-pushed the 5149-multi-smesher-activation branch 3 times, most recently from 52ee95f to 0976695 Compare January 31, 2024 15:01
@fasmat fasmat force-pushed the 5149-multi-smesher-activation branch from eaf33d9 to cf39e02 Compare February 1, 2024 10:35
common/types/nodeid.go Outdated Show resolved Hide resolved
common/types/hashes.go Outdated Show resolved Hide resolved
common/types/hashes.go Outdated Show resolved Hide resolved
api/grpcserver/grpcserver_test.go Show resolved Hide resolved
activation/activation.go Outdated Show resolved Hide resolved
activation/post_test.go Outdated Show resolved Hide resolved
activation/activation_multi_test.go Show resolved Hide resolved
activation/activation_multi_test.go Outdated Show resolved Hide resolved
activation/activation_multi_test.go Show resolved Hide resolved
activation/handler_test.go Show resolved Hide resolved
activation/e2e/nipost_test.go Show resolved Hide resolved
@fasmat
Copy link
Member Author

fasmat commented Feb 2, 2024

bors merge

spacemesh-bors bot pushed a commit that referenced this pull request Feb 2, 2024
#5484)

## Motivation

<!-- Give a brief description of the motivation for this PR. 1-2 sentences is fine. -->
This adds multi-smesher support to the activation package. Specifically to the `activation.Builder` and `activation.NIPostBuilder` services.
@spacemesh-bors
Copy link

spacemesh-bors bot commented Feb 2, 2024

Pull request successfully merged into develop.

Build succeeded:

@spacemesh-bors spacemesh-bors bot changed the title Refactor NIPostBuilder and activation.Builder for multiple identities. [Merged by Bors] - Refactor NIPostBuilder and activation.Builder for multiple identities. Feb 2, 2024
@spacemesh-bors spacemesh-bors bot closed this Feb 2, 2024
@spacemesh-bors spacemesh-bors bot deleted the 5149-multi-smesher-activation branch February 2, 2024 18:56
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.

activation: support multiple smeshers
2 participants