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

Accelerated regtest support #100

Merged
merged 1 commit into from
Aug 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Accelerated regtest support
  • Loading branch information
lazynina committed Jul 31, 2024
commit bb2a7462b5ebcd405e58564b214c26ca7e1d29cc
2 changes: 1 addition & 1 deletion cmd/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ to quickly create a Cobra application.`,
// DeserializeBlockNode.
// Check for regtest mode
if config.Regtest {
config.Params.EnableRegtest()
config.Params.EnableRegtest(config.RegtestAccelerated)
}
lib.GlobalDeSoParams = *config.Params

Expand Down
2 changes: 2 additions & 0 deletions deso/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ type Config struct {
BlockProducerSeed string
PosValidatorSeed string
Regtest bool
RegtestAccelerated bool
ConnectIPs []string
HyperSync bool
SyncType lib.NodeSyncType
Expand Down Expand Up @@ -77,6 +78,7 @@ func LoadConfig() (*Config, error) {
result.BlockProducerSeed = viper.GetString("block-producer-seed")
result.PosValidatorSeed = viper.GetString("pos-validator-seed")
result.Regtest = viper.GetBool("regtest")
result.RegtestAccelerated = viper.GetBool("regtest-accelerated")
result.ConnectIPs = viper.GetStringSlice("connect-ips")

result.HyperSync = viper.GetBool("hypersync")
Expand Down
2 changes: 1 addition & 1 deletion deso/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ func (node *Node) Start(exitChannels ...*chan os.Signal) {
go node.listenToRestart()

if node.Config.Regtest {
node.Params.EnableRegtest()
node.Params.EnableRegtest(node.Config.RegtestAccelerated)
}
lib.GlobalDeSoParams = *node.Params

Expand Down