diff --git a/.changeset/rare-hornets-rush.md b/.changeset/rare-hornets-rush.md deleted file mode 100644 index 6addec2382c..00000000000 --- a/.changeset/rare-hornets-rush.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@fuel-ts/utils": patch ---- - -chore: integrate vitest matchers globally diff --git a/.changeset/rotten-chefs-shake.md b/.changeset/rotten-chefs-shake.md deleted file mode 100644 index 21aba98f83f..00000000000 --- a/.changeset/rotten-chefs-shake.md +++ /dev/null @@ -1,4 +0,0 @@ ---- ---- - -docs: add docs for splitting UTXOs, `maxOutputs` and `maxInputs` \ No newline at end of file diff --git a/.changeset/wild-stingrays-cheat.md b/.changeset/wild-stingrays-cheat.md deleted file mode 100644 index 3a3c0777276..00000000000 --- a/.changeset/wild-stingrays-cheat.md +++ /dev/null @@ -1,8 +0,0 @@ ---- -"@fuel-ts/contract": patch -"@fuel-ts/account": patch -"fuels": patch -"@fuel-ts/utils": patch ---- - -chore: update internally used chain config diff --git a/.github/workflows/release-deprecate.yaml b/.github/workflows/release-deprecate.yaml new file mode 100644 index 00000000000..61807d69d16 --- /dev/null +++ b/.github/workflows/release-deprecate.yaml @@ -0,0 +1,29 @@ +name: "Deprecate Old Versions" + +on: + workflow_dispatch: + inputs: + deprecate_versions: + type: boolean + description: Deprecate versions? Otherwise dry-run mode will be used. + default: false + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + deprecate-npm-versions: + name: Deprecate versions next, pr and rc + runs-on: buildjet-4vcpu-ubuntu-2204 + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: CI Setup + uses: ./.github/actions/ci-setup + + - name: Deprecate + run: pnpm release:deprecate + env: + DEPRECATE_VERSIONS: ${{ github.event.inputs.deprecate_versions }} diff --git a/.github/workflows/release-unpublish.yaml b/.github/workflows/release-unpublish.yaml deleted file mode 100644 index 77cba5e6ea3..00000000000 --- a/.github/workflows/release-unpublish.yaml +++ /dev/null @@ -1,28 +0,0 @@ -name: "Unpublish old versions" - -on: - workflow_dispatch: - inputs: - delete_packages: - type: boolean - description: Delete packages? otherwise dry-run mode will be used - default: false - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true - -jobs: - clean-npm-versions: - name: Unpublish versions next and pr - runs-on: buildjet-4vcpu-ubuntu-2204 - steps: - - uses: actions/checkout@v4 - - uses: ./.github/actions/ci-setup - - uses: FuelLabs/github-actions/setups/npm@master - with: - npm-token: ${{ secrets.NPM_TOKEN }} - - run: | - node ./scripts/release-unpublish.js - env: - DELETE_PACKAGES: ${{ github.event.inputs.delete_packages}} diff --git a/apps/create-fuels-counter-guide/fuel-toolchain.toml b/apps/create-fuels-counter-guide/fuel-toolchain.toml index 63b847ed56f..1abe9727207 100644 --- a/apps/create-fuels-counter-guide/fuel-toolchain.toml +++ b/apps/create-fuels-counter-guide/fuel-toolchain.toml @@ -1,2 +1,6 @@ [toolchain] channel = "testnet" + +[components] +forc = "0.66.5" +fuel-core = "0.40.1" \ No newline at end of file diff --git a/internal/benchmarks/CHANGELOG.md b/internal/benchmarks/CHANGELOG.md index c062bac1c9b..6e6c8e0980b 100644 --- a/internal/benchmarks/CHANGELOG.md +++ b/internal/benchmarks/CHANGELOG.md @@ -1,5 +1,12 @@ # @internal/benchmarks +## 1.0.10 + +### Patch Changes + +- Updated dependencies [ebe5ecd] + - fuels@0.97.2 + ## 1.0.9 ### Patch Changes diff --git a/internal/benchmarks/package.json b/internal/benchmarks/package.json index 1bc55986896..253dd72a5b8 100644 --- a/internal/benchmarks/package.json +++ b/internal/benchmarks/package.json @@ -14,5 +14,5 @@ "fuels": "workspace:*", "@internal/utils": "workspace:*" }, - "version": "1.0.9" + "version": "1.0.10" } diff --git a/internal/check-imports/CHANGELOG.md b/internal/check-imports/CHANGELOG.md index 3cff6c2142b..143324a3715 100644 --- a/internal/check-imports/CHANGELOG.md +++ b/internal/check-imports/CHANGELOG.md @@ -1,5 +1,31 @@ # @internal/check-imports +## 0.0.17 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [5ec254d] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/versions@0.97.2 + - @fuel-ts/contract@0.97.2 + - @fuel-ts/account@0.97.2 + - fuels@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/abi-typegen@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/program@0.97.2 + - @fuel-ts/script@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/merkle@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.0.16 ### Patch Changes diff --git a/internal/check-imports/package.json b/internal/check-imports/package.json index 9e825284c71..7d55c6752fb 100644 --- a/internal/check-imports/package.json +++ b/internal/check-imports/package.json @@ -27,5 +27,5 @@ "@fuel-ts/account": "workspace:*", "fuels": "workspace:*" }, - "version": "0.0.16" + "version": "0.0.17" } diff --git a/internal/forc/CHANGELOG.md b/internal/forc/CHANGELOG.md index 1d6b83284c9..479ecce2cb1 100644 --- a/internal/forc/CHANGELOG.md +++ b/internal/forc/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## 0.89.5 + +### Patch Changes + +- 5ec254d: chore: updated forc version to `0.66.5` + ## 0.89.4 ### Patch Changes diff --git a/internal/forc/VERSION b/internal/forc/VERSION index e890bffdf27..fff670af850 100644 --- a/internal/forc/VERSION +++ b/internal/forc/VERSION @@ -1 +1 @@ -0.66.4 +0.66.5 diff --git a/internal/forc/package.json b/internal/forc/package.json index 07df4a15d29..f26c2edaeb2 100644 --- a/internal/forc/package.json +++ b/internal/forc/package.json @@ -1,7 +1,7 @@ { "private": true, "name": "@internal/forc", - "version": "0.89.4", + "version": "0.89.5", "description": "NPM bin wrapper around Fuel `forc`", "author": "Fuel Labs (https://fuel.network/)", "bin": { diff --git a/package.json b/package.json index 6711a49ae90..c37e19ba1cf 100644 --- a/package.json +++ b/package.json @@ -55,6 +55,7 @@ "changeset:update-changelog": "tsx ./scripts/changeset/update-changelog.mts", "changeset:get-latest-release": "tsx ./scripts/changeset/get-latest-release.mts", "changeset:dependabot": "./scripts/changeset/dependabot-changeset.sh", + "release:deprecate": "tsx ./scripts/release-deprecate.ts", "forc:update": "tsx ./scripts/forc-update", "forc:check": "./scripts/forc-check.sh", "forc:format": "./scripts/forc-format.sh", diff --git a/packages/abi-coder/CHANGELOG.md b/packages/abi-coder/CHANGELOG.md index 260fd961c27..34e6c7746e0 100644 --- a/packages/abi-coder/CHANGELOG.md +++ b/packages/abi-coder/CHANGELOG.md @@ -1,5 +1,19 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/abi-coder/package.json b/packages/abi-coder/package.json index 52e462b0a67..cd480019997 100644 --- a/packages/abi-coder/package.json +++ b/packages/abi-coder/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/abi-coder", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/abi-typegen/CHANGELOG.md b/packages/abi-typegen/CHANGELOG.md index 3045edcd58c..a707a4cdf66 100644 --- a/packages/abi-typegen/CHANGELOG.md +++ b/packages/abi-typegen/CHANGELOG.md @@ -1,5 +1,18 @@ # @fuel-ts/abi-typegen +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [5ec254d] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/versions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/abi-typegen/package.json b/packages/abi-typegen/package.json index 7ad0d2ff37b..0159020dc0d 100644 --- a/packages/abi-typegen/package.json +++ b/packages/abi-typegen/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/abi-typegen", - "version": "0.97.1", + "version": "0.97.2", "description": "Generates Typescript definitions from Sway ABI Json files", "author": "Fuel Labs (https://fuel.network/)", "bin": { diff --git a/packages/abi-typegen/test/fixtures/templates/contract-with-configurable/main.hbs b/packages/abi-typegen/test/fixtures/templates/contract-with-configurable/main.hbs index d767304335a..9c3157b490b 100644 --- a/packages/abi-typegen/test/fixtures/templates/contract-with-configurable/main.hbs +++ b/packages/abi-typegen/test/fixtures/templates/contract-with-configurable/main.hbs @@ -160,17 +160,17 @@ const abi = { { "name": "SHOULD_RETURN", "concreteTypeId": "b760f44fa5965c2474a3b471467a22c43185152129295af588b022ae50b50903", - "offset": 2776 + "offset": 2816 }, { "name": "AN_OPTION", "concreteTypeId": "2da102c46c7263beeed95818cd7bee801716ba8303dddafdcd0f6c9efda4a0f1", - "offset": 2752 + "offset": 2792 }, { "name": "A_GENERIC_STRUCT", "concreteTypeId": "71df88006611ffff852cf617defb70f77adaf507305088cedd41d276c783aab0", - "offset": 2768 + "offset": 2808 } ] }; diff --git a/packages/abi-typegen/test/fixtures/templates/predicate-with-configurable/main.hbs b/packages/abi-typegen/test/fixtures/templates/predicate-with-configurable/main.hbs index fdacb6def91..c40afd5a99d 100644 --- a/packages/abi-typegen/test/fixtures/templates/predicate-with-configurable/main.hbs +++ b/packages/abi-typegen/test/fixtures/templates/predicate-with-configurable/main.hbs @@ -73,12 +73,12 @@ const abi = { { "name": "FEE", "concreteTypeId": "c89951a24c6ca28c13fd1cfdc646b2b656d69e61a92b91023be7eb58eb914b6b", - "offset": 920 + "offset": 936 }, { "name": "ADDRESS", "concreteTypeId": "7c5ee1cecf5f8eacd1284feb5f0bf2bdea533a51e2f0c9aabe9236d335989f3b", - "offset": 888 + "offset": 904 } ] }; diff --git a/packages/abi-typegen/test/fixtures/templates/script-with-configurable/main.hbs b/packages/abi-typegen/test/fixtures/templates/script-with-configurable/main.hbs index 71b9ba3cb53..34c9a4f1722 100644 --- a/packages/abi-typegen/test/fixtures/templates/script-with-configurable/main.hbs +++ b/packages/abi-typegen/test/fixtures/templates/script-with-configurable/main.hbs @@ -81,7 +81,7 @@ const abi = { { "name": "SHOULD_RETURN", "concreteTypeId": "b760f44fa5965c2474a3b471467a22c43185152129295af588b022ae50b50903", - "offset": 760 + "offset": 768 } ] }; diff --git a/packages/account/CHANGELOG.md b/packages/account/CHANGELOG.md index 7aa0a1fb5c7..5a9269c0430 100644 --- a/packages/account/CHANGELOG.md +++ b/packages/account/CHANGELOG.md @@ -1,5 +1,26 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- ebe5ecd: chore: update internally used chain config +- Updated dependencies [0970bc4] +- Updated dependencies [5ec254d] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/versions@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/merkle@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/account/package.json b/packages/account/package.json index 833acb6ed29..446a5ecad12 100644 --- a/packages/account/package.json +++ b/packages/account/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/account", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/address/CHANGELOG.md b/packages/address/CHANGELOG.md index 6dee7356960..e151d8ef0e0 100644 --- a/packages/address/CHANGELOG.md +++ b/packages/address/CHANGELOG.md @@ -1,5 +1,17 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/address/package.json b/packages/address/package.json index f1e2d570558..bbd00cdc526 100644 --- a/packages/address/package.json +++ b/packages/address/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/address", - "version": "0.97.1", + "version": "0.97.2", "description": "Utilities for encoding and decoding addresses", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/contract/CHANGELOG.md b/packages/contract/CHANGELOG.md index 081db43f4d0..2a19a86a13d 100644 --- a/packages/contract/CHANGELOG.md +++ b/packages/contract/CHANGELOG.md @@ -1,5 +1,27 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- ebe5ecd: chore: update internally used chain config +- Updated dependencies [0970bc4] +- Updated dependencies [5ec254d] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/versions@0.97.2 + - @fuel-ts/account@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/program@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/merkle@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/contract/package.json b/packages/contract/package.json index 13e817a5539..fd2f4db6ee0 100644 --- a/packages/contract/package.json +++ b/packages/contract/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/contract", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/create-fuels/CHANGELOG.md b/packages/create-fuels/CHANGELOG.md index 51dacbda2d0..a2e267d10d8 100644 --- a/packages/create-fuels/CHANGELOG.md +++ b/packages/create-fuels/CHANGELOG.md @@ -1,5 +1,14 @@ # create-fuels +## 0.97.2 + +### Patch Changes + +- efdf9a1: fix: specify versions in `create fuels` toolchain file +- Updated dependencies [5ec254d] + - @fuel-ts/versions@0.97.2 + - @fuel-ts/errors@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/create-fuels/package.json b/packages/create-fuels/package.json index 431e06ce7bd..8f4ec4dcef9 100644 --- a/packages/create-fuels/package.json +++ b/packages/create-fuels/package.json @@ -1,6 +1,6 @@ { "name": "create-fuels", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "bin": { diff --git a/packages/create-fuels/test/cli.test.ts b/packages/create-fuels/test/cli.test.ts index e51500559df..a58965b876b 100644 --- a/packages/create-fuels/test/cli.test.ts +++ b/packages/create-fuels/test/cli.test.ts @@ -83,9 +83,13 @@ describe('CLI', { timeout: 15_000 }, () => { const fuelToolchain = readFileSync(fuelToolchainPath, 'utf-8'); const parsedFuelToolchain = toml.parse(fuelToolchain); - const { toolchain } = parsedFuelToolchain; + const { toolchain, components } = parsedFuelToolchain; expect(toolchain).toEqual({ channel: 'testnet' }); + expect(components).toEqual({ + forc: '0.66.5', + 'fuel-core': '0.40.1', + }); }); test('should rewrite for the appropriate package manager', async () => { diff --git a/packages/crypto/CHANGELOG.md b/packages/crypto/CHANGELOG.md index 4b3754b39f8..dd2a6872dd1 100644 --- a/packages/crypto/CHANGELOG.md +++ b/packages/crypto/CHANGELOG.md @@ -1,5 +1,17 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/crypto/package.json b/packages/crypto/package.json index 269600c89b1..4818995a291 100644 --- a/packages/crypto/package.json +++ b/packages/crypto/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/crypto", - "version": "0.97.1", + "version": "0.97.2", "description": "Utilities for encrypting and decrypting data", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/errors/CHANGELOG.md b/packages/errors/CHANGELOG.md index ea6166e2a5a..dd79980d0ae 100644 --- a/packages/errors/CHANGELOG.md +++ b/packages/errors/CHANGELOG.md @@ -1,5 +1,12 @@ # @fuel-ts/errors +## 0.97.2 + +### Patch Changes + +- Updated dependencies [5ec254d] + - @fuel-ts/versions@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/errors/package.json b/packages/errors/package.json index fad17a07904..db553956a45 100644 --- a/packages/errors/package.json +++ b/packages/errors/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/errors", - "version": "0.97.1", + "version": "0.97.2", "description": "Error class and error codes that the fuels-ts library throws", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/abi-contract/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/abi-contract/src/main.sw index afc7ebb063f..dcce801f68d 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/abi-contract/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/abi-contract/src/main.sw @@ -1,8 +1,8 @@ contract; -mod data_structures; -mod equality; -mod utils; +pub mod data_structures; +pub mod equality; +pub mod utils; use data_structures::*; use equality::*; diff --git a/packages/fuel-gauge/test/fixtures/forc-projects/bytecode-sway-lib/src/main.sw b/packages/fuel-gauge/test/fixtures/forc-projects/bytecode-sway-lib/src/main.sw index 5aac2d0d056..f0c350998a2 100644 --- a/packages/fuel-gauge/test/fixtures/forc-projects/bytecode-sway-lib/src/main.sw +++ b/packages/fuel-gauge/test/fixtures/forc-projects/bytecode-sway-lib/src/main.sw @@ -19,6 +19,6 @@ impl MyContract for Contract { } fn compute_predicate_address(bytecode: Vec) -> Address { - return Address::from(0x68fec7a57e48f4ec6467d7e09c27272bd8ca72b312ea553a470b98731475ccf3); + return Address::from(0x190c849d8d5fdc0ad9e87cdfa02dde8b4414cacb34ae277a49ec057e67b04c01); } } diff --git a/packages/fuels/CHANGELOG.md b/packages/fuels/CHANGELOG.md index 6486ee8373b..a16c9e42e40 100644 --- a/packages/fuels/CHANGELOG.md +++ b/packages/fuels/CHANGELOG.md @@ -1,5 +1,32 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- ebe5ecd: chore: update internally used chain config +- Updated dependencies [0970bc4] +- Updated dependencies [5ec254d] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/versions@0.97.2 + - @fuel-ts/contract@0.97.2 + - @fuel-ts/account@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/abi-typegen@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/program@0.97.2 + - @fuel-ts/recipes@0.97.2 + - @fuel-ts/script@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/merkle@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/fuels/package.json b/packages/fuels/package.json index dab7694d1af..d95bd3c43a5 100644 --- a/packages/fuels/package.json +++ b/packages/fuels/package.json @@ -1,6 +1,6 @@ { "name": "fuels", - "version": "0.97.1", + "version": "0.97.2", "description": "Fuel TS SDK", "author": "Fuel Labs (https://fuel.network/)", "bin": { diff --git a/packages/hasher/CHANGELOG.md b/packages/hasher/CHANGELOG.md index b5a55e7bde2..60ad637670d 100644 --- a/packages/hasher/CHANGELOG.md +++ b/packages/hasher/CHANGELOG.md @@ -1,5 +1,16 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/crypto@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/hasher/package.json b/packages/hasher/package.json index 78cddcdab0a..d929e2ce70c 100644 --- a/packages/hasher/package.json +++ b/packages/hasher/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/hasher", - "version": "0.97.1", + "version": "0.97.2", "description": "Sha256 hash utility for Fuel", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/interfaces/CHANGELOG.md b/packages/interfaces/CHANGELOG.md index 753c62ae787..e9860253b08 100644 --- a/packages/interfaces/CHANGELOG.md +++ b/packages/interfaces/CHANGELOG.md @@ -1,5 +1,7 @@ # Change Log +## 0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/interfaces/package.json b/packages/interfaces/package.json index ae371647051..fc9806e2c47 100644 --- a/packages/interfaces/package.json +++ b/packages/interfaces/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/interfaces", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/logger/CHANGELOG.md b/packages/logger/CHANGELOG.md index b3ebef2b05d..b5b247aec7f 100644 --- a/packages/logger/CHANGELOG.md +++ b/packages/logger/CHANGELOG.md @@ -1,5 +1,13 @@ # @fuel-ts/logger +## 0.97.2 + +### Patch Changes + +- @fuel-ts/address@0.97.2 +- @fuel-ts/math@0.97.2 +- @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/logger/package.json b/packages/logger/package.json index ef3d0be4a07..5a3f3df1cdf 100644 --- a/packages/logger/package.json +++ b/packages/logger/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/logger", - "version": "0.97.1", + "version": "0.97.2", "author": "Fuel Labs (https://fuel.network/)", "description": "A logger for the Fuel-TS ecosystem", "main": "dist/index.js", diff --git a/packages/math/CHANGELOG.md b/packages/math/CHANGELOG.md index 0f569c049f6..15251b648ad 100644 --- a/packages/math/CHANGELOG.md +++ b/packages/math/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- @fuel-ts/errors@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/math/package.json b/packages/math/package.json index 41dea3b37b4..2d49d315d4e 100644 --- a/packages/math/package.json +++ b/packages/math/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/math", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/merkle/CHANGELOG.md b/packages/merkle/CHANGELOG.md index feede49d5e9..191e9bef232 100644 --- a/packages/merkle/CHANGELOG.md +++ b/packages/merkle/CHANGELOG.md @@ -1,5 +1,12 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- @fuel-ts/hasher@0.97.2 +- @fuel-ts/math@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/merkle/package.json b/packages/merkle/package.json index 9363c1a09a9..ffd4260a45f 100644 --- a/packages/merkle/package.json +++ b/packages/merkle/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/merkle", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/program/CHANGELOG.md b/packages/program/CHANGELOG.md index 07403a9873c..bee88abf9c8 100644 --- a/packages/program/CHANGELOG.md +++ b/packages/program/CHANGELOG.md @@ -1,5 +1,21 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/account@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/program/package.json b/packages/program/package.json index 8377da6fefd..df590f63d6f 100644 --- a/packages/program/package.json +++ b/packages/program/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/program", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/recipes/CHANGELOG.md b/packages/recipes/CHANGELOG.md index d2a1ad0acfe..9d00300254e 100644 --- a/packages/recipes/CHANGELOG.md +++ b/packages/recipes/CHANGELOG.md @@ -1,5 +1,21 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/contract@0.97.2 + - @fuel-ts/account@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/abi-typegen@0.97.2 + - @fuel-ts/program@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/recipes/package.json b/packages/recipes/package.json index 05200e09806..bc566fe267c 100644 --- a/packages/recipes/package.json +++ b/packages/recipes/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/recipes", - "version": "0.97.1", + "version": "0.97.2", "description": "Recipes for Sway Programs", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/recipes/src/types/Src14OwnedProxy.ts b/packages/recipes/src/types/Src14OwnedProxy.ts index dcfab7009a8..aab3c9532ae 100644 --- a/packages/recipes/src/types/Src14OwnedProxy.ts +++ b/packages/recipes/src/types/Src14OwnedProxy.ts @@ -5,7 +5,7 @@ /* eslint-disable @typescript-eslint/consistent-type-imports */ /* - Fuels version: 0.97.0 + Fuels version: 0.97.2 */ import { Contract, type InvokeFunction } from '@fuel-ts/program'; diff --git a/packages/recipes/src/types/Src14OwnedProxyFactory.ts b/packages/recipes/src/types/Src14OwnedProxyFactory.ts index b0789cb3f5a..30762b7a0e9 100644 --- a/packages/recipes/src/types/Src14OwnedProxyFactory.ts +++ b/packages/recipes/src/types/Src14OwnedProxyFactory.ts @@ -5,7 +5,7 @@ /* eslint-disable @typescript-eslint/consistent-type-imports */ /* - Fuels version: 0.97.0 + Fuels version: 0.97.2 */ import { ContractFactory, type DeployContractOptions } from '@fuel-ts/contract'; diff --git a/packages/recipes/src/types/common.d.ts b/packages/recipes/src/types/common.d.ts index d7ca20eaa69..ef3dec5e95c 100644 --- a/packages/recipes/src/types/common.d.ts +++ b/packages/recipes/src/types/common.d.ts @@ -5,7 +5,7 @@ /* eslint-disable @typescript-eslint/consistent-type-imports */ /* - Fuels version: 0.97.0 + Fuels version: 0.97.2 */ /** diff --git a/packages/recipes/src/types/index.ts b/packages/recipes/src/types/index.ts index 22dd3591167..15dc6b12ae3 100644 --- a/packages/recipes/src/types/index.ts +++ b/packages/recipes/src/types/index.ts @@ -5,7 +5,7 @@ /* eslint-disable @typescript-eslint/consistent-type-imports */ /* - Fuels version: 0.97.0 + Fuels version: 0.97.2 */ export { Src14OwnedProxy } from './Src14OwnedProxy'; diff --git a/packages/script/CHANGELOG.md b/packages/script/CHANGELOG.md index 2b3759ee417..d80f0fcc9b4 100644 --- a/packages/script/CHANGELOG.md +++ b/packages/script/CHANGELOG.md @@ -1,5 +1,22 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/account@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/program@0.97.2 + - @fuel-ts/transactions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/script/package.json b/packages/script/package.json index 390a175c337..93b9cbad421 100644 --- a/packages/script/package.json +++ b/packages/script/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/script", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/transactions/CHANGELOG.md b/packages/transactions/CHANGELOG.md index d656ed16123..5c7b2003627 100644 --- a/packages/transactions/CHANGELOG.md +++ b/packages/transactions/CHANGELOG.md @@ -1,5 +1,20 @@ # Change Log +## 0.97.2 + +### Patch Changes + +- Updated dependencies [0970bc4] +- Updated dependencies [896bf5b] +- Updated dependencies [ebe5ecd] + - @fuel-ts/utils@0.97.2 + - @fuel-ts/abi-coder@0.97.2 + - @fuel-ts/address@0.97.2 + - @fuel-ts/hasher@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/transactions/package.json b/packages/transactions/package.json index d8913d02387..84e9e0bf45a 100644 --- a/packages/transactions/package.json +++ b/packages/transactions/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/transactions", - "version": "0.97.1", + "version": "0.97.2", "description": "", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", diff --git a/packages/utils/CHANGELOG.md b/packages/utils/CHANGELOG.md index eba5e7e7931..f3c9b37db4f 100644 --- a/packages/utils/CHANGELOG.md +++ b/packages/utils/CHANGELOG.md @@ -1,5 +1,18 @@ # @fuel-ts/utils +## 0.97.2 + +### Patch Changes + +- 0970bc4: fix: Vitest matcher integration +- 896bf5b: chore: integrate vitest matchers globally +- ebe5ecd: chore: update internally used chain config +- Updated dependencies [5ec254d] + - @fuel-ts/versions@0.97.2 + - @fuel-ts/errors@0.97.2 + - @fuel-ts/math@0.97.2 + - @fuel-ts/interfaces@0.97.2 + ## 0.97.1 ### Patch Changes diff --git a/packages/utils/package.json b/packages/utils/package.json index 4838abaa426..63a44d2d4dc 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/utils", - "version": "0.97.1", + "version": "0.97.2", "description": "Utilities (and test utilities) collection", "author": "Fuel Labs (https://fuel.network/)", "main": "dist/index.js", @@ -52,5 +52,8 @@ "@fuel-ts/math": "workspace:*", "@fuel-ts/versions": "workspace:*", "fflate": "0.8.2" + }, + "peerDependencies": { + "vitest": "2.0.5" } } diff --git a/packages/utils/src/test-utils/vitest.matchers.ts b/packages/utils/src/test-utils/vitest.matchers.ts index 0240caa917e..4cf99f05c22 100644 --- a/packages/utils/src/test-utils/vitest.matchers.ts +++ b/packages/utils/src/test-utils/vitest.matchers.ts @@ -1,5 +1,6 @@ import { bn } from '@fuel-ts/math'; import type { BN, BNInput } from '@fuel-ts/math'; +import type { ExpectStatic as GlobalExpectStatic } from 'vitest'; interface Matchers { toEqualBn: (expected: BNInput) => R; @@ -12,7 +13,7 @@ declare module 'vitest' { } } -export const setupTestMatchers = () => { +export const setupTestMatchers = (expect: GlobalExpectStatic) => { expect.extend({ toEqualBn(received: BNInput, expected: BNInput) { const actualBn = bn(received); diff --git a/packages/versions/CHANGELOG.md b/packages/versions/CHANGELOG.md index 765642b0c49..2ac7d0c98b0 100644 --- a/packages/versions/CHANGELOG.md +++ b/packages/versions/CHANGELOG.md @@ -1,5 +1,11 @@ # @fuel-ts/versions +## 0.97.2 + +### Patch Changes + +- 5ec254d: chore: updated forc version to `0.66.5` + ## 0.97.1 ### Patch Changes diff --git a/packages/versions/package.json b/packages/versions/package.json index 263f53dfd63..37ae36cfcca 100644 --- a/packages/versions/package.json +++ b/packages/versions/package.json @@ -1,6 +1,6 @@ { "name": "@fuel-ts/versions", - "version": "0.97.1", + "version": "0.97.2", "description": "Validates supported versions of the Fuel toolchain", "author": "Fuel Labs (https://fuel.network/)", "bin": { diff --git a/packages/versions/src/lib/getBuiltinVersions.ts b/packages/versions/src/lib/getBuiltinVersions.ts index 66829a030dc..ba398bf849a 100644 --- a/packages/versions/src/lib/getBuiltinVersions.ts +++ b/packages/versions/src/lib/getBuiltinVersions.ts @@ -2,8 +2,8 @@ import type { Versions } from './types'; export function getBuiltinVersions(): Versions { return { - FORC: '0.66.4', + FORC: '0.66.5', FUEL_CORE: '0.40.1', - FUELS: '0.97.1', + FUELS: '0.97.2', }; } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index ebc274c4d1f..0b70c432ee5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1236,6 +1236,9 @@ importers: fflate: specifier: 0.8.2 version: 0.8.2 + vitest: + specifier: 2.0.5 + version: 2.0.5(@types/node@22.7.7)(@vitest/browser@2.0.5)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.36.0) packages/versions: dependencies: @@ -13968,6 +13971,7 @@ packages: sudo-prompt@9.2.1: resolution: {integrity: sha512-Mu7R0g4ig9TUuGSxJavny5Rv0egCEtpZRNMrZaYS1vxkiIxGiGUwoezU3LazIQ+KE04hTrTfNPgxU5gzi7F5Pw==} + deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. summary@2.1.0: resolution: {integrity: sha512-nMIjMrd5Z2nuB2RZCKJfFMjgS3fygbeyGk9PxPPaJR1RIcyN9yn4A63Isovzm3ZtQuEkLBVgMdPup8UeLH7aQw==} @@ -21313,7 +21317,7 @@ snapshots: magic-string: 0.30.11 msw: 2.4.7(typescript@5.6.3) sirv: 2.0.4 - vitest: 2.0.5(@types/node@22.5.5)(@vitest/browser@2.0.5)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.36.0) + vitest: 2.0.5(@types/node@22.7.7)(@vitest/browser@2.0.5)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.36.0) ws: 8.18.0(bufferutil@4.0.8)(utf-8-validate@6.0.4) optionalDependencies: playwright: 1.47.2 @@ -25487,7 +25491,7 @@ snapshots: eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint@8.57.0))(eslint@8.57.0) - eslint-plugin-import: 2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0) + eslint-plugin-import: 2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint@8.57.0))(eslint@8.57.0))(eslint@8.57.0) eslint-plugin-jsx-a11y: 6.9.0(eslint@8.57.0) eslint-plugin-react: 7.35.0(eslint@8.57.0) eslint-plugin-react-hooks: 4.6.2(eslint@8.57.0) @@ -25542,7 +25546,7 @@ snapshots: enhanced-resolve: 5.17.1 eslint: 8.57.0 eslint-module-utils: 2.11.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint@8.57.0))(eslint@8.57.0))(eslint@8.57.0) - eslint-plugin-import: 2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0) + eslint-plugin-import: 2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint@8.57.0))(eslint@8.57.0))(eslint@8.57.0) fast-glob: 3.3.2 get-tsconfig: 4.7.6 is-core-module: 2.15.1 @@ -25671,7 +25675,7 @@ snapshots: - eslint-import-resolver-webpack - supports-color - eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0): + eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint@8.57.0))(eslint@8.57.0))(eslint@8.57.0): dependencies: '@rtsao/scc': 1.1.0 array-includes: 3.1.8 @@ -25699,6 +25703,35 @@ snapshots: - eslint-import-resolver-webpack - supports-color + eslint-plugin-import@2.30.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-typescript@3.6.1)(eslint@8.57.0): + dependencies: + '@rtsao/scc': 1.1.0 + array-includes: 3.1.8 + array.prototype.findlastindex: 1.2.5 + array.prototype.flat: 1.3.2 + array.prototype.flatmap: 1.3.2 + debug: 3.2.7 + doctrine: 2.1.0 + eslint: 8.57.0 + eslint-import-resolver-node: 0.3.9 + eslint-module-utils: 2.11.0(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-import-resolver-typescript@3.6.1(@typescript-eslint/parser@6.21.0(eslint@8.57.0)(typescript@5.6.3))(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.30.0)(eslint@8.57.0))(eslint@8.57.0) + hasown: 2.0.2 + is-core-module: 2.15.1 + is-glob: 4.0.3 + minimatch: 3.1.2 + object.fromentries: 2.0.8 + object.groupby: 1.0.3 + object.values: 1.2.0 + semver: 6.3.1 + tsconfig-paths: 3.15.0 + optionalDependencies: + '@typescript-eslint/parser': 6.21.0(eslint@8.57.0)(typescript@5.6.3) + transitivePeerDependencies: + - eslint-import-resolver-typescript + - eslint-import-resolver-webpack + - supports-color + optional: true + eslint-plugin-jest@25.7.0(@typescript-eslint/eslint-plugin@5.59.0(@typescript-eslint/parser@5.59.0(eslint@9.9.1(jiti@2.3.3))(typescript@5.6.3))(eslint@9.9.1(jiti@2.3.3))(typescript@5.6.3))(eslint@9.9.1(jiti@2.3.3))(jest@27.5.1(bufferutil@4.0.8)(ts-node@10.9.1(@swc/core@1.7.14)(@types/node@22.5.5)(typescript@5.6.3))(utf-8-validate@5.0.10))(typescript@5.6.3): dependencies: '@typescript-eslint/experimental-utils': 5.60.1(eslint@9.9.1(jiti@2.3.3))(typescript@5.6.3) @@ -33531,6 +33564,41 @@ snapshots: - supports-color - terser + vitest@2.0.5(@types/node@22.7.7)(@vitest/browser@2.0.5)(jsdom@16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4))(terser@5.36.0): + dependencies: + '@ampproject/remapping': 2.3.0 + '@vitest/expect': 2.0.5 + '@vitest/pretty-format': 2.1.1 + '@vitest/runner': 2.0.5 + '@vitest/snapshot': 2.0.5 + '@vitest/spy': 2.0.5 + '@vitest/utils': 2.0.5 + chai: 5.1.1 + debug: 4.3.7(supports-color@5.5.0) + execa: 8.0.1 + magic-string: 0.30.11 + pathe: 1.1.2 + std-env: 3.7.0 + tinybench: 2.9.0 + tinypool: 1.0.1 + tinyrainbow: 1.2.0 + vite: 5.4.9(@types/node@22.7.7)(terser@5.36.0) + vite-node: 2.0.5(@types/node@22.7.7)(terser@5.36.0) + why-is-node-running: 2.3.0 + optionalDependencies: + '@types/node': 22.7.7 + '@vitest/browser': 2.0.5(bufferutil@4.0.8)(playwright@1.47.2)(typescript@5.6.3)(utf-8-validate@6.0.4)(vitest@2.0.5)(webdriverio@9.0.9(bufferutil@4.0.8)(utf-8-validate@6.0.4)) + jsdom: 16.7.0(bufferutil@4.0.8)(utf-8-validate@6.0.4) + transitivePeerDependencies: + - less + - lightningcss + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser + vlq@1.0.1: {} vm-browserify@1.1.2: {} diff --git a/scripts/release-deprecate.ts b/scripts/release-deprecate.ts new file mode 100644 index 00000000000..922b967cc76 --- /dev/null +++ b/scripts/release-deprecate.ts @@ -0,0 +1,86 @@ +import { compare } from 'compare-versions'; +import { exec } from 'node:child_process'; +import { readFileSync, readdirSync } from 'node:fs'; +import { join } from 'node:path'; + +const { log, error } = console; + +const deprecateTags = /next|pr|rc/; +const { version: currentVersion } = JSON.parse( + readFileSync(join(process.cwd(), '/packages/fuels/package.json')).toString() +); +const deprecateVersions = process.env.DEPRECATE_VERSIONS === 'true'; + +const getPublicPackages = () => { + const packagesDir = join(__dirname, '../packages'); + const packages = readdirSync(packagesDir, { withFileTypes: true }); + const packagesNames = packages.map((p) => { + try { + const packageContent = readFileSync(join(packagesDir, p.name, 'package.json'), 'utf8'); + const packageJson = JSON.parse(packageContent.toString()); + return packageJson.private ? null : packageJson.name; + } catch (err) { + return null; + } + }); + return packagesNames.filter((p) => !!p); +}; + +const getVersionsToDeprecate = async (packageName: string) => { + const { versions } = await fetch(`https://registry.npmjs.org/${packageName}`).then((resp) => + resp.json() + ); + + // Only deprecate certain tags + const validVersions = Object.keys(versions).filter( + (version) => version.search(deprecateTags) > -1 && !compare(version, currentVersion, '>=') + ); + + // Remove the latest next tag from the deprecation list + const latestNextVersion = validVersions.filter((version) => version.search('next') > -1).pop(); + return validVersions.filter((version) => version !== latestNextVersion); +}; + +const main = async () => { + const packages = getPublicPackages(); + await Promise.allSettled( + packages.map(async (packageName) => { + const versionsToDeprecate = await getVersionsToDeprecate(packageName); + + log('The following versions will be deprecated:'); + log(versionsToDeprecate.map((v) => ` - ${v}`).join('\n')); + + if (deprecateVersions) { + await Promise.allSettled( + versionsToDeprecate.map( + async (versionToDelete) => + new Promise((resolve, reject) => { + exec( + `npm deprecate ${packageName}@${versionToDelete} "Version no longer supported."`, + (err, _stdout, stderr) => { + if (err) { + log(`❌ Error ${packageName}@${versionToDelete} not deprecated!\n`); + reject(err); + return; + } + if (stderr) { + log(`❌ Error ${packageName}@${versionToDelete} not deprecated!\n`); + reject(new Error(stderr)); + return; + } + log(`✅ Package ${packageName}@${versionToDelete} deprecated!\n`); + resolve(true); + } + ); + }) + ) + ); + } + }) + ); +}; + +main().catch((err) => { + error(err); + process.exit(1); +}); diff --git a/scripts/release-unpublish.js b/scripts/release-unpublish.js deleted file mode 100644 index d88f3e91ed9..00000000000 --- a/scripts/release-unpublish.js +++ /dev/null @@ -1,59 +0,0 @@ -/* eslint-disable @typescript-eslint/no-var-requires */ -const { compare } = require('compare-versions'); -const { readFileSync, readdirSync } = require('node:fs'); -const { join } = require('node:path'); -const util = require('node:util'); -const exec = util.promisify(require('node:child_process').exec); - -const DELETE_TAGS = /next|pr/; -const { version: CURRENT_VERSION } = require('../packages/fuels/package.json'); - -const DELETE_PACKAGES = process.env.DELETE_PACKAGES === 'true'; -const dryRun = DELETE_PACKAGES ? '' : '--dry-run'; - -const { log, error } = console; - -const getPublicPackages = () => { - const packagesDir = join(__dirname, '../packages'); - const packages = readdirSync(packagesDir, { withFileTypes: true }); - const packagesNames = packages.map((p) => { - try { - const packageContent = readFileSync(join(packagesDir, p.name, 'package.json'), 'utf8'); - const packageJson = JSON.parse(packageContent.toString()); - return packageJson.private ? null : packageJson.name; - } catch (err) { - return null; - } - }); - return packagesNames.filter((p) => !!p); -}; - -const main = async () => { - const packages = getPublicPackages(); - await packages.map(async (packageName) => { - log(`📦 Fetching ${packageName} versions`); - const { versions: packageVersions } = await fetch( - `https://registry.npmjs.org/${packageName}` - ).then((resp) => resp.json()); - - const versionsToDelete = Object.keys(packageVersions).filter( - (packageVersion) => - packageVersion.search(DELETE_TAGS) > -1 && !compare(packageVersion, CURRENT_VERSION, '>=') - ); - log('The following versions will be deleted:'); - log(versionsToDelete.map((v) => ` - ${v}`).join('\n')); - versionsToDelete.map(async (versionToDelete) => { - const { stderr } = await exec(`npm unpublish ${packageName}@${versionToDelete} ${dryRun}`); - if (stderr) { - log(`❌ Error ${packageName}@${versionToDelete} not deleted!\n`); - } else { - log(`✅ Package ${packageName}@${versionToDelete} deleted!\n`); - } - }); - }); -}; - -main().catch((err) => { - error(err); - process.exit(1); -}); diff --git a/templates/nextjs/fuel-toolchain.toml b/templates/nextjs/fuel-toolchain.toml index 7d473c1eac9..1abe9727207 100644 --- a/templates/nextjs/fuel-toolchain.toml +++ b/templates/nextjs/fuel-toolchain.toml @@ -1,2 +1,6 @@ [toolchain] -channel = "testnet" \ No newline at end of file +channel = "testnet" + +[components] +forc = "0.66.5" +fuel-core = "0.40.1" \ No newline at end of file diff --git a/templates/vite/fuel-toolchain.toml b/templates/vite/fuel-toolchain.toml index 7d473c1eac9..1abe9727207 100644 --- a/templates/vite/fuel-toolchain.toml +++ b/templates/vite/fuel-toolchain.toml @@ -1,2 +1,6 @@ [toolchain] -channel = "testnet" \ No newline at end of file +channel = "testnet" + +[components] +forc = "0.66.5" +fuel-core = "0.40.1" \ No newline at end of file diff --git a/vitest.setup-files.ts b/vitest.setup-files.ts index 8cd866cc303..95bb7e793d8 100644 --- a/vitest.setup-files.ts +++ b/vitest.setup-files.ts @@ -1,3 +1,4 @@ import { setupTestMatchers } from '@fuel-ts/utils/test-utils'; +import { expect } from 'vitest'; -setupTestMatchers(); +setupTestMatchers(expect);