当我尝试使用--parallel
在Travis CI上并行运行django测试时,我遇到了这个错误
Traceback (most recent call last):
File "manage.py", line 43, in <module>
execute_from_command_line(sys.argv)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/__init__.py", line 364, in execute_from_command_line
utility.execute()
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/__init__.py", line 356, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/commands/test.py", line 29, in run_from_argv
super(Command, self).run_from_argv(argv)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/base.py", line 283, in run_from_argv
self.execute(*args, **cmd_options)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/base.py", line 330, in execute
output = self.handle(*args, **options)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/core/management/commands/test.py", line 62, in handle
failures = test_runner.run_tests(test_labels)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/test/runner.py", line 603, in run_tests
result = self.run_suite(suite)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/test/runner.py", line 567, in run_suite
return runner.run(suite)
File "/opt/python/2.7.6/lib/python2.7/unittest/runner.py", line 151, in run
test(result)
File "/opt/python/2.7.6/lib/python2.7/unittest/suite.py", line 70, in __call__
return self.run(*args, **kwds)
File "/home/travis/virtualenv/python2.7.6/lib/python2.7/site-packages/django/test/runner.py", line 370, in run
subsuite_index, events = test_results.next(timeout=0.1)
File "/opt/python/2.7.6/lib/python2.7/multiprocessing/pool.py", line 655, in next
raise value
TypeError: __init__() takes exactly 3 arguments (2 given)
在Django中,我在任何地方都找不到任何支持。
在这种情况下,我不知道第三个参数 init ()是什么。
我的django版本是1.11.18
命令为python manage.py test --parapllel=4