Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
83 commits
Select commit Hold shift + click to select a range
1da0e8d
Bumped versions
petertonysmith94 Jun 2, 2025
98519a9
Sync'd fuel-core schema
petertonysmith94 Jun 2, 2025
e05e72d
Separated `INSUFFICIENT_FUNDS` and `MAX_COINS_REACHED`
petertonysmith94 Jun 2, 2025
c853995
Fixed error message for `PredicateVerificationFailed`
petertonysmith94 Jun 2, 2025
4d36cf4
Revert "Separated `INSUFFICIENT_FUNDS` and `MAX_COINS_REACHED`"
petertonysmith94 Jun 3, 2025
c73d9a3
Allow proper mapping of `INSUFFICIENT_FUNDS_OR_MAX_COINS` error
petertonysmith94 Jun 3, 2025
ff08172
Bumped `@fuels/asm`
petertonysmith94 Jun 3, 2025
4705862
Changeset
petertonysmith94 Jun 3, 2025
30f66dc
Added metadata to the `INSUFFICIENT_FUNDS_OR_MAX_COINS` error
petertonysmith94 Jun 3, 2025
33019d4
Lintfix
petertonysmith94 Jun 3, 2025
2166cab
Update .changeset/full-carpets-lose.md
petertonysmith94 Jun 3, 2025
8d8a1d4
Merge branch 'master' of github.com:FuelLabs/fuels-ts into ps/chore/u…
petertonysmith94 Jun 6, 2025
0a0dd2c
Update .changeset/full-carpets-lose.md
petertonysmith94 Jun 6, 2025
09d3bd1
Update .changeset/full-carpets-lose.md
petertonysmith94 Jun 6, 2025
6c42877
Only bump version
petertonysmith94 Jun 6, 2025
cd1d8fa
Testing with binaries committed
petertonysmith94 Jun 6, 2025
cead8c3
Added logging to binary finding
petertonysmith94 Jun 6, 2025
174a46e
Is it a faulty bin?
petertonysmith94 Jun 6, 2025
8b9ad15
Use correct architecture for Vercel
petertonysmith94 Jun 6, 2025
1d9d975
rollback bin changes
petertonysmith94 Jun 6, 2025
fd8e415
Remove binaries
petertonysmith94 Jun 9, 2025
fac685c
Install correct version
petertonysmith94 Jun 9, 2025
dbb5f3d
Testing publishing preview
petertonysmith94 Jun 9, 2025
9d361ba
deploy
petertonysmith94 Jun 9, 2025
3810b9c
Fix env
petertonysmith94 Jun 9, 2025
3c51531
Use correct argument
petertonysmith94 Jun 9, 2025
f45cc82
Move to output
petertonysmith94 Jun 9, 2025
db1c6ff
Removed CWD
petertonysmith94 Jun 9, 2025
e5ad884
Change dir
petertonysmith94 Jun 9, 2025
4dd2552
chore: added build
petertonysmith94 Jun 9, 2025
ce8a2b9
Added token
petertonysmith94 Jun 9, 2025
0b2db65
Added action
petertonysmith94 Jun 10, 2025
05be56a
Missing shell
petertonysmith94 Jun 10, 2025
edd8d56
Please build
petertonysmith94 Jun 10, 2025
63b5aed
Added debug
petertonysmith94 Jun 10, 2025
bb37a39
Use latest corepack
petertonysmith94 Jun 10, 2025
fe23ca4
Remove corepack version check
petertonysmith94 Jun 10, 2025
2fd4794
Added template build
petertonysmith94 Jun 10, 2025
65b08b8
Pull envs
petertonysmith94 Jun 10, 2025
a886c88
Delete `vercel.json`
petertonysmith94 Jun 10, 2025
273e4a5
Fix?
petertonysmith94 Jun 10, 2025
e8f2deb
Echo out deployment URL's
petertonysmith94 Jun 10, 2025
3a491c4
Echo out deployment URL's
petertonysmith94 Jun 10, 2025
6797d75
Added PR comment
petertonysmith94 Jun 10, 2025
f86d7a4
Revert "Only bump version"
petertonysmith94 Jun 10, 2025
80f7110
Revert "Added logging to binary finding"
petertonysmith94 Jun 10, 2025
f84e088
Merge branch 'master' of github.com:FuelLabs/fuels-ts into ps/chore/t…
petertonysmith94 Jun 10, 2025
892d530
Update id
petertonysmith94 Jun 10, 2025
1ccb280
Added conditional outcome comment
petertonysmith94 Jun 10, 2025
17992af
Pls
petertonysmith94 Jun 10, 2025
dea5919
Ensure all deployments successful
petertonysmith94 Jun 10, 2025
1776634
Added missing project ID
petertonysmith94 Jun 10, 2025
eacb56b
Added environment support for Vercel deploy
petertonysmith94 Jun 11, 2025
d27d289
Merge branch 'master' of github.com:FuelLabs/fuels-ts into ps/chore/u…
petertonysmith94 Jun 11, 2025
c1649f8
Fixed inputs
petertonysmith94 Jun 11, 2025
1a6704b
Single equality check
petertonysmith94 Jun 11, 2025
51bbc21
Added deployment for the releases
petertonysmith94 Jun 11, 2025
82593f0
Merge branch 'master' into ps/chore/test-fuel-core-update
petertonysmith94 Jun 11, 2025
b7820d5
Missing nightly option
petertonysmith94 Jun 11, 2025
d72e6de
Merge branch 'ps/chore/test-fuel-core-update' into ps/chore/upgrade-f…
petertonysmith94 Jun 11, 2025
a297318
Merge branch 'master' into ps/chore/upgrade-fuel-core-to-0.44.0
petertonysmith94 Jun 12, 2025
d8869b5
Merge branch 'master' into ps/chore/upgrade-fuel-core-to-0.44.0
petertonysmith94 Jun 12, 2025
0fffb2e
Added `assetId` to error message
petertonysmith94 Jun 12, 2025
44229fc
Merge branch 'master' into ps/chore/upgrade-fuel-core-to-0.44.0
petertonysmith94 Jun 12, 2025
9879da1
Merge branch 'master' into ps/chore/upgrade-fuel-core-to-0.44.0
Torres-ssf Jun 25, 2025
756c257
feat: Implemented changes from `fuel-core` for separation of errors
petertonysmith94 Jun 30, 2025
c65bd76
fix: Issue with `launchNode` not accepting a argument
petertonysmith94 Jun 30, 2025
7fa2860
fix: Issue with tests with built versions of `fuel-core`
petertonysmith94 Jun 30, 2025
96b52dd
Finalized the changes to error messages
petertonysmith94 Jul 2, 2025
e63cc1d
Removed redudant account methods
petertonysmith94 Jul 4, 2025
698e2e9
Added `startConsolidation` to the connectors
petertonysmith94 Jul 4, 2025
0e3783f
Implemented start consolidation on the account
petertonysmith94 Jul 4, 2025
b5d0e58
Fixed error message
petertonysmith94 Jul 4, 2025
563042e
Merge branch 'master' of github.com:FuelLabs/fuels-ts into ps/feat/au…
petertonysmith94 Jul 9, 2025
5d7bf5c
Merge branch 'master' into ps/chore/upgrade-fuel-core-to-0.44.0
petertonysmith94 Jul 9, 2025
4b03ab6
Updated PR
petertonysmith94 Jul 9, 2025
7e11a38
Merge branch 'ps/chore/upgrade-fuel-core-to-0.44.0' into ps/feat/auto…
petertonysmith94 Jul 9, 2025
dcdcfb5
Added tests for consolidation
petertonysmith94 Jul 9, 2025
54f26bf
Consolidate when using `getResourcesToSpend`
petertonysmith94 Jul 11, 2025
b5d39fe
feat: Added new `consolidateCoins` helper function with improved stra…
petertonysmith94 Jul 15, 2025
f78d488
Auto consolidate for contract calls
petertonysmith94 Jul 15, 2025
ae7149c
Lintfix
petertonysmith94 Jul 15, 2025
1ea29f3
Adhered to the pre-existing `consolidateCoins` method
petertonysmith94 Jul 16, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .changeset/full-carpets-lose.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"@internal/fuel-core": patch
"@fuel-ts/account": patch
"@fuel-ts/contract": patch
"fuels": patch
"@fuel-ts/program": patch
"@fuel-ts/utils": patch
"@fuel-ts/versions": patch
---

chore: upgrade `fuel-core` to `0.44.0`
1 change: 1 addition & 0 deletions .fuel-core/configs/chainConfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@
"mul": 2,
"muli": 2,
"mldv": 3,
"niop": 2,
"noop": 1,
"not": 2,
"or": 1,
Expand Down
2 changes: 1 addition & 1 deletion apps/create-fuels-counter-guide/fuel-toolchain.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ channel = "testnet"

[components]
forc = "0.68.7"
fuel-core = "0.43.1"
fuel-core = "0.44.0"
5 changes: 3 additions & 2 deletions apps/demo-bun-fuels/src/bun.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ describe('ExampleContract', () => {
} = launched;

const unfundedWallet = Wallet.generate({ provider });
const baseAssetId = await provider.getBaseAssetId();

const deploy = await SampleFactory.deploy(fundedWallet);
const { contract } = await deploy.waitForResult();
Expand All @@ -81,8 +82,8 @@ describe('ExampleContract', () => {
await expectToThrowFuelError(
() => contractInstance.functions.return_input(1337).simulate(),
new FuelError(
ErrorCode.INSUFFICIENT_FUNDS_OR_MAX_COINS,
`Insufficient funds or too many small value coins. Consider combining UTXOs.`
ErrorCode.INSUFFICIENT_FUNDS,
`Insufficient funds.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${unfundedWallet.address.toB256()}'.`
)
);
});
Expand Down
5 changes: 3 additions & 2 deletions apps/demo-fuels/src/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ describe('ExampleContract', () => {
} = launched;

const unfundedWallet = Wallet.generate({ provider });
const baseAssetId = await provider.getBaseAssetId();

const deploy = await SampleFactory.deploy(fundedWallet);
const { contract } = await deploy.waitForResult();
Expand All @@ -74,8 +75,8 @@ describe('ExampleContract', () => {
await expectToThrowFuelError(
() => contractInstance.functions.return_input(1337).simulate(),
new FuelError(
ErrorCode.INSUFFICIENT_FUNDS_OR_MAX_COINS,
`Insufficient funds or too many small value coins. Consider combining UTXOs.`
ErrorCode.INSUFFICIENT_FUNDS,
`Insufficient funds.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${unfundedWallet.address.toB256()}'.`
)
);
});
Expand Down
2 changes: 1 addition & 1 deletion apps/demo-nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"pretest": "pnpm original:build"
},
"dependencies": {
"@fuels/vm-asm": "0.60.2",
"@fuels/vm-asm": "0.62.0",
"@types/node": "22.13.5",
"@types/react-dom": "19.0.4",
"@types/react": "19.0.10",
Expand Down
2 changes: 1 addition & 1 deletion apps/demo-react-vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"pretest": "pnpm original:build"
},
"dependencies": {
"@fuels/vm-asm": "0.60.2",
"@fuels/vm-asm": "0.62.0",
"fuels": "workspace:*",
"react-dom": "19.0.0",
"react": "19.0.0"
Expand Down
5 changes: 3 additions & 2 deletions apps/demo-typegen/src/demo.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ it('should throw when simulating via contract factory with wallet with no resour
} = launched;

const unfundedWallet = Wallet.generate({ provider });
const baseAssetId = await provider.getBaseAssetId();

const factory = new DemoContractFactory(fundedWallet);
const { waitForResult } = await factory.deploy();
Expand All @@ -108,8 +109,8 @@ it('should throw when simulating via contract factory with wallet with no resour
await expectToThrowFuelError(
() => contractInstance.functions.return_input(1337).simulate(),
new FuelError(
ErrorCode.INSUFFICIENT_FUNDS_OR_MAX_COINS,
`Insufficient funds or too many small value coins. Consider combining UTXOs.`
ErrorCode.INSUFFICIENT_FUNDS,
`Insufficient funds.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${unfundedWallet.address.toB256()}'.`
)
);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,13 @@ const predicate = new SimplePredicate({

// Any amount coins will fail as the predicate is unfunded
const amountOfCoinsToFail = 1000;
const { error } = await safeExec(async () =>
predicate.transfer(
receiver.address,
amountOfCoinsToFail,
await provider.getBaseAssetId()
)
const baseAssetId = await provider.getBaseAssetId();
const { error } = await safeExec(() =>
predicate.transfer(receiver.address, amountOfCoinsToFail, baseAssetId)
);

// #region send-and-spend-funds-from-predicates-6
const errorMessage = `Insufficient funds or too many small value coins. Consider combining UTXOs.`;
const errorMessage = `Insufficient funds.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${predicate.address.toB256()}'.`;
// #endregion send-and-spend-funds-from-predicates-6

const actualErrorMessage = (<Error>error).message;
Expand Down
2 changes: 1 addition & 1 deletion internal/fuel-core/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.43.1
git:ps/fix/max-coins-error
2 changes: 1 addition & 1 deletion packages/account/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"@fuel-ts/transactions": "workspace:*",
"@fuel-ts/utils": "workspace:*",
"@fuel-ts/versions": "workspace:*",
"@fuels/vm-asm": "0.60.2",
"@fuels/vm-asm": "0.62.0",
"@noble/curves": "1.8.1",
"events": "3.3.0",
"graphql": "16.10.0",
Expand Down
40 changes: 35 additions & 5 deletions packages/account/src/account.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -602,8 +602,8 @@ describe('Account', () => {
await expectToThrowFuelError(
() => user.getResourcesToSpend([[1, ASSET_A]], { utxos: [assetAUTXO.id] }),
new FuelError(
ErrorCode.INSUFFICIENT_FUNDS_OR_MAX_COINS,
`Insufficient funds or too many small value coins. Consider combining UTXOs.`
ErrorCode.INSUFFICIENT_FUNDS,
`Insufficient funds.\n\tAsset ID: '${ASSET_A}'.\n\tOwner: '${user.address.toB256()}'.`
)
);
});
Expand Down Expand Up @@ -975,13 +975,43 @@ describe('Account', () => {
wallets: [wallet],
provider,
} = launched;
const baseAssetId = await provider.getBaseAssetId();

const request = new ScriptTransactionRequest();
request.addCoinOutput(wallet.address, 30_000, await provider.getBaseAssetId());
request.addCoinOutput(wallet.address, 30_000, baseAssetId);

await expectToThrowFuelError(() => request.estimateAndFund(wallet), {
code: ErrorCode.INSUFFICIENT_FUNDS_OR_MAX_COINS,
message: 'Insufficient funds or too many small value coins. Consider combining UTXOs.',
code: ErrorCode.MAX_COINS_REACHED,
message: `You have too many small value coins - consider combining UTXOs.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${wallet.address.toB256()}'.`,
});
});

it('throws when funding with more than 255 coins for an input', async () => {
using launched = await setupTestProviderAndWallets({
walletsConfig: {
amountPerCoin: 100,
coinsPerAsset: 400,
},
});
const {
wallets: [wallet],
provider,
} = launched;
const baseAssetId = await provider.getBaseAssetId();

const request = new ScriptTransactionRequest();
request.addCoinOutput(wallet.address, 30_000, baseAssetId);

const assembleTx = () =>
provider.assembleTx({
request,
feePayerAccount: wallet,
accountCoinQuantities: [{ amount: 30_000, assetId: baseAssetId }],
});

await expectToThrowFuelError(assembleTx, {
code: ErrorCode.MAX_COINS_REACHED,
message: `You have too many small value coins - consider combining UTXOs.\n\tAsset ID: '${baseAssetId}'.\n\tOwner: '${wallet.address.toB256()}'.`,
});
});

Expand Down
Loading
Loading