Closed Bug 1682844 Opened 4 years ago Closed 2 years ago

check_subdomain is missing mp_context

Categories

(Testing :: web-platform-tests, defect)

defect

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: yulia, Unassigned)

Details

When running mach wpt-serve with the most recent m-c, I hit the following error:

TypeError: check_subdomains() missing 1 required positional argument: 'mp_context'

  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/mach_commands.py", line 559, in wpt_serve
    return wpt_serve.run(**params)
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/mach_commands.py", line 270, in run
    return 0 if serve.run(route_builder=get_route_builder, **kwargs) else 1
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/tests/tools/serve/serve.py", line 1004, in run
    check_subdomains(config, routes)

I tried a naive fix for this by adding mp_context here: https://searchfox.org/mozilla-central/rev/8883276967d39918e2ce64e873afdd432fb406ca/testing/web-platform/tests/tools/serve/serve.py#1004 but this resulted in another error:

TypeError: cannot pickle 'module' object

  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/mach_commands.py", line 559, in wpt_serve
    return wpt_serve.run(**params)
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/mach_commands.py", line 270, in run
    return 0 if serve.run(route_builder=get_route_builder, **kwargs) else 1
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/tests/tools/serve/serve.py", line 1004, in run
    check_subdomains(config, routes, mp_context)
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/tests/tools/serve/serve.py", line 482, in check_subdomains
    wrapper.start(start_http_server, host, port, paths, routes,
  File "/Users/yuliastartsev/Work/mozilla-central/testing/web-platform/tests/tools/serve/serve.py", line 423, in start
    self.proc.start()
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/process.py", line 121, in start
    self._popen = self._Popen(self)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/context.py", line 283, in _Popen
    return Popen(process_obj)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in __init__
    super().__init__(process_obj)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_fork.py", line 19, in __init__
    self._launch(process_obj)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
    reduction.dump(process_obj, fp)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)

I hope this is the same as bug 1682805; let me know if autoland/cherry-picking that change doesn't fix the problem.

Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.