Skip to content

fix: make test suite pass on Windows and Python 3.12+ - #1185

Merged
csmarchbanks merged 2 commits into
prometheus:masterfrom
MelvinjoseC:master
Jul 24, 2026
Merged

fix: make test suite pass on Windows and Python 3.12+#1185
csmarchbanks merged 2 commits into
prometheus:masterfrom
MelvinjoseC:master

Conversation

@MelvinjoseC

Copy link
Copy Markdown
Contributor
  • Fix event loop issues in ASGI tests under newer asgiref by wrapping communicator setup in an async coroutine run on the loop.
  • Fix mmap file locking (PermissionError: [WinError 32]) on Windows in multiprocess tests by closing open database handles before unlinking/removing directories.
  • Skip case-sensitive env var deprecation warning assertion on Windows where environment variables are case-insensitive.
  • Conditionally define the parser benchmark test to avoid failure when pytest-benchmark is not installed.
- Fix event loop issues in ASGI tests under newer asgiref by wrapping communicator setup in an async coroutine run on the loop.
- Fix mmap file locking (PermissionError: [WinError 32]) on Windows in multiprocess tests by closing open database handles before unlinking/removing directories.
- Skip case-sensitive env var deprecation warning assertion on Windows where environment variables are case-insensitive.
- Conditionally define the parser benchmark test to avoid failure when pytest-benchmark is not installed.

Signed-off-by: MelvinjoseC <165891174+MelvinjoseC@users.noreply.github.com>

@csmarchbanks csmarchbanks left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

A few lint errors and such in CI, but generally I am happy with this. Would you also be interested in adding a CI pipeline for windows to avoid regressions? Just one python version is probably enough.

@MelvinjoseC

Copy link
Copy Markdown
Contributor Author

Thanks for the feedback! I've fixed the remaining lint/type issues and added a Windows CI job using Python 3.12. All local checks pass, and GitHub Actions are now running.

@csmarchbanks

Copy link
Copy Markdown
Member

Thanks! Everything looks good now, but the DCO needs to be signed on your most recent commit.

Signed-off-by: MelvinjoseC <165891174+MelvinjoseC@users.noreply.github.com>
@MelvinjoseC

Copy link
Copy Markdown
Contributor Author

Thanks! I've added the DCO sign-off to the latest commit. The DCO check is now passing. The remaining CI workflow is awaiting maintainer approval.

@csmarchbanks csmarchbanks left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@csmarchbanks
csmarchbanks merged commit 769b415 into prometheus:master Jul 24, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants