Skip to content
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

Intermittent connection failure in app_test #39

Closed
vikramrajkumar opened this issue Jan 17, 2017 · 3 comments · Fixed by #2374
Closed

Intermittent connection failure in app_test #39

vikramrajkumar opened this issue Jan 17, 2017 · 3 comments · Fixed by #2374

Comments

@vikramrajkumar
Copy link
Contributor

vikramrajkumar commented Jan 17, 2017

From @theoreticalbts on July 14, 2015 22:24

After fixing generally obsolete app_test in cfd9dd0 I notice that every few runs, I get the following error:

$ sudo -u graphene -H tests/app_test --log_level=message
Running 1 test case...
Creating temporary files
Creating and initializing app1
Creating and initializing app2
Starting app1 and waiting 500 ms
1209829ms th_a       application.cpp:190           operator()           ] Initializing database...
1209838ms th_a       application.cpp:63            create_example_genes ] Allocating all stake to 5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
1209843ms th_a       thread.cpp:95                 thread               ] name:p2p tid:139731355076352
1209845ms th_a       application.cpp:118           reset_p2p_node       ] Configured p2p node to listen on 127.0.0.1:3939
Starting app2 and waiting 500 ms
1210345ms th_a       application.cpp:190           operator()           ] Initializing database...
1210345ms th_a       application.cpp:63            create_example_genes ] Allocating all stake to 5KQwrPbwdL6PhXujxW37FSSQZ1JiwsST4cqQzDeyXtP79zkvFD3
1210349ms th_a       thread.cpp:95                 thread               ] name:p2p tid:139731255420672
1210350ms th_a       application.cpp:107           reset_p2p_node       ] Adding seed node 127.0.0.1:3939
1210351ms th_a       application.cpp:118           reset_p2p_node       ] Configured p2p node to listen on 127.0.0.1:4040
/home/cc/graphene/src/graphene/tests/app/main.cpp(74): fatal error in "two_node_network": critical check app1.p2p_node()->get_connection_count() == 1 failed [0 != 1]
1210852ms th_a       thread.cpp:115                ~thread              ] calling quit() on p2p
1210852ms th_a       thread.cpp:160                quit                 ] destroying boost thread 139731255420672
1210890ms th_a       thread.cpp:115                ~thread              ] calling quit() on p2p
1210890ms th_a       thread.cpp:160                quit                 ] destroying boost thread 139731355076352
1210890ms p2p        thread.cpp:246                exec                 ] thread canceled: 9 canceled_exception: Canceled
cancellation reason: [none given]
    {"reason":"[none given]"}
    p2p  thread_d.hpp:463 start_next_fiber

*** 1 failure detected in test suite "Test Application"

This does not happen on every run, but usually shows up after several runs, if you don't see it after ~10 runs then I would assume your environment is unable to reproduce it.

A similar bug in the past was cryptonomex/graphene#55

Copied from original issue: cryptonomex/graphene#159

@vikramrajkumar
Copy link
Contributor Author

Too old

OpenLedgerApp pushed a commit to openledger/bitshares-core that referenced this issue Mar 7, 2019
…market-fee/CORE-841 to dynamic-market-fee/develop

Squashed commit of the following:

commit 7ea2755b10b366736444246752c0ee33a127ecfe
Author: Dmitry Yakovitsky <[email protected]>
Date:   Fri Jan 25 16:55:48 2019 +0300

    CORE-841 Add trade_statistics_object + index. Fix notes.

commit 1fa547cb8a7eaa15262b48d8e0b1647d2e6327aa
Merge: 34a43a4 9fcdccd
Author: Dmitry Yakovitsky <[email protected]>
Date:   Fri Jan 25 16:26:49 2019 +0300

    Merge branch 'dynamic-market-fee/CORE-841' of https://bitbucket.aeteh.com/scm/dev/bitshares-worker into dynamic-market-fee/CORE-841

commit 34a43a47952ca59542e1c43506044026e11f0235
Author: Dmitry Yakovitsky <[email protected]>
Date:   Fri Jan 25 16:22:46 2019 +0300

    CORE-841 Add trade_statistics_object + index. Fix notes.
    Use HARDFORK_DYNAMIC_FEE_TIME.

commit 17aa3757879e2e2c221858028682192987275d45
Author: Dmitry Yakovitsky <[email protected]>
Date:   Fri Jan 25 14:11:34 2019 +0300

    CORE-841 Add trade_statistics_object + index. Fix notes

commit 6bf0b31954aa3e03a8f50733bf55cb5b1bfcc86c
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 19:37:51 2019 +0300

    CORE-841 Add trade_statistics_object + index.

commit 21109a0a54679b39133de7e4d7a47d30cdb74e26
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 18:52:13 2019 +0300

    CORE-841 Add trade_statistics_object + index.

commit 3f3ce0ee35869c8b75886f14d968374bd8ba4b0d
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 16:40:48 2019 +0300

    CORE-841 Add trade_statistics_object + index. revert account_object.hpp

commit 0e1575e3bbab5c19e06e4df8f3d1a7d788674d51
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 11:39:24 2019 +0300

    CORE-841 Add trade_statistics_object + index. Fix UT

commit 2e910da2f74f1b5d4d4aa4cb011f1230c5e27651
Author: Dmitry Yakovitsky <[email protected]>
Date:   Wed Jan 16 13:11:56 2019 +0300

    CORE-841 Add trade_statistics_object + index

commit 3463741040614b7155fcf76a1db3d11bc89ac3cd
Author: Dmitry Yakovitsky <[email protected]>
Date:   Fri Jan 25 12:37:16 2019 +0300

    CORE-851 Create dynamic market fee hardfork

commit 9fcdccd572428792bff5e139b83abcc621510399
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 19:37:51 2019 +0300

    CORE-841 Add trade_statistics_object + index.

commit f2c69b0ef323a648532e13d3446808dce566d901
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 18:52:13 2019 +0300

    CORE-841 Add trade_statistics_object + index.

commit af7a2bd1ac438bcc3e6a4a6aa3d205ef4c52e05a
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 16:40:48 2019 +0300

    CORE-841 Add trade_statistics_object + index. revert account_object.hpp

commit 19846687698b31d8b8c78893ed183e679dceab11
Author: Dmitry Yakovitsky <[email protected]>
Date:   Mon Jan 21 11:39:24 2019 +0300

    CORE-841 Add trade_statistics_object + index. Fix UT

commit 74cfda21f3e3cbfb12a5e5f9de0dd47ad060d878
Author: Dmitry Yakovitsky <[email protected]>
Date:   Wed Jan 16 13:11:56 2019 +0300

    CORE-841 Add trade_statistics_object + index
@abitmore abitmore reopened this Mar 6, 2021
@abitmore abitmore added this to the Future Feature Release milestone Mar 6, 2021
@abitmore
Copy link
Member

abitmore commented Mar 9, 2021

This was probably a timing issue which should have been fixed in #2062. The related commits are a96aa5a, 471abef and fc826a5.

However, there is another bug introduced in #804 which leads to random connection issues too. The two nodes may be initialized with different genesis due to the bug. It will be fixed in #2374. For convenience that pull request will be linked to this issue, although strictly speaking it is not for this issue.

@abitmore abitmore linked a pull request Mar 9, 2021 that will close this issue
@abitmore
Copy link
Member

abitmore commented Mar 9, 2021

Fixed by #2374.

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

Successfully merging a pull request may close this issue.

2 participants