Even after providing tx policies with large limits, it didn’t help. The error is coming from some validation logic, where rust SDK fails to correctly estimate the fee amount it needs to provide for the transaction. And this logic ignores the provided tx policies
I resolved the issue by deploying the contract using forc deploy, but this should be fixed in the SDK as well. I can provide the bin and abi files of the contract if needed. Here’s the address of the contract on testnet (deployed via forc): 0x3faf84f2188b67d18055704b9001945a871fa24f86324761f630941eb6885ba5
Hey @mpoplavkov, it seems to be related to an already open issue here. However, there is a workaround for it here that you can use and you will be unblocked by it.
That might be related indeed, but in my case - I’m trying to deploy the contract, not call its function. And as I mentioned, setting a high script gas limit doesn’t solve the issue in my case
Hey @mpoplavkov, sorry for the delay. I coordinated with the team on this.
So, the initial error was fixed by them upgrading to 0.63.0 from what I understand, and I was right to say that it is related to an open issue. the remaining problem with the InsufficientMaxFee will be fixed as part of the same issue. unfortunately, we can’t merge it right away because we need a PR to land in a release of fuel-core (that we will release it hopefully this week).
TLDR; we have to wait for this release to get the PR for that issue to be merged.
if your work is important and is being blocked by this currently, someone from the sdk can probably find a workaround for you. but I guess you’ve found it already with forc deploy.
Also, chances are you’re not applying the TxPolicies here correctly, since your error message says max_fee_from_policies: 188268, while you are setting a different amount judging from the snippet