diff --git a/cmd/newallocation.go b/cmd/newallocation.go index 8bcdf2a5..14026e8d 100755 --- a/cmd/newallocation.go +++ b/cmd/newallocation.go @@ -284,7 +284,7 @@ var newallocationCmd = &cobra.Command{ } allocationID, _, _, err = sdk.CreateAllocationForOwner(owner, ownerPublicKey, *datashards, *parityshards, - *size, readPrice, writePrice, lock, preferred_blobbers, blobber_auth_tickets, thirdPartyExtendable, isEnterprise, force, &fileOptionParams) + *size, readPrice, writePrice, lock, preferred_blobbers, blobber_auth_tickets, thirdPartyExtendable, isEnterprise, force, &fileOptionParams, 0) if err != nil { log.Fatal("Error creating allocation: ", err) } diff --git a/cmd/storage.go b/cmd/storage.go index 9c0976e4..16e4dc7c 100644 --- a/cmd/storage.go +++ b/cmd/storage.go @@ -2,6 +2,7 @@ package cmd import ( "fmt" + "github.com/0chain/gosdk/zcncore" "log" "time" @@ -82,6 +83,11 @@ var lsBlobers = &cobra.Command{ log.Fatalf("Failed to get blobbers: %v", err) } + isActivated, err := zcncore.IsHardforkActivated("hermes") + log.Println("IsActivated: ", isActivated) + log.Fatal(err) + return + if doJSON { util.PrintJSON(list) } else { diff --git a/cmd/updateallocation.go b/cmd/updateallocation.go index aacb5ae9..b5b348ff 100755 --- a/cmd/updateallocation.go +++ b/cmd/updateallocation.go @@ -131,6 +131,7 @@ var updateAllocationCmd = &cobra.Command{ allocUnderRepair = true if txnHash, err := allocationObj.UpdateWithRepair( size, + 0, extend, lock, addBlobberId, @@ -154,6 +155,7 @@ var updateAllocationCmd = &cobra.Command{ } else { txnHash, _, err := sdk.UpdateAllocation( size, + 0, extend, allocID, lock, diff --git a/go.mod b/go.mod index 46d28fb6..07fb067d 100644 --- a/go.mod +++ b/go.mod @@ -6,7 +6,7 @@ toolchain go1.22.5 require ( github.com/0chain/errors v1.0.3 - github.com/0chain/gosdk v1.18.16 + github.com/0chain/gosdk v1.8.18-0.20230901213317-53d640a9b7f9 github.com/icza/bitio v1.1.0 github.com/olekukonko/tablewriter v0.0.5 github.com/spf13/cobra v1.6.0 @@ -86,4 +86,4 @@ require ( ) // temporary, for development -//replace github.com/0chain/gosdk => ../gosdk +replace github.com/0chain/gosdk => ../gosdk diff --git a/go.sum b/go.sum index 7d9bc7e5..3d823daa 100644 --- a/go.sum +++ b/go.sum @@ -40,8 +40,6 @@ github.com/0chain/common v1.18.3 h1:42dYOv2KyMTSanuS67iDtfv+ErbSRqR8NJ3MG72MwaI= github.com/0chain/common v1.18.3/go.mod h1:Lapu2Tj7z5Sm4r+X141e7vsz4NDODTEypeElYAP3iSw= github.com/0chain/errors v1.0.3 h1:QQZPFxTfnMcRdt32DXbzRQIfGWmBsKoEdszKQDb0rRM= github.com/0chain/errors v1.0.3/go.mod h1:xymD6nVgrbgttWwkpSCfLLEJbFO6iHGQwk/yeSuYkIc= -github.com/0chain/gosdk v1.18.16 h1:QpApoYGc7jbTxnSTi1AmyRHSvhFpkaPs3yWghhLj9rU= -github.com/0chain/gosdk v1.18.16/go.mod h1:8unFy9Dx2YyPKMYPDGR3MFhUEymbAfQcRDm9bobVLGw= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ=