Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

test_watch_multiple_dirs fails consistently

Đang mở
#200 3 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
42/100
Loại issue
Lỗi
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Đình trệ
Công nghệ
python
Lĩnh vực
testing

Hướng nghiên cứu

Start with tests/test_watcher.py, especially test_watch_multiple_dirs at line 147, and run that test under the reported Python 2.7 and 3.7 environments. Trace why watcher.examine() does not return (first_path, None); done means the multiple-directory watcher test passes consistently on both versions.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hello,

While trying to package v2.6.1 for NixOS (see https://github.com/NixOS/nixpkgs/pull/61905) I noticed that the latest addition to your test suite test_watch_multiple_dirs kept failing for both Python 2.7 and Python 3.7 builds.

The nosetests trace with debug is:

nose.suite: DEBUG: precache is [Test(<tests.test_watcher.TestWatcher testMethod=test_watch_dir>), Test(<tests.test_watcher.TestWatcher testMethod=test_watch_file>), Test(<tests.test_watcher.TestWatcher testMethod=test_watch_glob>), Test(<tests.test_watcher.TestWatcher testMethod=test_watch_ignore>), Test(<tests.test_watcher.TestWatcher testMethod=test_watch_multiple_dirs>)]
test_watch_dir (tests.test_watcher.TestWatcher) ... ok
test_watch_file (tests.test_watcher.TestWatcher) ... ok
test_watch_glob (tests.test_watcher.TestWatcher) ... ok
test_watch_ignore (tests.test_watcher.TestWatcher) ... ok
test_watch_multiple_dirs (tests.test_watcher.TestWatcher) ... FAIL
nose.suite: DEBUG: context teardown
nose.suite: DEBUG: ancestor <class 'tests.test_watcher.TestWatcher'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=TestWatcher> setup ancestor <class 'tests.test_watcher.TestWatcher'>
nose.suite: DEBUG: <nose.suite.ContextSuite context=TestWatcher> teardown context <class 'tests.test_watcher.TestWatcher'>
nose: DEBUG: call fixture <class 'tests.test_watcher.TestWatcher'>.tearDownClass
nose.suite: DEBUG: ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests.test_watcher> setup ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'>
nose.suite: DEBUG: ancestor <module 'tests' from '/build/source/tests/__init__.py'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests> setup ancestor <module 'tests' from '/build/source/tests/__init__.py'>
nose.suite: DEBUG: ancestor <class 'tests.test_watcher.TestWatcher'> may need teardown
nose.suite: DEBUG: ancestor <class 'tests.test_watcher.TestWatcher'> already torn down
nose.suite: DEBUG: context teardown
nose.suite: DEBUG: ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests.test_watcher> setup ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'>
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests.test_watcher> teardown context <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'>
nose.suite: DEBUG: ancestor <module 'tests' from '/build/source/tests/__init__.py'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests> setup ancestor <module 'tests' from '/build/source/tests/__init__.py'>
nose.suite: DEBUG: ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'> may need teardown
nose.suite: DEBUG: ancestor <module 'tests.test_watcher' from '/build/source/tests/test_watcher.py'> already torn down
nose.suite: DEBUG: context teardown
nose.suite: DEBUG: ancestor <module 'tests' from '/build/source/tests/__init__.py'> may need teardown
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests> setup ancestor <module 'tests' from '/build/source/tests/__init__.py'>
nose.suite: DEBUG: <nose.suite.ContextSuite context=tests> teardown context <module 'tests' from '/build/source/tests/__init__.py'>
nose.suite: DEBUG: ancestor <module 'tests' from '/build/source/tests/__init__.py'> may need teardown
nose.suite: DEBUG: ancestor <module 'tests' from '/build/source/tests/__init__.py'> already torn down
nose.suite: DEBUG: context teardown
nose.suite: DEBUG: No reason to teardown (was_setup? False was_torndown? False)

======================================================================
FAIL: test_watch_multiple_dirs (tests.test_watcher.TestWatcher)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/build/source/tests/test_watcher.py", line 147, in test_watch_multiple_dirs
    assert watcher.examine() == (first_path, None)
AssertionError

----------------------------------------------------------------------
Ran 5 tests in 3.099s

FAILED (failures=1)

I can't really figure out why it fails.

Ngôn ngữ chính
Python
Star
1.1k
Fork
149
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của lepture/python-livereload

Tất cả issue của lepture/python-livereload

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.