[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #22902 [Core Tor/Stem]: run_tests.py hangs in process or control.controller



#22902: run_tests.py hangs in process or control.controller
---------------------------+-----------------------------------
 Reporter:  catalyst       |          Owner:  atagar
     Type:  defect         |         Status:  needs_information
 Priority:  Medium         |      Milestone:
Component:  Core Tor/Stem  |        Version:
 Severity:  Normal         |     Resolution:
 Keywords:                 |  Actual Points:
Parent ID:                 |         Points:
 Reviewer:                 |        Sponsor:
---------------------------+-----------------------------------

Comment (by catalyst):

 Thanks.  I think I haven't seen a deadlock since updating to that.

 Here's one failure (after I had been running `run_tests.py` in a loop for
 a while:

 {{{
 ======================================================================
                     test.integ.process.TestProcess
 ======================================================================

 test_can_run_multithreaded                             0 ms  [SUCCESS]
 test_dump_config_argument                              0 ms  [SUCCESS]
 test_hash_password                                     0 ms  [SUCCESS]
 test_hash_password_requires_argument                   0 ms  [SUCCESS]
 test_help_argument                                     0 ms  [SUCCESS]
 test_hush_argument                                     0 ms  [SUCCESS]
 test_launch_tor_with_config_via_file                   0 ms  [SUCCESS]
 test_launch_tor_with_config_via_stdin                  0 ms  [SUCCESS]
 test_launch_tor_with_timeout                           0 ms  [SUCCESS]
 test_list_fingerprint_argument                         0 ms  [SUCCESS]
 test_list_torrc_options_argument                       0 ms  [SUCCESS]
 test_no_orphaned_process                               0 ms  [SUCCESS]
 test_quiet_argument                                    0 ms  [SUCCESS]
 test_take_ownership_via_controller                           [FAILURE]
 test_take_ownership_via_pid                            0 ms  [SUCCESS]
 test_torrc_arguments                                   0 ms  [SUCCESS]
 test_torrc_arguments_via_stdin                         0 ms  [SUCCESS]
 test_unanonymous_hidden_service_config_must_match      0 ms  [SUCCESS]
 test_validate_config_argument                          0 ms  [SUCCESS]
 test_version_argument                                  0 ms  [SUCCESS]
 test_with_invalid_config                               0 ms  [SUCCESS]
 test_with_missing_torrc                                0 ms  [SUCCESS]

 ======================================================================
 FAIL: test_take_ownership_via_controller
 ----------------------------------------------------------------------
 Traceback (most recent call last):
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 150, in
 <lambda>
     self.method = lambda test: self.result(test)  # method that can be
 mixed into TestCases
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 214, in result
     test.fail(self._result.msg)
 AssertionError: Traceback (most recent call last):
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 165, in
 _wrapper
     runner(*args) if args else runner()
   File "/home/tlyu/src/stem/test/integ/process.py", line 625, in
 test_take_ownership_via_controller
     take_ownership = True,
   File "/home/tlyu/src/stem/stem/process.py", line 274, in
 launch_tor_with_config
     return launch_tor(tor_cmd, ['-f', '-'], None, completion_percent,
 init_msg_handler, timeout, take_ownership, stdin = config_str)
   File "/home/tlyu/src/stem/stem/process.py", line 153, in launch_tor
     raise OSError('Process terminated: %s' % last_problem)
 OSError: Process terminated: Failed to bind one of the listener ports.


 ----------------------------------------------------------------------
 Ran 22 tests in 0.001s

 FAILED (failures=1)


 Shutting down tor... done

 Style checks require pycodestyle version 1.4.2 or later. Please install it
 from...
   http://pypi.python.org/pypi/pycodestyle

 TESTING FAILED (35 seconds)
   [RUN_NONE] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_OPEN] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_PASSWORD] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_COOKIE] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_MULTIPLE] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_SOCKET] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_SCOOKIE] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL
   [RUN_PTRACE] test_take_ownership_via_controller
 (test.integ.process.TestProcess) ... FAIL

 You can re-run just these tests with:

   ./run_tests.py --tor ../tor/src/or/tor --all --log notice --target
 RUN_ALL -v --test test.integ.process
 }}}

 and another one:

 {{{
 ======================================================================
                     test.integ.process.TestProcess
 ======================================================================

 test_can_run_multithreaded                             0 ms  [SUCCESS]
 test_dump_config_argument                              0 ms  [SUCCESS]
 test_hash_password                                     0 ms  [SUCCESS]
 test_hash_password_requires_argument                   0 ms  [SUCCESS]
 test_help_argument                                     0 ms  [SUCCESS]
 test_hush_argument                                     0 ms  [SUCCESS]
 test_launch_tor_with_config_via_file                         [FAILURE]
 test_launch_tor_with_config_via_stdin                  0 ms  [SUCCESS]
 test_launch_tor_with_timeout                           0 ms  [SUCCESS]
 test_list_fingerprint_argument                         0 ms  [SUCCESS]
 test_list_torrc_options_argument                       0 ms  [SUCCESS]
 test_no_orphaned_process                               0 ms  [SUCCESS]
 test_quiet_argument                                    0 ms  [SUCCESS]
 test_take_ownership_via_controller                     0 ms  [SUCCESS]
 test_take_ownership_via_pid                            0 ms  [SUCCESS]
 test_torrc_arguments                                   0 ms  [SUCCESS]
 test_torrc_arguments_via_stdin                         0 ms  [SUCCESS]
 test_unanonymous_hidden_service_config_must_match      0 ms  [SUCCESS]
 test_validate_config_argument                          0 ms  [SUCCESS]
 test_version_argument                                  0 ms  [SUCCESS]
 test_with_invalid_config                               0 ms  [SUCCESS]
 test_with_missing_torrc                                0 ms  [SUCCESS]

 ======================================================================
 FAIL: test_launch_tor_with_config_via_file
 ----------------------------------------------------------------------
 Traceback (most recent call last):
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 150, in
 <lambda>
     self.method = lambda test: self.result(test)  # method that can be
 mixed into TestCases
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 214, in result
     test.fail(self._result.msg)
 AssertionError: Traceback (most recent call last):
   File "/home/tlyu/src/stem/stem/util/test_tools.py", line 165, in
 _wrapper
     runner(*args) if args else runner()
   File "/home/tlyu/src/stem/test/integ/process.py", line 445, in
 test_launch_tor_with_config_via_file
     completion_percent = 5
   File "/home/tlyu/src/stem/stem/process.py", line 285, in
 launch_tor_with_config
     return launch_tor(tor_cmd, args, torrc_path, completion_percent,
 init_msg_handler, timeout, take_ownership)
   File "/home/tlyu/src/stem/stem/process.py", line 153, in launch_tor
     raise OSError('Process terminated: %s' % last_problem)
 OSError: Process terminated: Failed to bind one of the listener ports.


 ----------------------------------------------------------------------
 Ran 22 tests in 0.001s

 FAILED (failures=1)


 Shutting down tor... done

 Style checks require pycodestyle version 1.4.2 or later. Please install it
 from...
   http://pypi.python.org/pypi/pycodestyle

 TESTING FAILED (36 seconds)
   [RUN_NONE] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_OPEN] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_PASSWORD] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_COOKIE] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_MULTIPLE] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_SOCKET] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_SCOOKIE] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL
   [RUN_PTRACE] test_launch_tor_with_config_via_file
 (test.integ.process.TestProcess) ... FAIL

 You can re-run just these tests with:

   ./run_tests.py --tor ../tor/src/or/tor --all --log notice --target
 RUN_ALL -v --test test.integ.process
 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/22902#comment:3>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs