Comments (4)
Looks like just some logging paths differ. PR welcome to use regexes to avoid these failures.
from watchfiles.
To form PR it is necessary to know the code .. which I don't know.
from watchfiles.
I just tested 0.21.0 and looks like now fails only one unit
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -m 'not network' --import-mode=importlib
============================= test session starts ==============================
platform linux -- Python 3.8.18, pytest-7.4.3, pluggy-1.3.0
rootdir: /home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0
configfile: pyproject.toml
testpaths: tests
plugins: anyio-4.0.0, mock-3.12.0, timeout-2.2.0
timeout: 10.0s
timeout method: signal
timeout func_only: False
collected 161 items
tests/test_cli.py ....................... [ 14%]
tests/test_docs.py ................s [ 24%]
tests/test_filters.py .................. [ 36%]
tests/test_force_polling.py .......................... [ 52%]
tests/test_run_process.py ..s..................... [ 67%]
tests/test_rust_notify.py .................................... [ 89%]
tests/test_watch.py ...............sF [100%]
=================================== FAILURES ===================================
_________________________ test_awatch_interrupt_raise __________________________
self = <tests.test_watch.MockRustNotifyRaise object at 0x7f5f65dd28b0>
args = (1600, 50, 5000, <threading.Event object at 0x7f5f65e29130>)
def watch(self, *args):
if self.i == 1:
> raise KeyboardInterrupt('test error')
E KeyboardInterrupt: test error
tests/test_watch.py:204: KeyboardInterrupt
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 254, in awatch
raw_changes = await anyio.to_thread.run_sync(watcher.watch, debounce, step, timeout, stop_event_)
File "/usr/lib/python3.8/site-packages/anyio/to_thread.py", line 33, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 2106, in run_sync_in_worker_thread
return await future
File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 833, in run
result = context.run(func, *args)
File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 204, in watch
raise KeyboardInterrupt('test error')
KeyboardInterrupt: test error
During handling of the above exception, another exception occurred:
+ Exception Group Traceback (most recent call last):
| File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 341, in from_call
| result: Optional[TResult] = func()
| File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 262, in <lambda>
| lambda: ihook(item=item, **kwds), when=when, reraise=reraise
| File "/usr/lib/python3.8/site-packages/pluggy/_hooks.py", line 493, in __call__
| return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
| File "/usr/lib/python3.8/site-packages/pluggy/_manager.py", line 115, in _hookexec
| return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
| File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 152, in _multicall
| return outcome.get_result()
| File "/usr/lib/python3.8/site-packages/pluggy/_result.py", line 114, in get_result
| raise exc.with_traceback(exc.__traceback__)
| File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 77, in _multicall
| res = hook_impl.function(*args)
| File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call
| item.runtest()
| File "/usr/lib/python3.8/site-packages/_pytest/python.py", line 1797, in runtest
| self.ihook.pytest_pyfunc_call(pyfuncitem=self)
| File "/usr/lib/python3.8/site-packages/pluggy/_hooks.py", line 493, in __call__
| return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
| File "/usr/lib/python3.8/site-packages/pluggy/_manager.py", line 115, in _hookexec
| return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
| File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 113, in _multicall
| raise exception.with_traceback(exception.__traceback__)
| File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 77, in _multicall
| res = hook_impl.function(*args)
| File "/usr/lib/python3.8/site-packages/anyio/pytest_plugin.py", line 119, in pytest_pyfunc_call
| runner.run_test(pyfuncitem.obj, testargs)
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1936, in run_test
| self.get_loop().run_until_complete(
| File "/usr/lib64/python3.8/asyncio/base_events.py", line 616, in run_until_complete
| return future.result()
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1896, in _call_in_runner_task
| return await future
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1874, in _run_tests_and_fixtures
| retval = await coro
| File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 224, in test_awatch_interrupt_raise
| async for _ in awatch('.', stop_event=stop_event):
| File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 259, in awatch
| tg.cancel_scope.cancel()
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 664, in __aexit__
| raise BaseExceptionGroup(
| exceptiongroup.BaseExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
+-+---------------- 1 ----------------
| Traceback (most recent call last):
| File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 254, in awatch
| raw_changes = await anyio.to_thread.run_sync(watcher.watch, debounce, step, timeout, stop_event_)
| File "/usr/lib/python3.8/site-packages/anyio/to_thread.py", line 33, in run_sync
| return await get_async_backend().run_sync_in_worker_thread(
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 2106, in run_sync_in_worker_thread
| return await future
| File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 833, in run
| result = context.run(func, *args)
| File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 204, in watch
| raise KeyboardInterrupt('test error')
| KeyboardInterrupt: test error
+------------------------------------
------------------------------ Captured log call -------------------------------
watchfiles.main INFO: 1 change detected
=========================== short test summary info ============================
SKIPPED [1] tests/test_docs.py:105: output varies between versions
SKIPPED [1] tests/test_run_process.py:72: no need to test this except on windows
SKIPPED [1] tests/test_watch.py:192: different on windows
FAILED tests/test_watch.py::test_awatch_interrupt_raise - exceptiongroup.Base...
=================== 1 failed, 157 passed, 3 skipped in 3.66s ===================
from watchfiles.
Related Issues (20)
- Watchfiles not working without force_pulling HOT 1
- recursive watch ignoring changes beyond certain depth HOT 6
- Watched file no longer watched after a change HOT 8
- There was a problem installing the watchfiles.
- nonsensical wording in docs for watch HOT 1
- PyPy 3.10 Wheels HOT 3
- Watchfiles does not report changes made by a different user in a directory HOT 5
- Newly created subdirectories themselves arent getting watched recursively HOT 4
- Watchfiles with editable packages HOT 2
- install trouble on SUSE11SP4: ERROR: Failed building wheel for maturin HOT 1
- Please keep a changelog HOT 1
- tests/test_watch.py::test_awatch_interrupt_raise is failing with anyio>=4 HOT 8
- .pyd ignored pattern is added back by PythonFilter.extensions HOT 1
- Problem installing on raspberry pi HOT 6
- Signal timeout does not propagate HOT 2
- awatch on a file on Linux trigger delete event HOT 4
- Please make a new release using pyo3 0.20.3 HOT 9
- Testsuite hangs on test_ignore_permission_denied on Debian i386 HOT 1
- Ignore error_handler errors under ignore_permission_denied = True? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from watchfiles.