shohu / c0ban

c0ban source tree
MIT License
0 stars 0 forks source link

Pass signlogic for sendheaders.py #56

Closed shohu closed 6 years ago

shohu commented 6 years ago
# test/functional/sendheaders.py
2018-07-11 05:23:10.403000 TestFramework (INFO): Initializing test directory /tmp/test9u2an9zn
2018-07-11 05:23:10.892000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:11320
2018-07-11 05:23:10.892000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:11320
2018-07-11 05:23:11.154000 TestFramework (INFO): Part 1: headers don't start before sendheaders message...
2018-07-11 05:23:11.669000 TestFramework (INFO): Part 1: success!
2018-07-11 05:23:11.669000 TestFramework (INFO): Part 2: announce blocks with headers after sendheaders message...
2018-07-11 05:23:21.068000 TestFramework (INFO): Part 2: success!
2018-07-11 05:23:21.068000 TestFramework (INFO): Part 3: headers announcements can stop after large reorg, and resume after headers/inv from peer...
2018-07-11 05:23:22.767000 TestFramework (INFO): Part 3: success!
2018-07-11 05:23:22.767000 TestFramework (INFO): Part 4: Testing direct fetch behavior...
2018-07-11 05:23:23.560000 TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/c0ban/test/functional/test_framework/test_framework.py", line 120, in main
    self.run_test()
  File "test/functional/sendheaders.py", line 467, in run_test
    test_node.wait_for_getdata([x.sha256 for x in blocks[2:16]], timeout=direct_fetch_response_time)
  File "test/functional/sendheaders.py", line 158, in wait_for_getdata
    wait_until(test_function, timeout=timeout, lock=mininode_lock)
  File "/c0ban/test/functional/test_framework/util.py", line 222, in wait_until
    assert_greater_than(timeout, time.time())
  File "/c0ban/test/functional/test_framework/util.py", line 42, in assert_greater_than
    raise AssertionError("%s <= %s" % (str(thing1), str(thing2)))
AssertionError: 1531286603.5590484 <= 1531286603.5605059
2018-07-11 05:23:23.583000 TestFramework (INFO): Stopping nodes
2018-07-11 05:23:25.728000 TestFramework (WARNING): Not cleaning up dir /tmp/test9u2an9zn
2018-07-11 05:23:25.728000 TestFramework (ERROR): Test failed. Test logging available at /tmp/test9u2an9zn/test_framework.log
shohu commented 6 years ago

I passed this test. But I can't find cause error before

 test/functional/sendheaders.py
2018-07-12 06:14:48.457000 TestFramework (INFO): Initializing test directory /tmp/testq6h9ui9l
2018-07-12 06:14:48.951000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:15950
2018-07-12 06:14:48.951000 TestFramework.mininode (INFO): Connecting to Bitcoin Node: 127.0.0.1:15950
2018-07-12 06:14:49.210000 TestFramework (INFO): Part 1: headers don't start before sendheaders message...
2018-07-12 06:14:49.686000 TestFramework (INFO): Part 1: success!
2018-07-12 06:14:49.687000 TestFramework (INFO): Part 2: announce blocks with headers after sendheaders message...
2018-07-12 06:14:59.151000 TestFramework (INFO): Part 2: success!
2018-07-12 06:14:59.151000 TestFramework (INFO): Part 3: headers announcements can stop after large reorg, and resume after headers/inv from peer...
2018-07-12 06:15:00.803000 TestFramework (INFO): Part 3: success!
2018-07-12 06:15:00.803000 TestFramework (INFO): Part 4: Testing direct fetch behavior...
2018-07-12 06:15:01.702000 TestFramework (INFO): Part 4: success!
2018-07-12 06:15:01.706000 TestFramework (INFO): Part 5: Testing handling of unconnecting headers
2018-07-12 06:15:10.940000 TestFramework (INFO): Part 5: success!
2018-07-12 06:15:10.941000 TestFramework (INFO): Stopping nodes
2018-07-12 06:15:13.081000 TestFramework (INFO): Cleaning up
2018-07-12 06:15:13.084000 TestFramework (INFO): Tests successful