Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into nialexsan/update-sc…
Browse files Browse the repository at this point in the history
…affolds
  • Loading branch information
nialexsan committed Nov 20, 2024
2 parents 69fae46 + 659c356 commit cc5d63b
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ require (
github.com/onflow/cadence-tools/test v1.0.0
github.com/onflow/fcl-dev-wallet v0.8.0
github.com/onflow/flixkit-go/v2 v2.0.1
github.com/onflow/flow-core-contracts/lib/go/templates v1.3.1
github.com/onflow/flow-core-contracts/lib/go/templates v1.4.0
github.com/onflow/flow-emulator v1.0.1
github.com/onflow/flow-evm-gateway v0.36.5-0.20241005010031-1f3f5439d553
github.com/onflow/flow-go v0.38.0-preview.0.0.20241002124048-21cfe5aea5a8
Expand Down Expand Up @@ -207,9 +207,9 @@ require (
github.com/onflow/crypto v0.25.2 // indirect
github.com/onflow/flow-core-contracts/lib/go/contracts v1.3.1 // indirect
github.com/onflow/flow-ft/lib/go/contracts v1.0.0 // indirect
github.com/onflow/flow-ft/lib/go/templates v1.0.0 // indirect
github.com/onflow/flow-ft/lib/go/templates v1.0.1 // indirect
github.com/onflow/flow-nft/lib/go/contracts v1.2.1 // indirect
github.com/onflow/flow-nft/lib/go/templates v1.2.0 // indirect
github.com/onflow/flow-nft/lib/go/templates v1.2.1 // indirect
github.com/onflow/flow/protobuf/go/flow v0.4.7 // indirect
github.com/onflow/sdks v0.6.0-preview.1 // indirect
github.com/onflow/wal v1.0.2 // indirect
Expand Down
12 changes: 6 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -2174,25 +2174,25 @@ github.com/onflow/flixkit-go/v2 v2.0.1 h1:hbGiP5mdi9HPlsGSSnPtsTmQiaZXDkcpV3Cfn4
github.com/onflow/flixkit-go/v2 v2.0.1/go.mod h1:TVF6tdM5AMVhRtq1LcYqjOJDoz54TUyrMZvZUHNrX+o=
github.com/onflow/flow-core-contracts/lib/go/contracts v1.3.1 h1:q9tXLIALwQ76bO4bmSrhtTkyc2cZF4/gH11ix9E3F5k=
github.com/onflow/flow-core-contracts/lib/go/contracts v1.3.1/go.mod h1:u/mkP/B+PbV33tEG3qfkhhBlydSvAKxfLZSfB4lsJHg=
github.com/onflow/flow-core-contracts/lib/go/templates v1.3.1 h1:FfhMBAb78p6VAWkJ+iqdKLErGQVQgxk5w6DP5ZruWX8=
github.com/onflow/flow-core-contracts/lib/go/templates v1.3.1/go.mod h1:NgbMOYnMh0GN48VsNKZuiwK7uyk38Wyo8jN9+C9QE30=
github.com/onflow/flow-core-contracts/lib/go/templates v1.4.0 h1:u2DAG8pk0xFH7TwS70t1gSZ/FtIIZWMSNyiu4SeXBYg=
github.com/onflow/flow-core-contracts/lib/go/templates v1.4.0/go.mod h1:pN768Al/wLRlf3bwugv9TyxniqJxMu4sxnX9eQJam64=
github.com/onflow/flow-emulator v1.0.1 h1:yQc/YOzj4jJ4hPhWtzDTR4KXTq02LNXySMsU1ZK1uEw=
github.com/onflow/flow-emulator v1.0.1/go.mod h1:xDln3yR7WNfv+45RojHlezV0N8QziMrII16agWaOwFE=
github.com/onflow/flow-evm-gateway v0.36.5-0.20241005010031-1f3f5439d553 h1:FCDMPsHKT59j0AkwloTG05D4jvz+hGAYlep/OyoiCgs=
github.com/onflow/flow-evm-gateway v0.36.5-0.20241005010031-1f3f5439d553/go.mod h1:Wmk1Lc/dUjRNfXVAkRoD1pJNic0rV3lZx/WcuCkBWg8=
github.com/onflow/flow-ft/lib/go/contracts v1.0.0 h1:mToacZ5NWqtlWwk/7RgIl/jeKB/Sy/tIXdw90yKHcV0=
github.com/onflow/flow-ft/lib/go/contracts v1.0.0/go.mod h1:PwsL8fC81cjnUnTfmyL/HOIyHnyaw/JA474Wfj2tl6A=
github.com/onflow/flow-ft/lib/go/templates v1.0.0 h1:6cMS/lUJJ17HjKBfMO/eh0GGvnpElPgBXx7h5aoWJhs=
github.com/onflow/flow-ft/lib/go/templates v1.0.0/go.mod h1:uQ8XFqmMK2jxyBSVrmyuwdWjTEb+6zGjRYotfDJ5pAE=
github.com/onflow/flow-ft/lib/go/templates v1.0.1 h1:FDYKAiGowABtoMNusLuRCILIZDtVqJ/5tYI4VkF5zfM=
github.com/onflow/flow-ft/lib/go/templates v1.0.1/go.mod h1:uQ8XFqmMK2jxyBSVrmyuwdWjTEb+6zGjRYotfDJ5pAE=
github.com/onflow/flow-go v0.38.0-preview.0.0.20241002124048-21cfe5aea5a8 h1:gQcr59aPL9YjsUkgYwcc8ec8h2bw3ttX03553S/aW34=
github.com/onflow/flow-go v0.38.0-preview.0.0.20241002124048-21cfe5aea5a8/go.mod h1:kdaRKWlvm1vC8Lhf2uI4XvDxS+AvfWvrWZr2CFOz8y8=
github.com/onflow/flow-go-sdk v1.0.0-M1/go.mod h1:TDW0MNuCs4SvqYRUzkbRnRmHQL1h4X8wURsCw9P9beo=
github.com/onflow/flow-go-sdk v1.0.0 h1:Ha4fQm1MMKsyaqMkQLCN3rA/yaQKG6DGwiIfx06j40c=
github.com/onflow/flow-go-sdk v1.0.0/go.mod h1:iZkW2IWieVUZKK06mQCxpjJzPDgS0VtGpTaP/rKu6J4=
github.com/onflow/flow-nft/lib/go/contracts v1.2.1 h1:woAAS5z651sDpi7ihAHll8NvRS9uFXIXkL6xR+bKFZY=
github.com/onflow/flow-nft/lib/go/contracts v1.2.1/go.mod h1:2gpbza+uzs1k7x31hkpBPlggIRkI53Suo0n2AyA2HcE=
github.com/onflow/flow-nft/lib/go/templates v1.2.0 h1:JSQyh9rg0RC+D1930BiRXN8lrtMs+ubVMK6aQPon6Yc=
github.com/onflow/flow-nft/lib/go/templates v1.2.0/go.mod h1:p+2hRvtjLUR3MW1NsoJe5Gqgr2eeH49QB6+s6ze00w0=
github.com/onflow/flow-nft/lib/go/templates v1.2.1 h1:SAALMZPDw9Eb9p5kSLnmnFxjyig1MLiT4JUlLp0/bSE=
github.com/onflow/flow-nft/lib/go/templates v1.2.1/go.mod h1:W6hOWU0xltPqNpv9gQX8Pj8Jtf0OmRxc1XX2V0kzJaI=
github.com/onflow/flow/protobuf/go/flow v0.3.2-0.20231121210617-52ee94b830c2/go.mod h1:NA2pX2nw8zuaxfKphhKsk00kWLwfd+tv8mS23YXO4Sk=
github.com/onflow/flow/protobuf/go/flow v0.4.7 h1:iP6DFx4wZ3ETORsyeqzHu7neFT3d1CXF6wdK+AOOjmc=
github.com/onflow/flow/protobuf/go/flow v0.4.7/go.mod h1:NA2pX2nw8zuaxfKphhKsk00kWLwfd+tv8mS23YXO4Sk=
Expand Down
14 changes: 7 additions & 7 deletions internal/dependencymanager/dependencyinstaller.go
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,12 @@ func (di *DependencyInstaller) handleFoundContract(networkName, contractAddr, as
}
}

err := di.updateDependencyState(networkName, contractAddr, assignedName, contractName, originalContractDataHash)
if err != nil {
di.Logger.Error(fmt.Sprintf("Error updating state: %v", err))
return err
}

// Needs to happen before handleFileSystem
if !di.contractFileExists(contractAddr, contractName) {
err := di.handleAdditionalDependencyTasks(networkName, contractName)
Expand All @@ -455,17 +461,11 @@ func (di *DependencyInstaller) handleFoundContract(networkName, contractAddr, as
}
}

err := di.handleFileSystem(contractAddr, contractName, contractData, networkName)
err = di.handleFileSystem(contractAddr, contractName, contractData, networkName)
if err != nil {
return fmt.Errorf("error handling file system: %w", err)
}

err = di.updateDependencyState(networkName, contractAddr, assignedName, contractName, originalContractDataHash)
if err != nil {
di.Logger.Error(fmt.Sprintf("Error updating state: %v", err))
return err
}

return nil
}

Expand Down
2 changes: 1 addition & 1 deletion internal/emulator/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func configuredServiceKey(
state, err = flowkit.Load(command.Flags.ConfigPaths, loader)
if err != nil {
if errors.Is(err, config.ErrDoesNotExist) {
exitf(1, "🙏 Configuration is missing, initialize it with: 'flow init' and then rerun this command.")
exitf(1, "🙏 Configuration (flow.json) is missing, are you in the correct directory? If you are trying to create a new project, initialize it with 'flow init' and then rerun this command.")
} else {
exitf(1, err.Error())
}
Expand Down

0 comments on commit cc5d63b

Please sign in to comment.