bitcoinz-wallets / bitcoinz-copay-wallet

BitcoinZ Wallet - Copay Port
MIT License
11 stars 28 forks source link

Error Querying Blockchain #15

Open renuzit opened 6 years ago

renuzit commented 6 years ago

A user tried to send a transaction for 23500 BTCz and instead got an error message Error Querying Blockchain. When the user sent a smaller amount of 8000 BTCz, the transaction went through.

renuzit commented 6 years ago

slack-imgs

egyptianbman commented 6 years ago

The actual error was a PayloadTooLargeError coming back from the explorer.

bb2k16 commented 6 years ago

Just added information, tried on both lastest version of android and Linux. Both same issue.

panickz commented 6 years ago

What's the server the app is running ? Nginx?

egyptianbman commented 6 years ago

I forgot to post back an update on this. Basically, the issue is believed to be transaction fees were too high. I'm not sure why too high of a tx fee causes failure but lowering the tx fee to economy or manually setting to 0.0001 works.

@panickz there are several servers behind this -- nginx is the primary proxy. If you're thinking payoad as in the body size is too large, I don't think that's the case. I'm not 100% convinced of that, but I don't see how changing a tx fee would change the body of the request by that much.

Ostseebengel commented 6 years ago

Under 5000 BTCZ and the network fee on Super Economy worked for me.

renuzit commented 6 years ago

I had this happen to me today. It seems as if there are a bunch of UTXO, then it can take a while to calculate the total to create the transaction. My theory is that the request on the webserver side timesout and we get the error.

egyptianbman commented 6 years ago

I don't think that's related -- it may be another issue throwing the same error.

This issue seems to relate to what we see in the swing wallet, even. I think you'll get failure if you try to send a tx with 1 BTCZ fee.

egyptianbman commented 6 years ago

An update on this. BWS is returning the following error:

ERR! /v2/wallets/?includeExtendedInfo=0&twoStep=1&r=45524 :500:Error querying the blockchain
WARN Insight https://explorer.btcz.rocks:443/api/utils/estimatefee?nbBlocks=2,3,4,5,6,7,8,24,25,26 Returned Status: 400
Error estimating fee Error querying the blockchain

Going to that url for the explorer yields the following response:

{
  2: -1,
  3: -1,
  4: -1,
  5: -1,
  6: -1,
  7: -1,
  8: -1,
  24: -1,
  25: -1,
  26: -1,
}

This call to the explorer happens a lot. It's always a GET request so I think ultimately, there is a bug around there. I can't imagine -1 is the expected response. I'll see if I can figure out what's going on in the explorer.

lorenzo-paglia commented 6 years ago

Thanks for help

On 13 Mar 2018 08:54, "Beshoy Girgis" notifications@github.com wrote:

An update on this. BWS is returning the following error:

ERR! /v2/wallets/?includeExtendedInfo=0&twoStep=1&r=45524 :500:Error querying the blockchain WARN Insight https://explorer.btcz.rocks:443/api/utils/estimatefee?nbBlocks=2,3,4,5,6,7,8,24,25,26 Returned Status: 400 Error estimating fee Error querying the blockchain

Going to that url for the explorer yields the following response:

{ 2: -1, 3: -1, 4: -1, 5: -1, 6: -1, 7: -1, 8: -1, 24: -1, 25: -1, 26: -1, }

This call to the explorer happens a lot. It's always a GET request so I think ultimately, there is a bug around there. I can't imagine -1 is the expected response. I'll see if I can figure out what's going on in the explorer.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/bitcoinz-wallets/bitcoinz-copay-wallet/issues/15#issuecomment-372576946, or mute the thread https://github.com/notifications/unsubscribe-auth/AhhIFMVGMkwO-c1rtyM2cup3abMSkowdks5td3sogaJpZM4RVoUK .

renuzit commented 6 years ago

@egyptianbman Maybe we should try to add more explorers to the list?

egyptianbman commented 6 years ago

How would that resolve this issue?

renuzit commented 6 years ago

It makes me feel that the explorer is getting overwhelmed or something.

egyptianbman commented 6 years ago

Not at all. The server can handle at least 1000x what it's receiving right now.

In addition, I just finished setting up a local dev explorer to test on and the same thing is happening, with no traffic at all.

image

renuzit commented 6 years ago

So wait, the error querying blockchain is coming from the estimatedFee route?

egyptianbman commented 6 years ago

From the BWS log:

ERR! /v2/wallets/?includeExtendedInfo=0&twoStep=1&r=45524 :500:Error querying the blockchain
WARN Insight https://explorer.btcz.rocks:443/api/utils/estimatefee?nbBlocks=2,3,4,5,6,7,8,24,25,26 Returned Status: 400
Error estimating fee Error querying the blockchain
egyptianbman commented 6 years ago

This may be a blockchain issue: image

egyptianbman commented 6 years ago

But I don't know that it's an actual problem. Testing on the zcash daemon, I get -1 when trying to estimate a fee for nblocks of 1. From 2 to 25, I get 0.00002491. Above 25, I get -1 again.

futurewwwwww commented 2 years ago

I'm having the same problem, but different from transactions, it appears when I try to import my wallet, I'm not able to log in the wallet in the app, this message appears right after I type the private words. I can't access my wallet, I'm desperate! Can someone help me? 20220227_101222