-
-
Notifications
You must be signed in to change notification settings - Fork 14.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
python3Packages.mocket: Resolve test failures #216511
base: master
Are you sure you want to change the base?
Conversation
"test_http_session" | ||
"test_https_session" | ||
"test_httprettish_session" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Set __darwinAllowLocalNetworking = true;
instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I didn't know about that! However, I'm not sure if it's even a Darwin-specific issue anymore -see below
The tests also fail on x86_64-linux for me (even with the sandbox disabled).
(printed a couple of times) That would mean it's simply an upstream Python 3.11 compatibility issue. |
Result of 2 packages marked as broken and skipped:
11 packages failed to build:
16 packages built:
Edit:
geoip2 test output (excerpt):
|
Add pytest-asyncio in order to allow async tests to run. They were previously silently skipped with a warning. Disable three more tests (test_http*_session) that depend on Internet connectivity and thus fail in sandboxed builds.
1848879
to
58fd39a
Compare
After more fiddling, I think the root issue is simply some Python 3.11 incompatibility in the test setup of mocket (althought I'm not sure what the cause is). Anyways, in the newest version of the commits I'm conditionally disabling certain tests on Python >= 3.11 in mocket and geoip2 - the latter has similar 3.11 issues that weren't uncovered previously because mocket didn't build. |
Result of 2 packages marked as broken and skipped:
1 package failed to build:
26 packages built:
sopel issue maybe unrelated:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes look good
Build successful
#217295 contains the update of |
@@ -30,6 +30,8 @@ buildPythonPackage rec { | |||
pytestCheckHook | |||
]; | |||
|
|||
disabledTests = lib.optional (pythonAtLeast "3.11") "TestAsyncClient"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For me there was also a failure on Python 3.10, see e2be015
Description of changes
Add pytest-asyncio in order to allow async tests to run. They were previously silently skipped with a warning.
Disable three more tests (test_http*_session) that depend on Internet connectivity and thus fail in sandboxed builds.
This should some Hydra failures, e.g. this one: https://hydra.nixos.org/build/208832590
Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)