Skip to content

fix: disable anyio pytest plugin#1098

Open
xangcastle wants to merge 2 commits into
1.xfrom
xangcastle/1x-disable-anyio-pytest-plugin
Open

fix: disable anyio pytest plugin#1098
xangcastle wants to merge 2 commits into
1.xfrom
xangcastle/1x-disable-anyio-pytest-plugin

Conversation

@xangcastle

@xangcastle xangcastle commented Jun 10, 2026

Copy link
Copy Markdown
Member

Problem

When anyio is a direct or transitive dependency of a py_test target, its pytest plugin auto-registers via the pytest11 entry point. This causes interference with test collection and execution in environments that don't explicitly configure anyio's async backend.

Fix

Add and e2e sample with -p no:anyio to the pytest args.


Changes are visible to end-users: no

Test plan

  • New test cases added

@aspect-workflows

aspect-workflows Bot commented Jun 10, 2026

Copy link
Copy Markdown

✨ Aspect Workflows Tasks

📅 Wed Jun 10 22:57:55 UTC 2026

✅ 7 successful tasks

  • ✅ buildifier · ⏱ 24.3s · 🐙 GitHub Actions · ☑️ Check
    💬 Format complete (clean)
  • ✅ gazelle · ⏱ 18.1s · 🐙 GitHub Actions · ☑️ Check
    💬 Gazelle complete (clean)
  • ✅ test (test-e2e-bazel-8) · ⏱ 34m 8s · 🐙 GitHub Actions · ☑️ Check
    💬 Bazel test complete (62/62 passed)
  • ✅ test (test-e2e-bazel-9) · ⏱ 36m 26s · 🐙 GitHub Actions · ☑️ Check
    💬 Bazel test complete (62/62 passed)
  • ✅ test (test-examples-uv_pip_compile-bazel-8) · ⏱ 17.7s · 🐙 GitHub Actions · ☑️ Check
    💬 Bazel test complete (1/1 passed · 1 cached)
  • ✅ test (test-root-bazel-8) · ⏱ 38m 5s · 🐙 GitHub Actions · ☑️ Check
    💬 Bazel test complete (123/123 passed)
  • ✅ test (test-root-bazel-9) · ⏱ 36m · 🐙 GitHub Actions · ☑️ Check
    💬 Bazel test complete (122/122 passed)

⏱ Last updated Wed Jun 10 23:36:10 UTC 2026 · 📊 GitHub API quota 252/15,000 (2% used, resets in 6m, throttle 3×)
🚀 Powered by Aspect CLI (v2026.22.44)  |  Aspect Build · X · LinkedIn · YouTube

@xangcastle xangcastle requested a review from jbedard June 10, 2026 21:52
Comment thread e2e/MODULE.bazel Outdated
Comment thread py/private/pytest.py.tmpl Outdated
@xangcastle xangcastle force-pushed the xangcastle/1x-disable-anyio-pytest-plugin branch from 1565957 to ee27337 Compare June 10, 2026 22:51
@xangcastle xangcastle force-pushed the xangcastle/1x-disable-anyio-pytest-plugin branch from ee27337 to 3689e16 Compare June 10, 2026 22:57
@xangcastle xangcastle requested a review from jbedard June 10, 2026 23:05
@xangcastle xangcastle marked this pull request as ready for review June 10, 2026 23:05
@jbedard

jbedard commented Jun 10, 2026

Copy link
Copy Markdown
Member

Now this is just an example in e2e? Is that worth merging into 1.x?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants