The code below makes a “Error: Unknown field “status” on type “Message”” Error. How ever .get() does work. await contract.functions.max_supply().get();
const v = await contract.functions.mint()
.txParams({ gasPrice: 1 })
.call();
Error: Unknown field "status" on type "Message".: {"response":{"data":null,"errors":[{"message":"Unknown field \"status\" on type \"Message\".","locations":[{"line":28,"column":3}]}],"status":200,"headers":{"map":{"content-type":"application/json"}}},"request":{"query":"query getResourcesToSpend($owner: Address!, $queryPerAsset: [SpendQueryElementInput!]!, $excludedIds: ExcludeInput) {\n resourcesToSpend(\n owner: $owner\n queryPerAsset: $queryPerAsset\n excludedIds: $excludedIds\n ) {\n ...coinFragment\n ...messageFragment\n }\n}\n\nfragment coinFragment on Coin {\n utxoId\n owner\n amount\n assetId\n maturity\n coinStatus: status\n blockCreated\n}\n\nfragment messageFragment on Message {\n amount\n sender\n recipient\n data\n nonce\n messageStatus: status\n daHeight\n}","variables":{"owner":"0xf37e242bb530789a5714c01c2cd266ea5d9c7c5d802c5a64c00e77b60e79dcca","queryPerAsset":[{"assetId":"0x0000000000000000000000000000000000000000000000000000000000000000","amount":"100"}],"excludedIds":{"messages":[],"utxos":[]}}}}
at index.ts:498:1
at step (graphql-ws.ts:280:1)
at Object.next (graphql-ws.ts:280:1)
at fulfilled (graphql-ws.ts:280:1)
I deployed in testnet(beta2) and fuel version looks like 0.30.
I found the version in Cargo.toml. fuels = { version = "0.30", features = ["fuel-core-lib"] }
ok yeah this is a version mismatch. What you should do is type the command fuelup default beta-2 this should give you the correct toolchain to use with the beta-2 testnet. This error occurs bc the beta-2 testnet is on fuel-core version 0.15.1 which compatible with forc v 0.31.1 and fuels v0.30.0 (iirc).