-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
245 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
package fixstrays | ||
|
||
import ( | ||
storetypes "github.com/cosmos/cosmos-sdk/store/types" | ||
sdk "github.com/cosmos/cosmos-sdk/types" | ||
"github.com/cosmos/cosmos-sdk/types/module" | ||
upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" | ||
"github.com/jackalLabs/canine-chain/app/upgrades" | ||
"github.com/jackalLabs/canine-chain/types" | ||
storagemodulekeeper "github.com/jackalLabs/canine-chain/x/storage/keeper" | ||
) | ||
|
||
var _ upgrades.Upgrade = &Upgrade{} | ||
|
||
// Upgrade represents the v4 upgrade | ||
type Upgrade struct { | ||
mm *module.Manager | ||
configurator module.Configurator | ||
storeageKeeper storagemodulekeeper.Keeper | ||
} | ||
|
||
// NewUpgrade returns a new Upgrade instance | ||
func NewUpgrade(mm *module.Manager, configurator module.Configurator, storeageKeeper storagemodulekeeper.Keeper) *Upgrade { | ||
return &Upgrade{ | ||
mm: mm, | ||
configurator: configurator, | ||
storeageKeeper: storeageKeeper, | ||
} | ||
} | ||
|
||
// Name implements upgrades.Upgrade | ||
func (u *Upgrade) Name() string { | ||
return "fixstrays" | ||
} | ||
|
||
// Handler implements upgrades.Upgrade | ||
func (u *Upgrade) Handler() upgradetypes.UpgradeHandler { | ||
return func(ctx sdk.Context, plan upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { | ||
if types.IsTestnet(ctx.ChainID()) { | ||
|
||
newVM, err := u.mm.RunMigrations(ctx, u.configurator, fromVM) | ||
if err != nil { | ||
return newVM, err | ||
} | ||
|
||
deals := u.storeageKeeper.GetAllActiveDeals(ctx) | ||
for _, deal := range deals { | ||
u.storeageKeeper.RemoveActiveDeals(ctx, deal.Cid) | ||
} | ||
|
||
strays := u.storeageKeeper.GetAllStrays(ctx) | ||
for _, stray := range strays { | ||
u.storeageKeeper.RemoveStrays(ctx, stray.Cid) | ||
} | ||
|
||
payinfo := u.storeageKeeper.GetAllStoragePaymentInfo(ctx) | ||
for _, info := range payinfo { | ||
u.storeageKeeper.RemoveStoragePaymentInfo(ctx, info.Address) | ||
} | ||
|
||
fidcid := u.storeageKeeper.GetAllFidCid(ctx) | ||
for _, fc := range fidcid { | ||
u.storeageKeeper.RemoveFidCid(ctx, fc.Fid) | ||
} | ||
|
||
return newVM, err | ||
} | ||
return fromVM, nil | ||
} | ||
} | ||
|
||
// StoreUpgrades implements upgrades.Upgrade | ||
func (u *Upgrade) StoreUpgrades() *storetypes.StoreUpgrades { | ||
return &storetypes.StoreUpgrades{} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# v1.2.0 - Bouncy Bulldog | ||
|
||
## Summary | ||
This upgrade allows the Jackal Network to start fulfilling its purpose as the Decentralized Storage Platform of the Cosmos. This upgrade introduces the Storage module, which allows users to pay for storage and create storage deals with Storage Providers. It also brings the addition of the Filetree module which creates a privacy layer and bucket file structure akin to S3 and Google Drive. Finally it also brings the addition of the Oracle module which allows other modules to query a data stream being supplied by a centralized entity. In this case, Jackal Labs will be using this oracle to supply pricing information while the AMM module is being finalized. | ||
## Change Log | ||
* Re-added Storage Module | ||
* Re-added Filetree Module | ||
* Added Oracle Module | ||
* Fixed RNS marketplace bugs | ||
* Increased Code Test Coverage to ~50% | ||
* Fixed Go Package & Proto Layout | ||
* Removed Ignite CLI as a dependency & fixed codegen bugs associated with it | ||
* Improved Safety of Storage/Filetree modules from v1.1.1 | ||
* Updated Cosmwasm Version from v0.29.1 -> v0.29.2 | ||
* Updated CosmosSDK Version from v0.45.10 -> v0.45.11 | ||
* Updated IBC Version from v3.3.1 -> v3.4.0 | ||
* Updated Tendermint Version from Tendermint v0.34.22 -> [Informal's Tendermint](https://github.com/tendermint/tendermint/issues/9972) v0.34.23 | ||
* Updated Security of Storage Module proof mechanism from using Blake2b to Sha3-512 | ||
* Refactored HTTP server into new repo, see [canine-provider](https://github.com/JackalLabs/canine-provider) | ||
|
||
For a full list of changes, please visit https://github.com/JackalLabs/canine-chain/compare/v1.1.2-hotfix...v23.01-beta | ||
|
||
## Upgrading | ||
See [the upgrade instructions](https://github.com/JackalLabs/canine-chain/blob/v23.01-beta/upgrades/v1.2.0.md) for full details on how to install and run this upgrade. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.