-
Notifications
You must be signed in to change notification settings - Fork 278
sync: coreth PR #963,981,1009: sync package extension and related items #1679
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
base: master
Are you sure you want to change the base?
Conversation
| MetadataDB: vm.metadataDB, | ||
| Acceptor: vm, | ||
| Parser: vm.extensionConfig.SyncableParser, | ||
| Extender: nil, |
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.
Signed-off-by: Jonathan Oppenheimer <[email protected]>
alarso16
left a comment
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.
This PR is kinda big, and really seems like two different ideas (block extension, sync extensions). I would feel more confident if it was split up, but it might not be worth the effort at this size.
Gotcha - I can split it up further but thought the extension stuff in general could be a single PR. If you think it's worth the effort I will, otherwise will let be! |
Co-authored-by: Austin Larson <[email protected]> Signed-off-by: Jonathan Oppenheimer <[email protected]>
Co-authored-by: Austin Larson <[email protected]> Signed-off-by: Jonathan Oppenheimer <[email protected]>
Co-authored-by: Austin Larson <[email protected]> Signed-off-by: Jonathan Oppenheimer <[email protected]>
ceyonur
left a comment
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.
I was in the middle of reviewing but it seems this has some invalid and unrelated changes. It also is too big and it reverts some of previous PRs.
Can we focus on each of these sync PRs one-by-one maybe not mechanically but conceptually. A directy cherry-pick could be end up with massive conflicts.
Signed-off-by: Jonathan Oppenheimer <[email protected]>
This has been broken up significantly with 3 other PRs eating into this -- is this focused enough now? |
| func (vm *VM) Connected(ctx context.Context, nodeID ids.NodeID, version *version.Application) error { | ||
| vm.vmLock.Lock() | ||
| defer vm.vmLock.Unlock() | ||
|
|
||
| if err := vm.uptimeTracker.Connect(nodeID); err != nil { | ||
| return fmt.Errorf("uptime tracker failed to connect node %s: %w", nodeID, err) | ||
| } | ||
|
|
||
| return vm.Network.Connected(ctx, nodeID, version) | ||
| } | ||
|
|
||
| func (vm *VM) Disconnected(ctx context.Context, nodeID ids.NodeID) error { | ||
| vm.vmLock.Lock() | ||
| defer vm.vmLock.Unlock() | ||
|
|
||
| if err := vm.uptimeTracker.Disconnect(nodeID); err != nil { | ||
| return fmt.Errorf("uptime tracker failed to disconnect node %s: %w", nodeID, err) | ||
| } | ||
|
|
||
| return vm.Network.Disconnected(ctx, nodeID) | ||
| } |
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.
these should not be deleted
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.
Why? They were deleted from coreth and they are never used anywhere

This PR syncs:
Tthis PR brings in a lot of changes that aren't particular useful for subnet-evm, like the extender. This is intended, as I am trying to minimize the difference between coreth's version of these files, and subnet-evms. The eventual goal is the complete merger of all of these files, which is why I am making these changes now.
This PR introduces practically 0 "originally written by me code" - this is a culmination of the code of many other people (and in effect, has already been reviewed)
Also syncs this PR: ava-labs/coreth#1338 as surfaced by @alarso16