Instadapp / dsa-sdk

Build DeFi apps instantly using our SDK
MIT License
79 stars 23 forks source link

running build() without parameters causes (node:22117) UnhandledPromiseRejectionWarning: Error: `gasPrice` is not defined. #108

Open paulvi opened 3 years ago

paulvi commented 3 years ago

https://docs.instadapp.io/setup/ shows example as

dsa.build().then(console.log);

and says that build has

an optional Object parameter

However running build() without parameters causes

(node:22117) UnhandledPromiseRejectionWarning: Error: gasPrice is not defined. at f.exports.getTxObj (/Users/user/Workspaces/Ethereum/Instadapp/instadapp-get-started/node_modules/dsa-sdk/build/dsa.min.js:12:395221) at processTicksAndRejections (internal/process/task_queues.js:93:5) at async /Users/user/Workspaces/Ethereum/Instadapp/instadapp-get-started/node_modules/dsa-sdk/build/dsa.min.js:12:41342 (

So either docs or current version of sdk are wrong.

Sowmayjain commented 3 years ago

@paulvi could you use this SDK instead?

https://github.com/instadapp/dsa-connect

paulvi commented 3 years ago

Do you mean that "Documentation" link from https://instadapp.io/ was wrong and the content of https://docs.instadapp.io/ is of no use?

So https://github.com/instadapp/dsa-connect is newer SDK version