diff --git a/.github/workflows/generate-srtool-wasm.yml b/.github/workflows/generate-srtool-wasm.yml new file mode 100644 index 000000000..6ccca997e --- /dev/null +++ b/.github/workflows/generate-srtool-wasm.yml @@ -0,0 +1,48 @@ +name: Srtool build Wasm + +on: + workflow_dispatch: + + push: + branches: [main] + +jobs: + srtool: + runs-on: ubuntu-latest + strategy: + matrix: + chain: ["testnet", "mainnet"] + steps: + + - uses: actions/checkout@v3 + + - name: Srtool build + if: matrix.chain == 'mainnet' + id: srtool_build + uses: chevdor/srtool-actions@v0.8.0 + with: + chain: ${{ matrix.chain }} + runtime_dir: runtime/${{ matrix.chain }} + package: tangle-runtime + + - name: Srtool build testnet + if: matrix.chain == 'testnet' + uses: chevdor/srtool-actions@v0.8.0 + with: + chain: ${{ matrix.chain }} + runtime_dir: runtime/${{ matrix.chain }} + package: tangle-testnet-runtime + + - name: Summary + run: | + echo '${{ steps.srtool_build.outputs.json }}' | jq . > ${{ matrix.chain }}-srtool-digest.json + cat ${{ matrix.chain }}-srtool-digest.json + echo "Runtime location: ${{ steps.srtool_build.outputs.wasm }}" + + - name: Archive Runtime + uses: actions/upload-artifact@v2 + with: + name: ${{ matrix.chain }}-runtime-${{ github.sha }} + path: | + ${{ steps.srtool_build.outputs.wasm }} + ${{ matrix.chain }}-srtool-digest.json \ No newline at end of file diff --git a/.github/workflows/publish-srtool-wasm.yml b/.github/workflows/publish-srtool-wasm.yml new file mode 100644 index 000000000..4f27ec4cc --- /dev/null +++ b/.github/workflows/publish-srtool-wasm.yml @@ -0,0 +1,48 @@ +name: Srtool Wasm Publish + +on: + workflow_dispatch: + + push: + tags: ["v*.*.*"] + +jobs: + srtool: + runs-on: ubuntu-latest + strategy: + matrix: + chain: ["testnet", "mainnet"] + steps: + - uses: actions/checkout@v3 + + - name: Srtool build + if: matrix.chain == 'mainnet' + id: srtool_build + uses: chevdor/srtool-actions@v0.8.0 + with: + chain: ${{ matrix.chain }} + runtime_dir: runtime/${{ matrix.chain }} + package: tangle-runtime + + - name: Srtool build testnet + if: matrix.chain == 'testnet' + uses: chevdor/srtool-actions@v0.8.0 + with: + chain: ${{ matrix.chain }} + runtime_dir: runtime/${{ matrix.chain }} + package: tangle-testnet-runtime + + - name: Summary + run: | + echo '${{ steps.srtool_build.outputs.json }}' | jq . > ${{ matrix.chain }}-srtool-digest.json + cat ${{ matrix.chain }}-srtool-digest.json + echo "Runtime location: ${{ steps.srtool_build.outputs.wasm }}" + + - name: Upload ${{ matrix.chain }} wasm to release + uses: svenstaro/upload-release-action@v2 + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + file: ${{ steps.srtool_build.outputs.wasm }} + asset_name: tangle-${{ matrix.features }}-srtool-wasm + tag: ${{ github.ref }} + overwrite: true \ No newline at end of file diff --git a/pallets/dkg/src/misbehavior/dfns_cggmp21/integer.rs b/pallets/dkg/src/misbehavior/dfns_cggmp21/integer.rs index 3f5dd7894..b1fd2cd65 100644 --- a/pallets/dkg/src/misbehavior/dfns_cggmp21/integer.rs +++ b/pallets/dkg/src/misbehavior/dfns_cggmp21/integer.rs @@ -15,6 +15,7 @@ // along with Tangle. If not, see . use malachite_base::num::conversion::traits::FromStringBase; +use parity_scale_codec::alloc::vec; use parity_scale_codec::{Decode, Encode}; use scale_info::TypeInfo; use sp_core::RuntimeDebug; diff --git a/runtime/mainnet/Cargo.toml b/runtime/mainnet/Cargo.toml index 34733e595..5cced3c1e 100644 --- a/runtime/mainnet/Cargo.toml +++ b/runtime/mainnet/Cargo.toml @@ -215,6 +215,7 @@ std = [ "pallet-roles/std", "sp-storage/std", "pallet-jobs/std", + "pallet-jobs-rpc-runtime-api/std", # Tangle dependencies "tangle-primitives/std",