Skip to content

Comments

make URI,StakingAddress to be empty when reading a tmpnet after a kill -9 of the processes#2741

Merged
felipemadero merged 2 commits intomainfrom
fix-tmpnet-process-check
Apr 16, 2025
Merged

make URI,StakingAddress to be empty when reading a tmpnet after a kill -9 of the processes#2741
felipemadero merged 2 commits intomainfrom
fix-tmpnet-process-check

Conversation

@felipemadero
Copy link
Collaborator

@felipemadero felipemadero commented Apr 15, 2025

Why this should be merged

Closes #2738

pkg/localnet/tmpnet.go currently assumes that when reading a tmpnet, the node fields URI, StakingAddress
will be empty if the associated nodes are not up. This is found to not be true after killing the processes with
SIGKILL.
This PR fixes this issue by adding code to fix the network metadata based on process state

How this works

How this was tested

Two cases.

Trying to stop a network with killed nodes was failling (Ref #2738)

network start
killall -9 avalanchego
network stop

Truing to start a network with killed nodes was failling

network start
killall -9 avalanchego
network start
  • CI

How is this documented

@github-project-automation github-project-automation bot moved this from Backlog 🗄️ to In Review 👀 in avalanchego Apr 15, 2025
@felipemadero felipemadero merged commit 6179c8e into main Apr 16, 2025
37 checks passed
@github-project-automation github-project-automation bot moved this from In Review 👀 to Done ✅ in avalanchego Apr 16, 2025
@felipemadero felipemadero deleted the fix-tmpnet-process-check branch April 16, 2025 17:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

[Bug]: The local subnet configuration was not saved after restarting

2 participants