Skip to content

transactions not always confirming #2223

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

Closed
bladedoyle opened this issue Dec 24, 2018 · 9 comments
Closed

transactions not always confirming #2223

bladedoyle opened this issue Dec 24, 2018 · 9 comments

Comments

@bladedoyle
Copy link
Contributor

bladedoyle commented Dec 24, 2018

NOTE: This may be due to #2266 - I was previously missing the error from finalize step so these tx remaining unconfirmed are probably caused by that.

I have a very low success rate getting transactions to confirm on FlooNet. Most dont confirm without being re-posted at least once. Here is a partial log of a wallet getting payments that remain unconfirmed:

Transaction Log - Account 'default' - Block Height: 5333
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 Id  Type         Shared Transaction Id                 Creation Time        Confirmed?  Confirmation Time    Num.    Num.     Amount         Amount         Fee    Net            Tx  
                                                                                                              Inputs  Outputs  Credited       Debited               Difference     Data 
===============================================================================================================================================================================================================================
 0   Received Tx  e58aa50d-b915-40ae-8a1c-250b2b42da9b  2018-12-22 22:06:37  false       None                 0       1        6.66           0.0            None   6.66           None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 1   Received Tx  bba39041-013d-4353-8685-2d534113bccd  2018-12-23 06:00:11  false       None                 0       1        46.794808853   0.0            None   46.794808853   None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 2   Received Tx  5f3ebee4-af6f-40b6-b6ca-fd4e9d9c0a42  2018-12-23 07:19:01  false       None                 0       1        396.844134324  0.0            None   396.844134324  None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 3   Received Tx  6289d8f7-2af7-4455-af68-da170fb4afb0  2018-12-23 07:56:39  true        2018-12-23 08:05:45  0       1        19.860068966   0.0            None   19.860068966   None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 4   Received Tx  4d738263-cbd2-482b-994f-448873a9e540  2018-12-23 09:00:10  false       None                 0       1        112.085067297  0.0            None   112.085067297  None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 5   Received Tx  dc12cbad-b01c-46c3-8cc6-c1606e25aacc  2018-12-23 10:00:08  false       None                 0       1        77.091452864   0.0            None   77.091452864   None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 6   Received Tx  514260d2-4136-436a-9a20-2e2d03d53f8b  2018-12-23 11:00:09  false       None                 0       1        215.140037689  0.0            None   215.140037689  None 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 7   Received Tx  f86f9b80-8dfe-4035-aa29-60a0f909ad76  2018-12-23 12:00:09  false       None                 0       1        37.154763314   0.0            None   37.154763314   None 
...
...
@pavoltravnik
Copy link

pavoltravnik commented Dec 24, 2018

Same here, I did multiple transactions between nodes with 0 confirmations and Coins are not Spendable anymore.

@bladedoyle
Copy link
Contributor Author

bladedoyle commented Dec 26, 2018

I see the following errors in my wallet log which I believe are related to this problem. I notice that the re-post will also sometimes fail with this error. These tx do eventually post after trying a few times.

20181226 18:37:41.318 INFO grin - This is Grin version 0.4.2 (git v0.4.2-88-gbc77803), built for x86_64-unknown-linux-gnu by rustc 1.31.0 (abe02cefd 2018-12-04).
20181226 18:37:41.318 DEBUG grin - Built with profile "release", features "".
20181226 18:37:41.318 DEBUG grin_wallet::types - Using wallet seed file at: /wallet/wallet_data/wallet.seed
20181226 18:37:41.322 INFO grin_wallet - Using LMDB Backend for wallet
20181226 18:37:41.322 DEBUG grin_wallet::types - Using wallet seed file at: /wallet/wallet_data/wallet.seed
20181226 18:37:41.350 DEBUG grin_wallet::libwallet::internal::updater - Refreshing wallet outputs
20181226 18:37:48.279 ERROR grin_wallet::libwallet::api - api: post_tx: failed with error: Client Callback Error: Posting transaction to node

and from grin server log:

20181226 17:18:45.118 INFO grin_api::handlers::pool_api - Pushing transaction e4951b0f to pool (inputs: 1, outputs: 2, kernels: 1)
20181226 17:18:45.121 ERROR grin_api::handlers::pool_api - update_pool: failed with error: Other("failed to validate tx")

@bladedoyle
Copy link
Contributor Author

For the owner_api there is no repost_tx method, and calling the post_tx method again does not seem to work. I get these results:

20181228 18:15:55.228 DEBUG grin_wallet::types - Using wallet seed file at: /wallet/wallet_data/wallet.seed
20181228 18:15:55.307 ERROR grin_wallet::libwallet::api - api: post_tx: failed with error: Client Callback Error: Posting transaction to node
20181228 18:15:55.308 ERROR grin_wallet::controller - post_tx: failed with error: Client Callback Error: Posting transaction to node
20181228 18:15:55.308 ERROR grin_wallet::controller - Request Error: Error { inner: Error { inner: 

Request error: Wrong response code }

Client Callback Error: Posting transaction to node }

@0xmichalis
Copy link
Contributor

