From ba55477c6ab2c99d191aa46d86c6ccb909c6eab5 Mon Sep 17 00:00:00 2001 From: Luca Joss Date: Wed, 28 Aug 2024 10:56:58 +0200 Subject: [PATCH] Update Neutron to v4.2.2 --- flake.lock | 26 ++++++++++++++++++++++---- flake.nix | 5 ++++- modules/packages.nix | 2 +- packages/libwasmvm.nix | 12 ++++++++++++ packages/neutron.nix | 14 ++++++++------ 5 files changed, 47 insertions(+), 12 deletions(-) diff --git a/flake.lock b/flake.lock index ba05a68..8aa7192 100644 --- a/flake.lock +++ b/flake.lock @@ -1114,16 +1114,16 @@ "neutron-src": { "flake": false, "locked": { - "lastModified": 1722341371, - "narHash": "sha256-dhBhWytamqp1hRsQH+xqpq1UJmPi6CRHHDQwveCQ2WQ=", + "lastModified": 1724773633, + "narHash": "sha256-pHubObIv3p6IrzI/U7aeDjdF5kWBpI9qgDoH/Hjk+i8=", "owner": "neutron-org", "repo": "neutron", - "rev": "db33d3302abb45ee3887a97ea3d53923241fc167", + "rev": "1b10cd282d5809ccdd87208918fd175aebec2b0b", "type": "github" }, "original": { "owner": "neutron-org", - "ref": "v4.1.0", + "ref": "v4.2.2", "repo": "neutron", "type": "github" } @@ -1509,6 +1509,7 @@ "wasmvm_1_5_2-src": "wasmvm_1_5_2-src", "wasmvm_1_beta7-src": "wasmvm_1_beta7-src", "wasmvm_2_0_0-src": "wasmvm_2_0_0-src", + "wasmvm_2_0_3-src": "wasmvm_2_0_3-src", "wasmvm_2_1_0-src": "wasmvm_2_1_0-src" } }, @@ -1945,6 +1946,23 @@ "type": "github" } }, + "wasmvm_2_0_3-src": { + "flake": false, + "locked": { + "lastModified": 1723134607, + "narHash": "sha256-fFFP9sqlfgFbjAPP6VVXEcDQ3is2RHZYNE003Ls8Sfk=", + "owner": "CosmWasm", + "repo": "wasmvm", + "rev": "64b8c846dadb664eeb9da765a98fc370eb594f6d", + "type": "github" + }, + "original": { + "owner": "CosmWasm", + "ref": "v2.0.3", + "repo": "wasmvm", + "type": "github" + } + }, "wasmvm_2_1_0-src": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index be6047d..12f8234 100644 --- a/flake.nix +++ b/flake.nix @@ -220,6 +220,9 @@ wasmvm_2_1_0-src.url = "github:CosmWasm/wasmvm/v2.1.0"; wasmvm_2_1_0-src.flake = false; + wasmvm_2_0_3-src.url = "github:CosmWasm/wasmvm/v2.0.3"; + wasmvm_2_0_3-src.flake = false; + wasmvm_2_0_0-src.url = "github:CosmWasm/wasmvm/v2.0.0"; wasmvm_2_0_0-src.flake = false; @@ -271,7 +274,7 @@ celestia-node-src.url = "github:celestiaorg/celestia-node/v0.13.0"; celestia-node-src.flake = false; - neutron-src.url = "github:neutron-org/neutron/v4.1.0"; + neutron-src.url = "github:neutron-org/neutron/v4.2.2"; neutron-src.flake = false; provenance-src.url = "github:/provenance-io/provenance/v1.19.1"; diff --git a/modules/packages.nix b/modules/packages.nix index 16eb4f7..7da5947 100644 --- a/modules/packages.nix +++ b/modules/packages.nix @@ -109,7 +109,7 @@ }; neutron = import ../packages/neutron.nix { inherit (inputs) neutron-src; - inherit (self'.packages) libwasmvm_2_0_0; + inherit (self'.packages) libwasmvm_2_0_3; inherit cosmosLib; }; andromeda = import ../packages/andromeda.nix { diff --git a/packages/libwasmvm.nix b/packages/libwasmvm.nix index b6c0c8f..ce870dc 100644 --- a/packages/libwasmvm.nix +++ b/packages/libwasmvm.nix @@ -29,6 +29,18 @@ in }; }; + libwasmvm_2_0_3 = { + src = "${inputs.wasmvm_2_0_3-src}/libwasmvm"; + version = "v2.0.3"; + cargoSha256 = "sha256-BFou131HI+YKXU9H51Xa/y7A441Z7QkAA92mhquJ5l4="; + cargoLock = { + lockFile = "${inputs.wasmvm_2_0_3-src}/libwasmvm/Cargo.lock"; + outputHashes = { + "cosmwasm-crypto-2.0.6" = "sha256-gGrbTeHzVn+9T82R6nsq2VIm1armIS/e1TP9w8z0aQ4="; + }; + }; + }; + libwasmvm_2_0_0 = { src = "${inputs.wasmvm_2_0_0-src}/libwasmvm"; version = "v2.0.0"; diff --git a/packages/neutron.nix b/packages/neutron.nix index d4b9fc7..2ed393d 100644 --- a/packages/neutron.nix +++ b/packages/neutron.nix @@ -1,20 +1,22 @@ { neutron-src, cosmosLib, - libwasmvm_2_0_0, + libwasmvm_2_0_3, }: cosmosLib.mkCosmosGoApp { - goVersion = "1.22"; + # nixpkgs latest go version v1.22 is v1.22.5 but Neutron v4.2.2 requires + # v1.22.6 or more so v1.23 is used instead + goVersion = "1.23"; name = "neutron"; - version = "v4.1.0"; + version = "v4.2.2"; src = neutron-src; rev = neutron-src.rev; - vendorHash = "sha256-SKuAOWosHM2tvVAsTu54sAfbiTtCoJap3/LA4zfmuOo="; + vendorHash = "sha256-5yjri/9QCSnHieWu/v9AYcktP+kXFEyWE7IbhkoNFXs="; engine = "cometbft/cometbft"; preFixup = '' - ${cosmosLib.wasmdPreFixupPhase libwasmvm_2_0_0 "neutrond"} + ${cosmosLib.wasmdPreFixupPhase libwasmvm_2_0_3 "neutrond"} ''; - buildInputs = [libwasmvm_2_0_0]; + buildInputs = [libwasmvm_2_0_3]; # main module (github.com/neutron-org/neutron/v4) does not contain package github.com/neutron-org/neutron/v4/tests/feemarket # main module (github.com/neutron-org/neutron/v4) does not contain package github.com/neutron-org/neutron/v4/tests/slinky