From 23ba504c7eb783690c1f0fb7bd47d707f4bae731 Mon Sep 17 00:00:00 2001 From: sideninja <75445744+sideninja@users.noreply.github.com> Date: Wed, 1 May 2024 00:14:39 +0200 Subject: [PATCH] fix changes in api --- internal/migrate/staging_validator.go | 6 +++--- internal/migrate/state.go | 12 ++++-------- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/internal/migrate/staging_validator.go b/internal/migrate/staging_validator.go index ba4d1c9e6..dac94e35b 100644 --- a/internal/migrate/staging_validator.go +++ b/internal/migrate/staging_validator.go @@ -23,8 +23,6 @@ import ( "fmt" "strings" - "github.com/onflow/flow-cli/internal/util" - "github.com/onflow/cadence" "github.com/onflow/cadence/runtime" "github.com/onflow/cadence/runtime/ast" @@ -40,6 +38,8 @@ import ( "github.com/onflow/flow-go/cmd/util/ledger/migrations" "github.com/onflow/flow-go/model/flow" "github.com/onflow/flowkit/v2" + + "github.com/onflow/flow-cli/internal/util" ) type stagingValidator struct { @@ -307,7 +307,7 @@ func (v *stagingValidator) loadSystemContracts() { return } - stagedSystemContracts := migrations.SystemContractChanges(chainId, migrations.SystemContractChangesOptions{ + stagedSystemContracts := migrations.SystemContractChanges(chainId, migrations.SystemContractsMigrationOptions{ Burner: migrations.BurnerContractChangeUpdate, // needs to be update for now since BurnerChangeDeploy is a no-op in flow-go EVM: migrations.EVMContractChangeFull, }) diff --git a/internal/migrate/state.go b/internal/migrate/state.go index d153f2fde..a2c14ae98 100644 --- a/internal/migrate/state.go +++ b/internal/migrate/state.go @@ -22,25 +22,20 @@ import ( "fmt" "os" - "github.com/rs/zerolog" - "github.com/spf13/cobra" - "github.com/onflow/cadence" "github.com/onflow/cadence/runtime/common" - "github.com/onflow/flow-emulator/storage/migration" emulatorMigrate "github.com/onflow/flow-emulator/storage/migration" "github.com/onflow/flow-emulator/storage/sqlite" - + "github.com/onflow/flow-go-sdk" "github.com/onflow/flow-go/cmd/util/ledger/migrations" "github.com/onflow/flow-go/cmd/util/ledger/reporters" - "github.com/onflow/flowkit/v2" "github.com/onflow/flowkit/v2/config" "github.com/onflow/flowkit/v2/output" "github.com/onflow/flowkit/v2/project" - - "github.com/onflow/flow-go-sdk" + "github.com/rs/zerolog" + "github.com/spf13/cobra" "github.com/onflow/flow-cli/internal/command" ) @@ -99,6 +94,7 @@ func migrateState( err = emulatorMigrate.MigrateCadence1( store, + stateFlags.SaveReport, migrations.EVMContractChangeNone, migrations.BurnerContractChangeDeploy, contracts,