PytestAssertRewriteWarning due to runpytest and pytest_plugins
Maintainer thường phản hồi trong vòng 1 ngày
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
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- python
- Lĩnh vực
- testing-qa
Hướng nghiên cứu
Bắt đầu với sáu test được nêu trong tests/markers/ và tests/test_event_loop_fixture.py, sau đó so sánh việc sử dụng runpytest_subprocess của chúng với commit 18afc9df5a3153dc1fbdc4e11a56517ef95480df. Chạy các test bị ảnh hưởng trên Python 3.11 và kiểm tra cách pytest_plugins tương tác với cơ chế tự động phát hiện plugin. Hoàn thành khi các test được liệt kê không còn phát ra PytestAssertRewriteWarning mà vẫn giữ nguyên hành vi hiện có.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Originally posted by @McSinyx in https://github.com/pytest-dev/pytest-asyncio/issues/1275#issuecomment-3737477316
On Python 3.11 on Guix (full test log), PytestAssertRewriteWarning resurfaces for the following tests due to 18afc9df5a3153dc1fbdc4e11a56517ef95480df replacing runpytest with runpytest_subprocess:
tests/markers/test_class_scope.py::test_standalone_test_does_not_trigger_warning_about_no_current_event_loop_being_set
tests/markers/test_function_scope.py::test_warns_when_scope_argument_is_present
tests/markers/test_module_scope.py::test_standalone_test_does_not_trigger_warning_about_no_current_event_loop_being_set
tests/markers/test_session_scope.py::test_standalone_test_does_not_trigger_warning_about_no_current_event_loop_being_set
tests/test_event_loop_fixture.py::test_event_loop_fixture_handles_unclosed_async_gen
tests/test_event_loop_fixture.py::test_event_loop_fixture_asyncgen_error
IIUC this commit tries to workaround a case in GH-1227 where a system pytest-asyncio package takes precedence over a local one. Our fix for Guix also involves removing pytest_plugins = 'pytest_asyncio' in the following tests because it also marks the package for assertion rewriting while it's already imported before executing the scripts as part of plugin autodiscovery.
tests/test_event_loop_fixture.py::test_event_loop_fixture_handles_unclosed_async_gen
tests/test_event_loop_fixture.py::test_event_loop_fixture_asyncgen_error
- Ngôn ngữ chính
- Python
- Star
- 1.7k
- Fork
- 207
- Merge trung bình
- 4 giờ 38 phút
- Pull request đã merge (30 ngày)
- 12
Chuẩn bị môi trường
Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. 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
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của pytest-dev/pytest-asyncio
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
pytest-dev/pytest-asyncio#1475 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 56/100
pytest-dev/pytest-asyncio#1514 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 72/100
pytest-dev/pytest-asyncio#1501 · 3 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
pytest-dev/pytest-asyncio#1463 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Don't warn about `asyncio_default_fixture_loop_scope` unless the test suite uses `pytest-asyncio`Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
pytest-dev/pytest-asyncio#1344 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của pytest-dev/pytest-asyncio
Issue tương tự
-
Broken links found in docsĐang mởdocs pydanty:is-working
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
pydantic/pydantic-ai#8863 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
run-llama/llama_index#23278 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
documentation from-review-extraction github-actions priority: low severity:nit
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
LearningCircuit/local-deep-research#6946 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
oracle/langchain-oracle#323 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
tenstorrent/tt-metal#58057 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày