Skip to content

[Python] MacOs stuck on importing (23.0.1) while works on (15.0.1) #49413

Open

Description

@KochankovID

Describe the bug, including details regarding any error messages, version, and platform.

Analysis of sampling python3 (pid 3720) every 1 millisecond
Process: python3.11 [3720]
Path: /Users/USER/*/python3.11
Load Address: 0x1020dc000
Identifier: python3.11
Version: 0
Code Type: ARM64
Platform: macOS
Parent Process: launchd [1]
Target Type: live task

Date/Time: 2026-02-28 12:01:36.872 +0300
Launch Time: 2026-02-28 11:44:21.343 +0300
OS Version: macOS 26.2 (25C56)
Report Version: 7
Analysis Tool: /usr/bin/sample

Physical footprint: 85.1M
Physical footprint (peak): 86.0M
Idle exit: untracked

Call graph:
2350 Thread_634713 DispatchQueue_13: com.apple.root.default-qos (concurrent)
+ 2350 thread_start (in libsystem_pthread.dylib) + 8 [0x187054ba8]
+ 2350 _pthread_start (in libsystem_pthread.dylib) + 136 [0x187059c08]
+ 2350 pythread_wrapper (in python3.11) + 28 [0x102279cdc]
+ 2350 thread_run (in python3.11) + 80 [0x1022d8ca0]
+ 2350 method_vectorcall (in python3.11) + 308 [0x10212dca8]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyObject_Call (in python3.11) + 168 [0x10212b884]
+ 2350 slot_tp_call (in python3.11) + 184 [0x10219957c]
+ 2350 _PyObject_Call_Prepend (in python3.11) + 148 [0x10212bd14]
+ 2350 _PyObject_FastCallDictTstate (in python3.11) + 272 [0x10212afcc]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 method_vectorcall (in python3.11) + 168 [0x10212dc1c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 method_vectorcall (in python3.11) + 168 [0x10212dc1c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 method_vectorcall (in python3.11) + 168 [0x10212dc1c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin_exec (in python3.11) + 916 [0x10220e7b4]
+ 2350 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin_exec (in python3.11) + 916 [0x10220e7b4]
+ 2350 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin___import
(in python3.11) + 256 [0x10220d7e0]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin_exec (in python3.11) + 916 [0x10220e7b4]
+ 2350 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin_exec (in python3.11) + 916 [0x10220e7b4]
+ 2350 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin___import
(in python3.11) + 256 [0x10220d7e0]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
+ 2350 builtin_exec (in python3.11) + 916 [0x10220e7b4]
+ 2350 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
+ 2350 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
+ 2350 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
+ 2350 object_vacall (in python3.11) + 256 [0x10212cc80]
+ 2350 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
+ 2350 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
+ 2350 cfunction_vectorcall_FASTCALL (in python3.11) + 260 [0x102177d78]
+ 2350 _imp_create_dynamic (in python3.11) + 408 [0x102251438]
+ 2350 _PyImport_LoadDynamicModuleWithSpec (in python3.11) + 584 [0x102251ddc]
+ 2350 _PyImport_FindSharedFuncptr (in python3.11) + 180 [0x102288e64]
+ 2350 dyld4::APIs::dlopen(char const*, int) (in dyld) + 128 [0x186cc7e70]
+ 2350 dyld4::APIs::dlopen_from(char const*, int, void*) (in dyld) + 1104 [0x186cc836c]
+ 2350 dyld4::APIs::dlopen_from(char const*, int, void*)::$_0::operator()() const (in dyld) + 1856 [0x186cd3ad0]
+ 2350 dyld4::Loader::runInitializersBottomUpPlusUpwardLinks(dyld4::RuntimeState&) const (in dyld) + 716 [0x186caf530]
+ 2350 dyld4::Loader::runInitializersBottomUpPlusUpwardLinks(dyld4::RuntimeState&) const::$_0::operator()() const (in dyld) + 180 [0x186cb3e50]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]
+ 2350 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 308 [0x186caf214]
+ 2350 dyld4::JustInTimeLoader::runInitializers(dyld4::RuntimeState&) const (in dyld) + 36 [0x186cb68b0]
+ 2350 dyld4::Loader::findAndRunAllInitializers(dyld4::RuntimeState&) const (in dyld) + 172 [0x186caea68]
+ 2350 dyld3::MachOAnalyzer::forEachInitializer(Diagnostics&, dyld3::MachOAnalyzer::VMAddrConverter const&, void (unsigned int) block_pointer, void const*) const (in dyld) + 516 [0x186cec220]
+ 2350 mach_o::Header::forEachSection(void (mach_o::Header::SectionInfo const&, bool&) block_pointer) const (in dyld) + 124 [0x186d099f0]
+ 2350 mach_o::Header::forEachLoadCommand(void (load_command const*, bool&) block_pointer) const (in dyld) + 208 [0x186d08158]
+ 2350 invocation function for block in mach_o::Header::forEachSection(void (mach_o::Header::SectionInfo const&, bool&) block_pointer) const (in dyld) + 312 [0x186d0b534]
+ 2350 invocation function for block in dyld3::MachOAnalyzer::forEachInitializer(Diagnostics&, dyld3::MachOAnalyzer::VMAddrConverter const&, void (unsigned int) block_pointer, void const*) const (in dyld) + 324 [0x186cec730]
+ 2350 invocation function for block in dyld4::Loader::findAndRunAllInitializers(dyld4::RuntimeState&) const (in dyld) + 444 [0x186caecb0]
+ 2350 _GLOBAL__sub_I_curl.cpp (in libarrow.2300.dylib) + 168 [0x164380e64]
+ 2350 curl_global_init (in libarrow.2300.dylib) + 232 [0x1647be44c]
+ 2350 Curl_macos_init (in libarrow.2300.dylib) + 16 [0x1647dd478]
+ 2350 SCDynamicStoreCopyProxiesWithOptions (in SystemConfiguration) + 180 [0x18857ff14]
+ 2350 _CFPreferencesCopyAppValueWithContainerAndConfiguration (in CoreFoundation) + 112 [0x1870bd7bc]
+ 2350 -[_CFXPreferences copyAppValueForKey:identifier:container:configurationURL:] (in CoreFoundation) + 156 [0x18726c174]
+ 2350 -[_CFXPreferences withSearchListForIdentifier:container:cloudConfigurationURL:perform:] (in CoreFoundation) + 432 [0x187239c6c]
+ 2350 __108-[_CFXPreferences(SearchListAdditions) withSearchListForIdentifier:container:cloudConfigurationURL:perform:]_block_invoke (in CoreFoundation) + 380 [0x187239e50]
+ 2350 __76-[_CFXPreferences copyAppValueForKey:identifier:container:configurationURL:]_block_invoke (in CoreFoundation) + 32 [0x18726c1f0]
+ 2350 -[CFPrefsSource copyValueForKey:] (in CoreFoundation) + 44 [0x1871d84e4]
+ 2350 -[CFPrefsSearchListSource alreadylocked_copyValueForKey:] (in CoreFoundation) + 172 [0x187237af0]
+ 2350 -[CFPrefsSearchListSource alreadylocked_getDictionary:] (in CoreFoundation) + 476 [0x18728dde0]
+ 2350 -[CFPrefsSearchListSource alreadylocked_generationCountFromListOfSources:count:] (in CoreFoundation) + 260 [0x18728e360]
+ 2350 -[CFPrefsSearchListSource synchronouslySendSystemMessage:andUserMessage:andDirectMessage:replyHandler:] (in CoreFoundation) + 240 [0x18728d7e4]
+ 2350 CFPREFERENCES_IS_WAITING_FOR_SYSTEM_AND_USER_CFPREFSDS (in CoreFoundation) + 100 [0x1870c4534]
+ 2350 __103-[CFPrefsSearchListSource synchronouslySendSystemMessage:andUserMessage:andDirectMessage:replyHandler:]_block_invoke.49 (in CoreFoundation) + 132 [0x187238fa4]
+ 2350 dispatch_apply (in libdispatch.dylib) + 96 [0x186eb111c]
+ 2006 _dispatch_apply_with_attr_f (in libdispatch.dylib) + 1272 [0x186eb0f6c]
+ ! 1996 _sigtramp (in libsystem_platform.dylib) + 0,56 [0x18706370c,0x187063744]
+ ! 7 _sigtramp (in libsystem_platform.dylib) + 76 [0x187063758]
+ ! : 7 __sigreturn (in libsystem_kernel.dylib) + 8,4 [0x18702278c,0x187022788]
+ ! 3 _sigtramp (in libsystem_platform.dylib) + 56 [0x187063744]
+ ! 2 signal_handler (in python3.11) + 32 [0x1022a147c]
+ ! | 2 trip_signal (in python3.11) + 64 [0x10229feb4]
+ ! | 1 _PyEval_SignalReceived (in python3.11) + 56 [0x1022115f0]
+ ! | + 1 PyThread_get_thread_ident (in python3.11) + 36 [0x102279d10]
+ ! | + 1 pthread_self (in libsystem_pthread.dylib) + 0 [0x18705552c]
+ ! | 1 _PyEval_SignalReceived (in python3.11) + 108 [0x102211624]
+ ! 1 signal_handler (in python3.11) + 0 [0x1022a145c]
+ 344 _dispatch_apply_with_attr_f (in libdispatch.dylib) + 1296 [0x186eb0f84]
2350 Thread_634715
2350 start_wqthread (in libsystem_pthread.dylib) + 8 [0x187054b9c]
2350 _pthread_wqthread (in libsystem_pthread.dylib) + 368 [0x187055e98]
2350 __workq_kernreturn (in libsystem_kernel.dylib) + 8 [0x1870189dc]

Total number in stack (recursive counted multiple, when >=5):
27 _PyEval_Vector (in python3.11) + 200 [0x102211fb4]
26 _PyEval_EvalFrameDefault (in python3.11) + 41612 [0x10221c2e0]
10 _PyVectorcall_Call (in python3.11) + 116 [0x10212b52c]
8 PyImport_ImportModuleLevelObject (in python3.11) + 1088 [0x10224f644]
8 PyObject_CallMethodObjArgs (in python3.11) + 92 [0x10212cae8]
8 object_vacall (in python3.11) + 256 [0x10212cc80]
7 cfunction_vectorcall_FASTCALL_KEYWORDS (in python3.11) + 160 [0x102177e38]
6 _PyEval_EvalFrameDefault (in python3.11) + 23232 [0x102217b14]
5 PyEval_EvalCode (in python3.11) + 272 [0x102211e84]
5 builtin_exec (in python3.11) + 916 [0x10220e7b4]
5 dyld4::Loader::runInitializersBottomUp(dyld4::RuntimeState&, dyld3::Array<dyld4::Loader const*>&, dyld3::Array<dyld4::Loader const*>&) const (in dyld) + 212 [0x186caf1b4]

Sort by top of stack, same collapsed (when >= 5):
__workq_kernreturn (in libsystem_kernel.dylib) 2350
_sigtramp (in libsystem_platform.dylib) 1996
_dispatch_apply_with_attr_f (in libdispatch.dylib) 344
__sigreturn (in libsystem_kernel.dylib) 7

Component(s)

Python

Activity

  1. added
    Status: confirmed
    and removed
    Status: confirmed
    on Nov 18, 2026
  2. thisisnic commented on Nov 18, 2026

    @thisisnic
    Member

    Thanks for the report. The stack shows the import stuck in curl_global_init, which is called from a static initialiser in the Azure SDK's curl.cpp when libarrow is loaded. Azure support was enabled in the macOS wheels in 16.0.0 (#39971), which is why 15.0.1 isn't affected.

    Does python -c "import pyarrow" run directly from a terminal also hang, or only when launched the way your application starts it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions