oHi,
I'm maintaining flaresolverr app into snapcraft containers.
Snapcraft are …isolated containers:
https://snapcraft.io/docs
Flaresolverr uses xvfbwrapper:
https://github.com/FlareSolverr/FlareSolverr
My Flaresolverr Snap package:
https://github.com/TehAppKiller/flaresolverr-tak
I'm forced to use xvfbwrapper 0.2.9 as updates after that fails to run into snapcraft containers.
Comparing is difficult as system is handled differently between 0.2.9 and 0.2.10+ and after.
And I'm not sure what data could help to debug.
Here are the xvfbwrapper 0.2.15 test results from flaresolverr snap container:
> ============================================================================================== test session starts ==============================================================================================
> platform linux -- Python 3.12.3, pytest-9.0.1, pluggy-1.6.0 -- /var/snap/flaresolverr-tak/x2/xvfbwrapper0215/.tox/py312/bin/python
> cachedir: .tox/py312/.pytest_cache
> rootdir: /var/snap/flaresolverr-tak/x2/xvfbwrapper0215
> configfile: pyproject.toml
> collected 16 items
>
> test_xvfb.py::TestXvfb::test_environ_keyword_isolates_environment_modification FAILED [ 6%]
> test_xvfb.py::TestXvfb::test_get_next_unused_display_does_not_reuse_lock PASSED [ 12%]
> test_xvfb.py::TestXvfb::test_start FAILED [ 18%]
> test_xvfb.py::TestXvfb::test_start_and_stop_as_context_manager FAILED [ 25%]
> test_xvfb.py::TestXvfb::test_start_fails_with_unknown_kwargs PASSED [ 31%]
> test_xvfb.py::TestXvfb::test_start_failure_without_initial_display_env PASSED [ 37%]
> test_xvfb.py::TestXvfb::test_start_multiple_times FAILED [ 43%]
> test_xvfb.py::TestXvfb::test_start_with_arbitrary_kwargs FAILED [ 50%]
> test_xvfb.py::TestXvfb::test_start_with_empty_display FAILED [ 56%]
> test_xvfb.py::TestXvfb::test_start_with_kwargs FAILED [ 62%]
> test_xvfb.py::TestXvfb::test_start_with_specific_display FAILED [ 68%]
> test_xvfb.py::TestXvfb::test_start_without_existing_display FAILED [ 75%]
> test_xvfb.py::TestXvfb::test_stop FAILED [ 81%]
> test_xvfb.py::TestXvfb::test_stop_if_not_running_doesnt_raise_error PASSED [ 87%]
> test_xvfb.py::TestXvfb::test_stop_with_xquartz FAILED [ 93%]
> test_xvfb.py::TestXvfb::test_xvfb_binary_does_not_exist PASSED [100%]
>
> =================================================================================================== FAILURES ====================================================================================================
> ________________________________________________________________________ TestXvfb.test_environ_keyword_isolates_environment_modification ________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_environ_keyword_isolates_environment_modification>
>
> def test_environ_keyword_isolates_environment_modification(self):
> # Check that start and stop methods modified the environ dict if
> # passed and does not modify os.environ
> env_duped = os.environ.copy()
> xvfb = Xvfb(environ=env_duped)
> > xvfb.start()
>
> test_xvfb.py:176:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3bba720>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1987231425', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ______________________________________________________________________________________________ TestXvfb.test_start ______________________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start>
>
> def test_start(self):
> xvfb = Xvfb()
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:33:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3bbbc20>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1728367108', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ________________________________________________________________________________ TestXvfb.test_start_and_stop_as_context_manager ________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_and_stop_as_context_manager>
>
> def test_start_and_stop_as_context_manager(self):
> orig_display = os.environ["DISPLAY"]
> > with Xvfb() as xvfb:
>
> test_xvfb.py:79:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> xvfbwrapper.py:70: in __enter__
> self.start()
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3bba690>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1184166777', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ______________________________________________________________________________________ TestXvfb.test_start_multiple_times _______________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_multiple_times>
>
> def test_start_multiple_times(self):
> xvfb = Xvfb()
> > xvfb.start()
>
> test_xvfb.py:49:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3a2e810>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':69736715', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ___________________________________________________________________________________ TestXvfb.test_start_with_arbitrary_kwargs ___________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_with_arbitrary_kwargs>
>
> def test_start_with_arbitrary_kwargs(self):
> xvfb = Xvfb(nolisten="tcp")
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:133:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3a2f050>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':908366905', '-screen', '0', '800x680x24', '-nolisten', 'tcp']
>
> xvfbwrapper.py:95: RuntimeError
> ____________________________________________________________________________________ TestXvfb.test_start_with_empty_display _____________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_with_empty_display>
>
> def test_start_with_empty_display(self):
> with patch.dict("os.environ", {}):
> os.environ["DISPLAY"] = ""
> xvfb = Xvfb()
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:101:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3a2faa0>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1634771482', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ________________________________________________________________________________________ TestXvfb.test_start_with_kwargs ________________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_with_kwargs>
>
> def test_start_with_kwargs(self):
> w = 800
> h = 600
> depth = 16
> xvfb = Xvfb(width=w, height=h, colordepth=depth)
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:122:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3a2e7e0>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1328711824', '-screen', '0', '800x600x16']
>
> xvfbwrapper.py:95: RuntimeError
> ___________________________________________________________________________________ TestXvfb.test_start_with_specific_display ___________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_with_specific_display>
>
> def test_start_with_specific_display(self):
> xvfb = Xvfb(display=42)
> xvfb2 = Xvfb(display=42)
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:110:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3bda1e0>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':42', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> _________________________________________________________________________________ TestXvfb.test_start_without_existing_display __________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_start_without_existing_display>
>
> def test_start_without_existing_display(self):
> with patch.dict("os.environ", {}):
> del os.environ["DISPLAY"]
> xvfb = Xvfb()
> self.addCleanup(xvfb.stop)
> > xvfb.start()
>
> test_xvfb.py:91:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3bb8a10>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1177018781', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ______________________________________________________________________________________________ TestXvfb.test_stop _______________________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_stop>
>
> def test_stop(self):
> orig_display = os.environ["DISPLAY"]
> xvfb = Xvfb()
> > xvfb.start()
>
> test_xvfb.py:41:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3aa59d0>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':985108025', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ________________________________________________________________________________________ TestXvfb.test_stop_with_xquartz ________________________________________________________________________________________
>
> self = <test_xvfb.TestXvfb testMethod=test_stop_with_xquartz>
>
> def test_stop_with_xquartz(self):
> # Check that xquartz pattern for display server is dealt with by
> # xvfb.stop() and restored appropriately
> xquartz_display = (
> "/private/tmp/com.apple.launchd.CgDzCWvNb1/org.macosforge.xquartz:0"
> )
> with patch.dict("os.environ", {"DISPLAY": xquartz_display}):
> xvfb = Xvfb()
> > xvfb.start()
>
> test_xvfb.py:71:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
>
> self = <xvfbwrapper.Xvfb object at 0x7a98c3aa4fb0>
>
> def start(self) -> None:
> if self.new_display is not None:
> if not self._get_lock_for_display(self.new_display):
> raise ValueError(f"Could not lock display :{self.new_display}")
> else:
> self.new_display = self._get_next_unused_display()
> display_var = f":{self.new_display}"
> self.xvfb_cmd = ["Xvfb", display_var, *self.extra_xvfb_args]
> self.proc = subprocess.Popen(
> self.xvfb_cmd,
> stdout=subprocess.DEVNULL,
> stderr=subprocess.DEVNULL,
> close_fds=True,
> )
> start = time.time()
> while not self._local_display_exists(self.new_display):
> time.sleep(1e-3)
> if time.time() - start > self._timeout:
> self.stop()
> > raise RuntimeError(f"Xvfb display did not open: {self.xvfb_cmd}")
> E RuntimeError: Xvfb display did not open: ['Xvfb', ':1721073704', '-screen', '0', '800x680x24']
>
> xvfbwrapper.py:95: RuntimeError
> ============================================================================================ short test summary info ============================================================================================
> FAILED test_xvfb.py::TestXvfb::test_environ_keyword_isolates_environment_modification - RuntimeError: Xvfb display did not open: ['Xvfb', ':1987231425', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start - RuntimeError: Xvfb display did not open: ['Xvfb', ':1728367108', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start_and_stop_as_context_manager - RuntimeError: Xvfb display did not open: ['Xvfb', ':1184166777', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start_multiple_times - RuntimeError: Xvfb display did not open: ['Xvfb', ':69736715', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start_with_arbitrary_kwargs - RuntimeError: Xvfb display did not open: ['Xvfb', ':908366905', '-screen', '0', '800x680x24', '-nolisten', 'tcp']
> FAILED test_xvfb.py::TestXvfb::test_start_with_empty_display - RuntimeError: Xvfb display did not open: ['Xvfb', ':1634771482', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start_with_kwargs - RuntimeError: Xvfb display did not open: ['Xvfb', ':1328711824', '-screen', '0', '800x600x16']
> FAILED test_xvfb.py::TestXvfb::test_start_with_specific_display - RuntimeError: Xvfb display did not open: ['Xvfb', ':42', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_start_without_existing_display - RuntimeError: Xvfb display did not open: ['Xvfb', ':1177018781', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_stop - RuntimeError: Xvfb display did not open: ['Xvfb', ':985108025', '-screen', '0', '800x680x24']
> FAILED test_xvfb.py::TestXvfb::test_stop_with_xquartz - RuntimeError: Xvfb display did not open: ['Xvfb', ':1721073704', '-screen', '0', '800x680x24']
> =================================================================================== 11 failed, 5 passed in 118.18s (0:01:58) ====================================================================================
> py312: exit 1 (118.48 seconds) /var/snap/flaresolverr-tak/x2/xvfbwrapper0215> pytest . pid=31941
> py312: FAIL ✖ in 2 minutes 4.42 seconds
> py313: skipped because could not find python interpreter with spec(s): py313
> py313: SKIP ⚠ in 0.01 seconds
> py314: skipped because could not find python interpreter with spec(s): py314
> py314: SKIP ⚠ in 0.01 seconds
> pypy3: skipped because could not find python interpreter with spec(s): pypy3
> validate: OK (7.85=setup[7.37]+cmd[0.49] seconds)
> lint: OK (16.66=setup[13.84]+cmd[0.37,0.03,0.02,2.40] seconds)
> type: OK (5.25=setup[3.11]+cmd[2.14] seconds)
> py310: SKIP (0.01 seconds)
> py311: SKIP (0.01 seconds)
> py312: FAIL code 1 (124.42=setup[5.93]+cmd[118.48] seconds)
> py313: SKIP (0.01 seconds)
> py314: SKIP (0.01 seconds)
> pypy3: SKIP (0.02 seconds)
> evaluation failed :( (154.28 seconds)
`
Thanks