From 5a33425da5d7d35a442cd2af2ba737372c5f9b41 Mon Sep 17 00:00:00 2001 From: Yohe-Am <56622350+Yohe-Am@users.noreply.github.com> Date: Sat, 6 Jul 2024 00:42:27 +0300 Subject: [PATCH] fix: broken pipeline for 0.4.4 (#782) Fixes erroneous usage of `setup-deno` which has been replaced by `ghjk` itself. #### Migration notes ... - [ ] The change comes with new or modified tests - [ ] Hard-to-understand functions have explanatory comments - [ ] End-user documentation is updated to reflect the change --- .github/workflows/merge.yml | 119 ---------------------------------- .github/workflows/release.yml | 9 --- .github/workflows/tests.yml | 6 -- dev/consts.ts | 1 - 4 files changed, 135 deletions(-) delete mode 100644 .github/workflows/merge.yml diff --git a/.github/workflows/merge.yml b/.github/workflows/merge.yml deleted file mode 100644 index 59a28764fe..0000000000 --- a/.github/workflows/merge.yml +++ /dev/null @@ -1,119 +0,0 @@ -on: - merge_group: - types: - - checks_requested - -env: - GHJK_VERSION: "0.2.0" - DENO_VERSION: "1.43.6" - RUST_BACKTRACE: "full" - RUST_LOG: "info,swc_ecma_codegen=off,tracing::span=off" - DENO_DIR: deno-dir - -jobs: - changes: - runs-on: ubuntu-latest - permissions: - pull-requests: read - steps: - - uses: actions/checkout@v4 - - uses: dorny/paths-filter@v3 - id: filter - with: - filters: | - website: - - '.github/workflows/tests.yml' - - 'website/**' - meta-cli: - - '.github/workflows/tests.yml' - - 'libs/**' - - 'meta-cli/**' - - 'Cargo.lock' - typegate: - - '.github/workflows/tests.yml' - - 'libs/**' - - 'typegate/**' - - 'meta-cli/**' - - 'Cargo.lock' - full: - - '.github/workflows/tests.yml' - - 'libs/**' - - 'typegate/**' - - 'typegraph/**' - - 'meta-cli/**' - - 'Cargo.lock' - - 'examples/**' - rust: - - '.github/workflows/tests.yml' - - 'libs/**' - - 'Cargo.lock' - outputs: - website: ${{ steps.filter.outputs.website }} - meta-cli: ${{ steps.filter.outputs.meta-cli }} - typegate: ${{ steps.filter.outputs.typegate }} - full: ${{ steps.filter.outputs.full }} - rust: ${{ steps.filter.outputs.rust }} - - - test-meta-cli-compat: - needs: changes - if: ${{ needs.changes.outputs.meta-cli == 'true' }} - runs-on: "${{ matrix.os }}" - strategy: - matrix: - include: - - os: macos-13 - activate: "source .venv/bin/activate" - - os: macos-14 - activate: "source .venv/bin/activate" - #- os: windows-latest - # activate: '.venv\Scripts\activate.bat' - steps: - - uses: actions/checkout@v4 - - uses: denoland/setup-deno@v1 - with: - deno-version: ${{ env.DENO_VERSION }} - - name: Cache deno dir - uses: actions/cache@v4 - with: - path: ${{ env.DENO_DIR }} - key: deno-mac-${{ hashFiles('**/deno.lock') }} - - uses: dsherret/rust-toolchain-file@v1 - - uses: Swatinem/rust-cache@v2 - with: - shared-key: ${{ runner.os }}-rust-${{ hashFiles('**/rust-toolchain.toml') }}-${{ hashFiles('**/Cargo.lock') }} - - name: Cache .venv dir - uses: actions/cache@v4 - with: - path: .venv - key: ${{ matrix.os }}-venv-${{ hashFiles('**/poetry.lock', '.ghjk/lock.json') }} - - uses: metatypedev/setup-ghjk@318209a9d215f70716a4ac89dbeb9653a2deb8bc - with: - # temporary fix - cache-key-prefix: ${{ matrix.os }} - - shell: bash - env: - WASM_FILE: target/debug/typegraph_core.wasm - run: | - python3 -m venv .venv - ${{ matrix.activate }} - - cd typegraph/python - poetry install --no-root - cd ../.. - poetry install --no-root - - deno cache --import-map typegate/import_map.json typegate/src/main.ts typegate/tests/utils/mod.ts - - cargo build -p typegraph_core --target wasm32-unknown-unknown --target-dir target/wasm - mkdir -p $(dirname $WASM_FILE) - wasm-opt -Oz target/wasm/wasm32-unknown-unknown/debug/typegraph_core.wasm -o $WASM_FILE.opt - wasm-tools component new $WASM_FILE.opt -o $WASM_FILE - rm -rf typegraph/python/typegraph/gen - poetry run python -m wasmtime.bindgen $WASM_FILE --out-dir typegraph/python/typegraph/gen - - cargo run --locked --package meta-cli -- --help - cargo test --locked --package meta-cli - - # check the fat CLI build - cargo run --locked --package meta-cli --features typegate -- --help diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a88c9dbd40..6000790386 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -30,9 +30,6 @@ jobs: fetch-depth: 0 - uses: WyriHaximus/github-action-get-previous-tag@v1.4.0 id: latest-tag - - uses: denoland/setup-deno@v1 - with: - deno-version: v${{ env.DENO_VERSION }} - uses: kenji-miyake/setup-git-cliff@v2 - run: | VERSION=$(ghjk x version-print) @@ -161,9 +158,6 @@ jobs: id: latest-tag - uses: dsherret/rust-toolchain-file@v1 - uses: mozilla-actions/sccache-action@v0.0.3 - - uses: denoland/setup-deno@v1 - with: - deno-version: ${{ env.DENO_VERSION }} - uses: metatypedev/setup-ghjk@318209a9d215f70716a4ac89dbeb9653a2deb8bc - shell: bash env: @@ -336,9 +330,6 @@ jobs: with: fetch-depth: 0 - uses: dsherret/rust-toolchain-file@v1 - - uses: denoland/setup-deno@v1 - with: - deno-version: v${{ env.DENO_VERSION }} - uses: kenji-miyake/setup-git-cliff@v2 - id: bump run: | diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 11bf409d0e..6b9ee26af3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -81,9 +81,6 @@ jobs: - uses: actions/checkout@v4 - uses: dsherret/rust-toolchain-file@v1 - uses: mozilla-actions/sccache-action@v0.0.3 - - uses: denoland/setup-deno@v1 - with: - deno-version: ${{ env.DENO_VERSION }} - uses: metatypedev/setup-ghjk@318209a9d215f70716a4ac89dbeb9653a2deb8bc - shell: bash run: | @@ -236,9 +233,6 @@ jobs: detached: true - uses: dsherret/rust-toolchain-file@v1 - uses: mozilla-actions/sccache-action@v0.0.3 - - uses: denoland/setup-deno@v1 - with: - deno-version: ${{ env.DENO_VERSION }} # - name: Cache deno dir # uses: actions/cache@v4 # with: diff --git a/dev/consts.ts b/dev/consts.ts index e686a21fe6..6765b498ff 100644 --- a/dev/consts.ts +++ b/dev/consts.ts @@ -19,7 +19,6 @@ export const sedLockLines: Record = { "rust-toolchain.toml": [[/(channel = ").+(")/, RUST_VERSION]], ".github/**/*.yml": [ ['( GHJK_VERSION: ").+(")', GHJK_VERSION], - ['( DENO_VERSION: ").+(")', DENO_VERSION], [/([\s-]+uses:\s+metatypedev\/setup-ghjk@).+()/, GHJK_ACTION_VERSION], ], "meta-lsp/package.json": [