aitos-io / BoAT-X-Framework

BoAT-X Blockchain Application Framework for IoT
http://www.aitos.io
Apache License 2.0
926 stars 49 forks source link

platon_ Call query error #1329

Closed zzqAlex closed 1 year ago

zzqAlex commented 1 year ago

Query interface without state change: platon_ Call, return the error of insufficient account balance:

LOG_VERBOSE: curlport.c:302, CurlPortRequestSync(): Post: {“jsonrpc”:“2.0”,“method”:“platon_call”,“params”:[{“to”:“lat1d5d09nnegcv72sj7a33uwn6vlzup9l25nj73k5”,“gas”:“0x9fffff”,“gasPrice”:“0x12a05ff00”,“data”:“0x17d7de7c”},“latest”],“id”:559325346} LOG_VERBOSE: curlport.c:303, CurlPortRequestSync(): Result Code: 200 LOG_VERBOSE: curlport.c:304, CurlPortRequestSync(): Response: {“jsonrpc”:“2.0”,“id”:559325346,“error”:{“code”:-32000,“message”:“err: insufficient balance to pay for gas (supplied gas 10485759)”}}

zzqAlex commented 1 year ago

Reason: platon needs to add the "from" field in the rpc message to identify the sender address