Opened 5 years ago
Closed 5 years ago
#30806 closed Bug (fixed)
Tox doesn't pass OBJC_DISABLE_INITIALIZE_FORK_SAFETY for MacOS test uns
Reported by: | Christopher Wilcox | Owned by: | Christopher Wilcox |
---|---|---|---|
Component: | Testing framework | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | Dustin Harrison | Triage Stage: | Ready for checkin |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description
Mac requires that you specify export OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES
Tox needs to specify to pass the ENV for executions.
Change History (7)
comment:1 by , 5 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 5 years ago
Triage Stage: | Unreviewed → Accepted |
---|---|
Type: | Uncategorized → Bug |
comment:3 by , 5 years ago
I was able to recreate this issue using MacOS Mojave 10.14.6, Python 3.7.3
Without OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES while the tests were running the following messages would occasionally be emitted and eventually the tests would hang:
[__NSPlaceholderDate initialize] may have been in progress in another thread when fork() was called. objc[40052]: +[__NSPlaceholderDate initialize] may have been in progress in another thread when fork() was called. We cannot safely call it or ignore it in the fork() child process. Crashing instead. Set a breakpoint on objc_initializeAfterForkError to debug.
After applying my PR (https://github.com/django/django/pull/11830) and running:
export OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES tox
all tests pass and don't hang.
comment:4 by , 5 years ago
Cc: | added |
---|---|
Easy pickings: | set |
Has patch: | set |
comment:5 by , 5 years ago
Thanks for confirming you are also seeing this Dustin. I also had a fix but was trying to find someone to verify it wasn't just better on my machine. https://github.com/django/django/pull/11835
comment:6 by , 5 years ago
Triage Stage: | Accepted → Ready for checkin |
---|
Related to #27086. Going to accept as
tox
should run on a clean checkout.