Python crashes repeatedly on M1 Pro Mac

Hi,

I’m using a MacBook Pro with the M1 Pro chip running the Homebrew version of Python 3.9.9 and usually as soon as I start bench, Python crashes. Is anyone else experiencing this?

Process:               Python [31990]
Path:                  /usr/local/Cellar/python@3.9/3.9.9/Frameworks/Python.framework/Versions/3.9/Resources/Python.app/Contents/MacOS/Python
Identifier:            org.python.python
Version:               3.9.9 (3.9.9)
Code Type:             X86-64 (Translated)
Parent Process:        Python [31954]
Responsible:           Terminal [31599]
User ID:               501

Date/Time:             2022-01-03 12:43:52.5092 +0530
OS Version:            macOS 12.1 (21C52)
Report Version:        12
Anonymous UUID:        8E463991-E0EF-06CF-2174-0866F047F8EB

Sleep/Wake UUID:       03BDBCF7-1BE0-46D8-BAF9-63E1E74F72A1

Time Awake Since Boot: 110000 seconds
Time Since Wake:       2599 seconds

System Integrity Protection: enabled

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_CRASH (SIGABRT)
Exception Codes:       0x0000000000000000, 0x0000000000000000
Exception Note:        EXC_CORPSE_NOTIFY

Termination Reason:    Namespace OBJC, Code 1 

Application Specific Information:
objc[31990]: +[__NSCFConstantString initialize] may have been in progress in another thread when fork() was called.
+[__NSCFConstantString 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.
crashed on child side of fork pre-exec

Thanks,
Ishan