sway
sway copied to clipboard
`forc deploy` improve error message for insufficient coins
When running
forc deploy --url node-beta-2.fuel.network/graphql --gas-price 1
on forc 0.33.1 with a forc wallet account that does not have enough coins for deployment the error message is
Error: Provider error: Response errors; not enough resources to fit the target
The message isn't immediately clear as to what the issue is.
If this issue persists in newer releases then it would be good to be more specific.
Hmm we are simply outputting the error message provided by the client which is defined here:
https://github.com/FuelLabs/fuel-core/blob/ce64223296537cecf5b8c2e2892e31e2f98fc9a5/crates/fuel-core/src/resource_query.rs#L34
I guess we have two options here:
- Improve the error message in fuel-core
- If this error message is sent by the client, somehow alter it and display the altered version