From f1260969a92f1824f3ba532d493c78bb61014400 Mon Sep 17 00:00:00 2001 From: Hussein Ait Lahcen Date: Tue, 30 Apr 2024 13:43:34 +0200 Subject: [PATCH] fix(ci): coverage currently ICE --- tools/rust/crane.nix | 97 ++++++++++++++++++++++---------------------- 1 file changed, 49 insertions(+), 48 deletions(-) diff --git a/tools/rust/crane.nix b/tools/rust/crane.nix index 5e5a6e4973..fffa82d3c5 100644 --- a/tools/rust/crane.nix +++ b/tools/rust/crane.nix @@ -335,53 +335,54 @@ in craneLib.cargoClippy (attrs // { cargoArtifacts = craneLib.buildDepsOnly attrs; }); - packages.rust-coverage = - let - craneLib = crane.lib.${system}.overrideToolchain rust.toolchains.dev; - in - craneLib.cargoLlvmCov { - pname = "workspace-cargo-llvm-cov"; - version = "0.0.0"; - cargoLlvmCovExtraArgs = lib.concatStringsSep " " [ - "--workspace" - "--html" - "--output-dir=$out" - "--ignore-filename-regex='((nix/store)|(generated))/.+'" - "--exclude=zerg" - "--exclude=parse-wasm-client-type" - "--exclude=protos" - "--exclude=contracts" - "--exclude=unionvisor" # TODO: Figure out why unionvisor tests are flakey - "--exclude=tidy" - "--exclude=generate-rust-sol-bindings" - "--exclude=ensure-blocks" - "--exclude=ucli" - "--hide-instantiations" - ]; - SQLX_OFFLINE = true; - cargoArtifacts = craneLib.buildDepsOnly { - pname = "workspace-build-deps-only"; - version = "0.0.0"; - cargoExtraArgs = "--locked"; - doCheck = false; - - buildInputs = [ pkgs.pkg-config pkgs.openssl ] ++ ( - lib.optionals pkgs.stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security ] - ); - src = cargoWorkspaceSrc; - }; - preBuild = '' - cp --no-preserve=mode ${self'.packages.uniond}/bin/uniond $(pwd)/unionvisor/src/testdata/test_init_cmd/bundle/bins/genesis - echo 'patching testdata' - patchShebangs $(pwd)/unionvisor/src/testdata - ''; - ICS23_TEST_SUITE_DATA_DIR = "${inputs.ics23}/testdata"; - ETHEREUM_CONSENSUS_SPECS_DIR = "${inputs.ethereum-consensus-specs}"; - - buildInputs = [ pkgs.pkg-config pkgs.openssl ] ++ ( - lib.optionals pkgs.stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security ] - ); - src = cargoWorkspaceSrc; - }; + # FIXME: currently ICE, https://github.com/unionlabs/union/actions/runs/8882618404/job/24387814904 + # packages.rust-coverage = + # let + # craneLib = crane.lib.${system}.overrideToolchain rust.toolchains.dev; + # in + # craneLib.cargoLlvmCov { + # pname = "workspace-cargo-llvm-cov"; + # version = "0.0.0"; + # cargoLlvmCovExtraArgs = lib.concatStringsSep " " [ + # "--workspace" + # "--html" + # "--output-dir=$out" + # "--ignore-filename-regex='((nix/store)|(generated))/.+'" + # "--exclude=zerg" + # "--exclude=parse-wasm-client-type" + # "--exclude=protos" + # "--exclude=contracts" + # "--exclude=unionvisor" # TODO: Figure out why unionvisor tests are flakey + # "--exclude=tidy" + # "--exclude=generate-rust-sol-bindings" + # "--exclude=ensure-blocks" + # "--exclude=ucli" + # "--hide-instantiations" + # ]; + # SQLX_OFFLINE = true; + # cargoArtifacts = craneLib.buildDepsOnly { + # pname = "workspace-build-deps-only"; + # version = "0.0.0"; + # cargoExtraArgs = "--locked"; + # doCheck = false; + + # buildInputs = [ pkgs.pkg-config pkgs.openssl ] ++ ( + # lib.optionals pkgs.stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security ] + # ); + # src = cargoWorkspaceSrc; + # }; + # preBuild = '' + # cp --no-preserve=mode ${self'.packages.uniond}/bin/uniond $(pwd)/unionvisor/src/testdata/test_init_cmd/bundle/bins/genesis + # echo 'patching testdata' + # patchShebangs $(pwd)/unionvisor/src/testdata + # ''; + # ICS23_TEST_SUITE_DATA_DIR = "${inputs.ics23}/testdata"; + # ETHEREUM_CONSENSUS_SPECS_DIR = "${inputs.ethereum-consensus-specs}"; + + # buildInputs = [ pkgs.pkg-config pkgs.openssl ] ++ ( + # lib.optionals pkgs.stdenv.isDarwin [ pkgs.darwin.apple_sdk.frameworks.Security ] + # ); + # src = cargoWorkspaceSrc; + # }; }; }