may have been in progress in another thread when fork() was called.

简介: may have been in progress in another thread when fork() was called.

运行Python代码报错,之前好好的,今天很突然

may have been in progress in another thread when fork() was called.

解决方法:添加环境变量:

OBJC_DISABLE_INITIALIZE_FORK_SAFETY=YES

环境变量.png

参考

“+[SomeClass initialize] may have been in progress in another thread when fork() was called”

相关文章
|
7月前
|
NoSQL 编译器 API
关于thread使用的错误:pure virtual method called terminate called without an active exception
关于thread使用的错误:pure virtual method called terminate called without an active exception
146 1
已解决 RuntimeError: There is no current event loop in thread ‘Thread-1‘.
Jetson Xavier NX 报错 RuntimeError: There is no current event loop in thread 'Thread-1'.异常错误,已解决
602 0
已解决 RuntimeError: There is no current event loop in thread ‘Thread-1‘.
|
6月前
|
Python
【ERROR】asyncio.run(main())报错:RuntimeError: Event loop is closed
【ERROR】asyncio.run(main())报错:RuntimeError: Event loop is closed
173 0
|
前端开发
The following tasks did not complete: first Did you forget to signal async completion?
The following tasks did not complete: first Did you forget to signal async completion?
|
Java Spring
Redisson BUG: Failed to submit a listener notification task. Event loop shut down?
Redisson BUG: Failed to submit a listener notification task. Event loop shut down?
1444 0
Error:svn:E155037:Previous operation has not finished; run ‘cleanup‘ if it was interrupted(完美解决)
Error:svn:E155037:Previous operation has not finished; run ‘cleanup‘ if it was interrupted(完美解决)
429 0
Error:svn:E155037:Previous operation has not finished; run ‘cleanup‘ if it was interrupted(完美解决)
|
调度 C++
Thread.sleep(0) vs Thread.sleep(1) vs Thread.yield() vs Object.wait()
Thread.sleep(0) vs Thread.sleep(1) vs Thread.yield() vs Object.wait()
|
Python
may have been in progress in another thread when fork() was called.
may have been in progress in another thread when fork() was called.
142 0
may have been in progress in another thread when fork() was called.
|
Java 程序员 调度
Thread State 详解
前言 文本已收录至我的GitHub仓库,欢迎Star:github.com/bin39232820… 种一棵树最好的时间是十年前,其次是现在
176 0