I saw the "failed to validate tx" error in the server in my own tx confirmation issue when I tried to re-finalize my transaction. It had been already transmitted and confirmed. The error message could definitely improve in the wallet's side ("you are trying to re-transmit an already confirmed transaction"?). I managed to fix my wallet state by running grin wallet restore.

@bladedoyle
Copy link
Contributor Author

I dont believe they are already confirmed. My wallet shows them as confirmed=false. Here is a (small) sample of my currently unconfirmed tx:

root@grinwallet:/wallet# grin wallet txs | grep false

 108   Sent Tx      e58aa50d-b915-40ae-8a1c-250b2b42da9b  2018-12-22 22:06:37  false       None                 1       1        53.332           60.0             0.008  -6.668           e58aa50d-b915-40ae-8a1c-250b2b42da9b.grintx 
 112   Send Tx      6a4e6791-aa8b-4a05-89e8-2dba2bfd6734  2018-12-22 23:07:17  false       None                 1       1        3.804034582      60.0             0.008  -56.195965418    6a4e6791-aa8b-4a05-89e8-2dba2bfd6734.grintx 
 121   Send Tx      c37da5d4-2b67-4e56-851c-0d5d3c414ed2  2018-12-22 23:48:11  false       None                 1       1        53.332           60.0             0.008  -6.668           c37da5d4-2b67-4e56-851c-0d5d3c414ed2.grintx 
 147   Sent Tx      bba39041-013d-4353-8685-2d534113bccd  2018-12-23 06:00:11  false       None                 2       1        50.330225729     97.132034582     0.007  -46.801808853    bba39041-013d-4353-8685-2d534113bccd.grintx 
 166   Sent Tx      5f3ebee4-af6f-40b6-b6ca-fd4e9d9c0a42  2018-12-23 07:19:02  false       None                 7       1        23.153865676     420.0            0.002  -396.846134324   5f3ebee4-af6f-40b6-b6ca-fd4e9d9c0a42.grintx 
 183   Sent Tx      4d738263-cbd2-482b-994f-448873a9e540  2018-12-23 09:00:10  false       None                 3       1        48.040863737     160.131931034    0.006  -112.091067297   4d738263-cbd2-482b-994f-448873a9e540.grintx 
 195   Sent Tx      dc12cbad-b01c-46c3-8cc6-c1606e25aacc  2018-12-23 10:00:08  false       None                 2       1        42.901547136     120.0            0.007  -77.098452864    dc12cbad-b01c-46c3-8cc6-c1606e25aacc.grintx 
 200   Sent Tx      514260d2-4136-436a-9a20-2e2d03d53f8b  2018-12-23 11:00:09  false       None                 4       1        24.854962311     240.0            0.005  -215.145037689   514260d2-4136-436a-9a20-2e2d03d53f8b.grintx 
 208   Sent Tx      f86f9b80-8dfe-4035-aa29-60a0f909ad76  2018-12-23 12:00:09  false       None                 1       1        22.837236686     60.0             0.008  -37.162763314    f86f9b80-8dfe-4035-aa29-60a0f909ad76.grintx 
 218   Sent Tx      e9603c59-d377-41e7-9e09-e5e9be60f95f  2018-12-23 13:00:09  false       None                 2       1        10.979477159     120.0            0.007  -109.020522841   e9603c59-d377-41e7-9e09-e5e9be60f95f.grintx 
 221   Sent Tx      d73bdb4b-641d-45dd-a6e3-e1c0d250badd  2018-12-23 14:00:08  false       None                 3       1        16.473996591     180.0            0.006  -163.526003409   d73bdb4b-641d-45dd-a6e3-e1c0d250badd.grintx 
 224   Sent Tx      28108102-e825-4c63-b57f-592a71ec2165  2018-12-23 15:00:08  false       None                 4       1        53.002687159     240.0            0.005  -186.997312841   28108102-e825-4c63-b57f-592a71ec2165.grintx 
 230   Sent Tx      a8db9d7c-c235-4c6f-a532-dfe6066a1760  2018-12-23 16:00:13  false       None                 4       1        42.395872054     240.0            0.005  -197.604127946   a8db9d7c-c235-4c6f-a532-dfe6066a1760.grintx 
 234   Sent Tx      726cad78-cf4b-4324-af3e-1c248bc67fd3  2018-12-23 17:00:09  false       None                 2       1        8.922930297      120.0            0.007  -111.077069703   726cad78-cf4b-4324-af3e-1c248bc67fd3.grintx 
 238   Sent Tx      ce1f58fd-ec35-4d43-89b1-8bb35d5d326a  2018-12-23 18:00:12  false       None                 1       1        40.927961749     60.0             0.008  -19.072038251    ce1f58fd-ec35-4d43-89b1-8bb35d5d326a.grintx 

@0xmichalis
Copy link
Contributor

You might as well try grin wallet restore and see whether that fixes your issue. Floonet is relaunched today.

@pavoltravnik
Copy link

You might as well try grin wallet restore and see whether that fixes your issue. Floonet is relaunched today.

It worked, but it is definitely a bug if 0 confirmation transactions behave like this.

@0xmichalis
Copy link
Contributor

Yes, it sounds like a bug in the wallet to me.

@bladedoyle
Copy link
Contributor Author

Im closing this. My issue was resolved with this fix:
c45486f

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants