-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG: Returned values aren't valid #1
Comments
Fun fact. it seems it was a temporary issue, works now (with not so many trades set as null + error). Still, if a trade has error I wonder why does it even show up in the results... |
Actually, still having the same issue: Trying to calculate a trade from Avalanche (AVAX) to Polygon (MATIC) and I get all trades null in the results, as in the screenshow above. I I try the same trade using the official rubic exchange, of course there it works: Can it be because I'm working on localhost? UPDATE You can test using my example, I added avalanche and more coins to test: See PR #2 |
I also migrated the react example to rubic sdk v3, in case it helps: https://github.com/firepol/rubic-sdk-example/tree/rubic-sdk-v3 |
Hi, please try the react example in this repo.
In the
Form.tsx
fileAfter
const wrappedTrades = await (sdk.crossChain.calculateTrade(fromToken, String(amount), toToken))
Add:
console.log(wrappedTrades)
Try to calculate a swap between BNB and Polygon, amount 1.
I get in the browser console a bunch of errors with trade set to null.
Errors for all trades:
Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.
Are you experiencing some issues right now or...?
I think a few days ago it was working...
The text was updated successfully, but these errors were encountered: