Skip to content
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

Segfault on import PythonCall #563

Open
nhz2 opened this issue Oct 7, 2024 · 5 comments
Open

Segfault on import PythonCall #563

nhz2 opened this issue Oct 7, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@nhz2
Copy link

nhz2 commented Oct 7, 2024

Affects: PythonCall

Describe the bug
I got a segfault using PythonCall on GitHub CI for Apple M1.

https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82

This seems to be an intermittent issue.
Your system

Julia Version 1.11.0-rc4
Commit b4b9add84db (2024-09-25 11:03 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: macOS (arm64-apple-darwin22.4.0)
  CPU: 3 × Apple M1 (Virtual)
  WORD_SIZE: 64
  LLVM: libLLVM-16.0.6 (ORCJIT, apple-m1)
Threads: 1 default, 0 interactive, 1 GC (on 3 virtual cores)
Testing ZipArchives
      Status `/private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/Project.toml`
  [4c88cf16] Aqua v0.8.7
  [944b1d66] CodecZlib v0.7.6
  [36869731] Malt v1.1.1
  [6fe1bfb0] OffsetArrays v1.14.1
  [6099a3de] PythonCall v0.9.23
  [efcf1570] Setfield v1.1.1
  [3bb67fe8] TranscodingStreams v0.11.3
  [49080126] ZipArchives v2.3.0 `~/work/ZipArchives.jl/ZipArchives.jl`
  [a5390f91] ZipFile v0.10.1
  [1e303b3e] LibArchive_jll v3.7.4+0
  [2a0f44e3] Base64 v1.11.0
  [a63ad114] Mmap v1.11.0
  [44cfe95a] Pkg v1.11.0
  [9a3f8284] Random v1.11.0
  [ea8e919c] SHA v0.7.0
  [8dfed614] Test v1.11.0
  [3f19e933] p7zip_jll v17.4.0+2
      Status `/private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/Manifest.toml`
  [4c88cf16] Aqua v0.8.7
  [dce04be8] ArgCheck v2.3.0
  [6309b1aa] CodecInflate64 v0.1.3
  [944b1d66] CodecZlib v0.7.6
  [34da2185] Compat v4.16.0
  [992eb4ea] CondaPkg v0.2.23
  [187b0558] ConstructionBase v1.5.8
  [9a962f9c] DataAPI v1.16.0
  [e2d170a0] DataValueInterfaces v1.0.0
  [0c81fc1b] InputBuffers v1.0.0
  [82899510] IteratorInterfaceExtensions v1.0.0
  [692b3bcd] JLLWrappers v1.6.0
  [0f8b85d8] JSON3 v1.14.0
  [1914dd2f] MacroTools v0.5.13
  [36869731] Malt v1.1.1
  [0b3b1443] MicroMamba v0.1.14
  [6fe1bfb0] OffsetArrays v1.14.1
  [bac558e1] OrderedCollections v1.6.3
  [69de0a69] Parsers v2.8.1
  [fa939f87] Pidfile v1.3.0
  [aea7be01] PrecompileTools v1.2.1
  [21216c6a] Preferences v1.4.3
  [6099a3de] PythonCall v0.9.23
  [05181044] RelocatableFolders v1.0.1
  [ae029012] Requires v1.3.0
  [6c6a2e73] Scratch v1.2.1
  [efcf1570] Setfield v1.1.1
  [1e83bf80] StaticArraysCore v1.4.3
  [856f2bd8] StructTypes v1.11.0
  [3783bdb8] TableTraits v1.0.1
  [bd369af6] Tables v1.12.0
  [3bb67fe8] TranscodingStreams v0.11.3
  [e17b2a0c] UnsafePointers v1.0.0
  [49080126] ZipArchives v2.3.0 `~/work/ZipArchives.jl/ZipArchives.jl`
  [a5390f91] ZipFile v0.10.1
  [1fd713ca] Attr_jll v2.5.2+0
  [6e34b625] Bzip2_jll v1.0.8+1
  [2e619515] Expat_jll v2.6.2+0
  [1e303b3e] LibArchive_jll v3.7.4+0
  [94ce4f54] Libiconv_jll v1.17.0+0
  [5ced3[41](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:44)a] Lz4_jll v1.10.0+1
  [458c3c95] OpenSSL_jll v3.0.15+1
  [ffd25f8a] XZ_jll v5.4.6+0
  [3161d3a3] Zstd_jll v1.5.6+1
  [ed5aba05] acl_jll v2.3.2+0
  [f8abcde7] micromamba_jll v1.5.8+0
  [0dad84c5] ArgTools v1.1.2
  [56f22d72] Artifacts v1.11.0
  [2a0f44e3] Base64 v1.11.0
  [ade2ca70] Dates v1.11.0
  [8ba89e20] Distributed v1.11.0
  [f43a241f] Downloads v1.6.0
  [7b1f6079] FileWatching v1.11.0
  [9fa8497b] Future v1.11.0
  [b77e0a4c] InteractiveUtils v1.11.0
  [4af54fe1] LazyArtifacts v1.11.0
  [b27032c2] LibCURL v0.6.4
  [76f85450] LibGit2 v1.11.0
  [8f399da3] Libdl v1.11.0
  [56ddb016] Logging v1.11.0
  [d6f4376e] Markdown v1.11.0
  [a63ad114] Mmap v1.11.0
  [ca575930] NetworkOptions v1.2.0
  [44cfe95a] Pkg v1.11.0
  [de0858da] Printf v1.11.0
  [3fa0cd96] REPL v1.11.0
  [9a3f8284] Random v1.11.0
  [ea8e919c] SHA v0.7.0
  [9e88b[42](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:45)a] Serialization v1.11.0
  [6462fe0b] Sockets v1.11.0
  [f489334b] StyledStrings v1.11.0
  [fa267f1f] TOML v1.0.3
  [a4e569a6] Tar v1.10.0
  [8dfed614] Test v1.11.0
  [cf7118a7] UUIDs v1.11.0
  [4ec0a83e] Unicode v1.11.0
  [deac9b[47](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:50)] LibCURL_jll v8.6.0+0
  [e37daf67] LibGit2_jll v1.7.2+0
  [29816b5a] LibSSH2_jll v1.11.0+1
  [c8ffd9c3] MbedTLS_jll v2.28.6+0
  [14a3606d] MozillaCACerts_jll v2023.12.12
  [83775a58] Zlib_jll v1.2.13+1
  [8e8[50](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:53)ede] nghttp2_jll v1.59.0+0
  [3f19e933] p7zip_jll v17.4.0+2

Additional context

Stack trace:

[3148] signal 11 (2): Segmentation fault: 11
in expression starting at /Users/runner/work/ZipArchives.jl/ZipArchives.jl/test/external_unzippers.jl:7
_PyObject_Malloc at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyUnicode_New at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
unicode_decode_utf8 at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyUnicode_FromFormatV at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyErr_Format at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
_PyObject_GenericGetAttrWithDict at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyObject_GetAttr at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
import_ensure_initialized at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyImport_ImportModuleLevelObject at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyImport_Import at /private/var/folders/0g/hj_q_pzx65bbjnslxz9n0src0000gn/T/jl_yiKQEd/.CondaPkg/env/lib/libpython3.11.dylib (unknown line)
PyImport_Import at /Users/runner/.julia/packages/PythonCall/Nr75f/src/C/pointers.jl:303
unknown function (ip: 0x12ed1409b)
unknown function (ip: 0x12ece431b)
unknown function (ip: 0x12ece42b7)
macro expansion at /Users/runner/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:132 [inlined]
pyimport at /Users/runner/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:1561
unknown function (ip: 0x12ece41ff)
unknown function (ip: 0x12ecbd833)
unknown function (ip: 0x12ecbd6e3)
pyimport at /Users/runner/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:1562 [inlined]
init_consts at /Users/runner/.julia/packages/PythonCall/Nr75f/src/Core/consts.jl:205
unknown function (ip: 0x12ecbd6a7)
unknown function (ip: 0x12eca421f)
unknown function (ip: 0x12eca40df)
__init__ at /Users/runner/.julia/packages/PythonCall/Nr75f/src/Core/Core.jl:42
unknown function (ip: 0x12eca4077)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
jl_module_run_initializer at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:76
run_module_init at ./loading.jl:1336
register_restored_modules at ./loading.jl:1324
#_include_from_serialized#1066 at ./loading.jl:1213
_include_from_serialized at ./loading.jl:1169 [inlined]
_include_from_serialized at ./loading.jl:1169 [inlined]
#_require_search_from_serialized#1076 at ./loading.jl:1975
_require_search_from_serialized at ./loading.jl:1898
jfptr__require_search_from_serialized_44910.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
_require at ./loading.jl:2435
__require_prelocked at ./loading.jl:2300
jfptr___require_prelocked_70208.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
jl_f__call_in_world at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/builtins.c:894
#invoke_in_world#3 at ./essentials.jl:1088 [inlined]
invoke_in_world at ./essentials.jl:1085 [inlined]
_require_prelocked at ./loading.jl:2287
macro expansion at ./loading.jl:2226 [inlined]
macro expansion at ./lock.jl:273 [inlined]
__require at ./loading.jl:2183
jfptr___require_70144.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
jl_f__call_in_world at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/builtins.c:894
#invoke_in_world#3 at ./essentials.jl:1088 [inlined]
invoke_in_world at ./essentials.jl:1085 [inlined]
require at ./loading.jl:2176
jfptr_require_70141.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
call_require at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:486 [inlined]
eval_import_path at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:523
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:812
eval_body at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:629
eval_body at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:539
jl_interpret_toplevel_thunk at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:821
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:943
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:886
ijl_toplevel_eval at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:952 [inlined]
ijl_toplevel_eval_in at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:994
eval at ./boot.jl:430 [inlined]
include_string at ./loading.jl:[262](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:265)8
_include at ./loading.jl:2688
include at ./sysimg.jl:38
unknown function (ip: 0x102884087)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
do_call at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:126
eval_stmt_value at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:174
eval_body at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:663
jl_interpret_toplevel_thunk at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:821
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:943
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:886
ijl_toplevel_eval at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:952 [inlined]
ijl_toplevel_eval_in at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:994
eval at ./boot.jl:430 [inlined]
include_string at ./loading.jl:2628
_include at ./loading.jl:[268](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:271)8
include at ./sysimg.jl:38
unknown function (ip: 0x102884087)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
do_call at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:126
eval_stmt_value at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:174
eval_body at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:663
jl_interpret_toplevel_thunk at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:821
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:943
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:886
ijl_toplevel_eval at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:952 [inlined]
ijl_toplevel_eval_in at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:994
eval at ./boot.jl:430 [inlined]
include_string at ./loading.jl:2628
_include at ./loading.jl:2688
include at ./sysimg.jl:38
unknown function (ip: 0x102884087)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
do_call at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:126
eval_stmt_value at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:174
eval_body at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:663
jl_interpret_toplevel_thunk at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/interpreter.c:821
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:943
jl_toplevel_eval_flex at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:886
ijl_toplevel_eval at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:952 [inlined]
ijl_toplevel_eval_in at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/toplevel.c:994
jlplt_ijl_toplevel_eval_in_[283](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/11219970406/job/31187122812?pr=82#step:6:286)55.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
eval at ./boot.jl:430 [inlined]
exec_options at ./client.jl:296
_start at ./client.jl:531
jfptr__start_72508.1 at /Users/runner/hostedtoolcache/julia/1.11.0-rc4/aarch64/lib/julia/sys.dylib (unknown line)
jl_apply at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/./julia.h:2157 [inlined]
true_main at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/jlapi.c:900
jl_repl_entrypoint at /Users/julia/.julia/scratchspaces/a66863c6-20e8-4ff4-8a62-49f30b1f605e/agent-cache/default-honeycrisp-XG3Q6T6R70.0/build/default-honeycrisp-XG3Q6T6R70-0/julialang/julia-release-1-dot-11/src/jlapi.c:1059
Allocations: 23655843 (Pool: 23653807; Big: 2036); GC: 20
Package ZipArchives errored during testing (received signal: 11)
@nhz2 nhz2 added the bug Something isn't working label Oct 7, 2024
@tmistele
Copy link

I have a very similar issue with the final julia 1.11.0. The segfault is very non-deterministic. It doesn't always happen and when it happens it doesn't always happen at the same point. Some backtraces look like this:

[36693] signal 11 (1): Segmentation fault
in expression starting at [REDACTED].jl
PyType_IsSubtype at /usr/lib64/libpython3.12.so.1.0 (unknown line)
unknown function (ip: 0x7fb959cbaf3d)
_PyEval_EvalFrameDefault at /usr/lib64/libpython3.12.so.1.0 (unknown line)
unknown function (ip: 0x7fb959cdce0a)
PyObject_CallObject at $HOME/.julia/packages/PythonCall/Nr75f/src/C/pointers.jl:303 [inlined]
macro expansion at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:132 [inlined]
pycallargs at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:220
#pycall#21 at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:243 [inlined]
pycall at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:233 [inlined]
#_#11 at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:357 [inlined]
Py at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:357 [inlined]
[...]

Others like this:

[36447] signal 11 (1): Segmentation fault
in expression starting at [REDACTED].jl
PyObject_GetAttr at /usr/lib64/libpython3.12.so.1.0 (unknown line)
PyUFuncOverride_GetNonDefaultArrayUfunc at [REDACTED]/.venv/lib/python3.12/site-packages/numpy/_core/_multiarray_umath.cpython-312-x86_64-linux-gnu.so (unknown line)
PyUFunc_CheckOverride at [REDACTED]/.venv/lib/python3.12/site-packages/numpy/_core/_multiarray_umath.cpython-312-x86_64-linux-gnu.so (unknown line)
ufunc_generic_fastcall at [REDACTED]/.venv/lib/python3.12/site-packages/numpy/_core/_multiarray_umath.cpython-312-x86_64-linux-gnu.so (unknown line)
PyObject_Vectorcall at /usr/lib64/libpython3.12.so.1.0 (unknown line)
_PyEval_EvalFrameDefault at /usr/lib64/libpython3.12.so.1.0 (unknown line)
unknown function (ip: 0x7f829fedce0a)
PyObject_CallObject at $HOME/.julia/packages/PythonCall/Nr75f/src/C/pointers.jl:303 [inlined]
macro expansion at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:132 [inlined]
pycallargs at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:220
#pycall#21 at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:243 [inlined]
pycall at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/builtins.jl:233 [inlined]
#_#11 at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:357 [inlined]
Py at $HOME/.julia/packages/PythonCall/Nr75f/src/Core/Py.jl:357 [inlined]
[...]

Running the same code with julia 1.10.4 doesn't have this issue.

@dpinol
Copy link
Contributor

dpinol commented Oct 10, 2024

I also get seg faults, on linux, only on multithread, in applications which worked with julia 1.10

@tmistele
Copy link

tmistele commented Nov 5, 2024

Fwiw, here's a somewhat self-contained example that reliably crashes for me within a handful of runs (but it's non-deterministic), see this repository. Its only dependencies are QuadGK on the julia side and camb on the python side. The crashes only happen with julia 1.11, not with julia 1.10. This is on x86_64 Linux.

import QuadGK
using PythonCall

const camb = pyimport("camb")

const Pm = let
	params = camb.set_params(H0=70)
	params.set_matter_power(redshifts=0:.1:1.5, kmax=9.5)
	res = camb.get_results(params)
	power = res.get_matter_power_interpolator(nonlinear=false, k_hunit=false, hubble_units=false, extrap_kmax=1e6).P
	(z, k) -> let
		pyval = power(z, k)
		pyconvert(Float64, pyval)
	end
end

calculate_stuff = (R, z) -> let
	θ = R/900.
	integrand =-> let
		kl =/((1+z) * R)
		sqrt(lθ)*cos(lθ)*Pm(z, kl) /*θ)
	end
	QuadGK.quadgk(integrand, 0, 50)[1]
end

zvalues = [0.05, 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7]
Rvalues = collect(.1:.2:7.0)
@info @. calculate_stuff(Rvalues, zvalues')

@CarloLucibello
Copy link
Contributor

CarloLucibello commented Dec 20, 2024

I get a segmentation error on julia v1.11.2 with another example. This is my system:

julia> versioninfo()
Julia Version 1.11.2
Commit 5e9a32e7af2 (2024-12-01 20:02 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: macOS (arm64-apple-darwin24.0.0)
  CPU: 8 × Apple M1 Pro
  WORD_SIZE: 64
  LLVM: libLLVM-16.0.6 (ORCJIT, apple-m1)
Threads: 1 default, 0 interactive, 1 GC (on 6 virtual cores)
Environment:
  JULIA_PKG_SERVER_REGISTRY_PREFERENCE = eager

My example involves just loading HuggingFaceDatasets.jl (which uses PythonCall) from another package. It works fine if just used in a script instead.

The error happens at precompilation time. GNNDatasets is a package containing the single line import HuggingFaceDatasets. This is what happens:

julia> activate .

julia> using GNNDatasets
Precompiling GNNDatasets...
Info Given GNNDatasets was explicitly requested, output will be shown live 

[68039] signal 11 (2): Segmentation fault: 11
in expression starting at none:0
_ZN3Aws4Http19CurlHandleContainerD2Ev at /Users/carlo/.julia/dev/GraphNeuralNetworks/GNNDatasets/.CondaPkg/env/lib/libaws-cpp-sdk-core.dylib (unknown line)s
Allocations: 3387461 (Pool: 3387279; Big: 182); GC: 9
  ✗ GNNDatasets
  0 dependencies successfully precompiled in 7 seconds. 171 already precompiled.

ERROR: The following 1 direct dependency failed to precompile:

GNNDatasets 

Failed to precompile GNNDatasets [2afd1aaa-255b-4d45-920d-62446192254f] to "/Users/carlo/.julia/compiled/v1.11/GNNDatasets/jl_R2rNZG".
[68039] signal 11 (2): Segmentation fault: 11
in expression starting at none:0
_ZN3Aws4Http19CurlHandleContainerD2Ev at /Users/carlo/.julia/dev/GraphNeuralNetworks/GNNDatasets/.CondaPkg/env/lib/libaws-cpp-sdk-core.dylib (unknown line)
Allocations: 3387461 (Pool: 3387279; Big: 182); GC: 

I can provide a full reproducer if needed.

@nhz2
Copy link
Author

nhz2 commented Mar 17, 2025

I'm getting a similar error on Julia 1.10 on Windows.

Here is the code that triggers the error.

https://github.com/JuliaIO/ZipArchives.jl/blob/99b5e8d99b048de340f2cc3c2b1f807b8f2c8789/test/external_unzippers.jl#L7-L11

try
    import PythonCall
catch
    @warn "PythonCall not working :("
end
Julia Version 1.10.9
Commit 5595d20a28 (2025-03-10 12:51 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: Windows (x86_64-w64-mingw32)
  CPU: 4 × AMD EPYC 7763 64-Core Processor                
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-15.0.7 (ORCJIT, znver3)
Threads: 1 default, 0 interactive, 1 GC (on 4 virtual cores)
Details
│
│ To reproduce this CI run locally run the following from the same repository state on julia version 1.10.9:
│
│ `import Pkg; Pkg.test(;coverage=true, julia_args=["--check-bounds=yes", "--compiled-modules=yes", "--depwarn=yes"], force_latest_compatible_version=false, allow_reresolve=true)`
│
     Testing ZipArchives
      Status `C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\Project.toml`
  [4c88cf16] Aqua v0.8.11
  [944b1d66] CodecZlib v0.7.8
  [36869731] Malt v1.1.2
  [6fe1bfb0] OffsetArrays v1.15.0
  [6099a3de] PythonCall v0.9.24
  [efcf1570] Setfield v1.1.2
  [3bb67fe8] TranscodingStreams v0.11.3
  [49080126] ZipArchives v2.4.1 `D:\a\ZipArchives.jl\ZipArchives.jl`
  [a5390f91] ZipFile v0.10.1
  [1e303b3e] LibArchive_jll v3.7.4+0
  [2a0f44e3] Base64
  [a63ad114] Mmap
  [44cfe95a] Pkg v1.10.0
  [9a3f8284] Random
  [ea8e919c] SHA v0.7.0
  [8dfed614] Test
  [3f19e933] p7zip_jll v17.4.0+2
      Status `C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\Manifest.toml`
  [4c88cf16] Aqua v0.8.11
  [dce04be8] ArgCheck v2.4.0
  [6309b1aa] CodecInflate64 v0.1.3
  [944b1d66] CodecZlib v0.7.8
  [34da2185] Compat v4.16.0
  [992eb4ea] CondaPkg v0.2.26
  [187b0558] ConstructionBase v1.5.8
  [9a962f9c] DataAPI v1.16.0
  [e2d170a0] DataValueInterfaces v1.0.0
  [0c81fc1b] InputBuffers v1.0.0
  [82899510] IteratorInterfaceExtensions v1.0.0
  [692b3bcd] JLLWrappers v1.7.0
  [0f8b85d8] JSON3 v1.14.1
  [1914dd2f] MacroTools v0.5.15
  [36869731] Malt v1.1.2
  [0b3b1443] MicroMamba v0.1.14
  [6fe1bfb0] OffsetArrays v1.15.0
  [bac558e1] OrderedCollections v1.8.0
  [69de0a69] Parsers v2.8.1
  [fa939f87] Pidfile v1.3.0
  [aea7be01] PrecompileTools v1.2.1
  [21216c6a] Preferences v1.4.3
  [6099a3de] PythonCall v0.9.24
  [05181044] RelocatableFolders v1.0.1
  [ae029012] Requires v1.3.1
  [6c6a2e73] Scratch v1.2.1
  [efcf1570] Setfield v1.1.2
  [1e83bf80] StaticArraysCore v1.4.3
  [856f2bd8] StructTypes v1.11.0
  [3783bdb8] TableTraits v1.0.1
  [bd369af6] Tables v1.12.0
  [3bb67fe8] TranscodingStreams v0.11.3
  [e17b2a0c] UnsafePointers v1.0.0
  [49080126] ZipArchives v2.4.1 `D:\a\ZipArchives.jl\ZipArchives.jl`
  [a5390f91] ZipFile v0.10.1
  [1fd713ca] Attr_jll v2.5.2+0
  [6e34b625] Bzip2_jll v1.0.9+0
  [2e619515] Expat_jll v2.6.5+0
  [1e303b3e] LibArchive_jll v3.7.4+0
  [94ce4f54] Libiconv_jll v1.18.0+0
  [5ced3[41](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:44)a] Lz4_jll v1.10.1+0
  [458c3c95] OpenSSL_jll v3.0.16+0
  [ffd25f8a] XZ_jll v5.6.4+1
  [3161d3a3] Zstd_jll v1.5.7+1
  [ed5aba05] acl_jll v2.3.2+0
  [f8abcde7] micromamba_jll v1.5.8+0
  [4d7b5844] pixi_jll v0.41.3+0
  [0dad84c5] ArgTools v1.1.1
  [56f22d72] Artifacts
  [2a0f44e3] Base64
  [ade2ca70] Dates
  [8ba89e20] Distributed
  [f43a241f] Downloads v1.6.0
  [7b1f6079] FileWatching
  [9fa8497b] Future
  [b77e0a4c] InteractiveUtils
  [4af54fe1] LazyArtifacts
  [b27032c2] LibCURL v0.6.4
  [76f85450] LibGit2
  [8f399da3] Libdl
  [56ddb016] Logging
  [d6f4376e] Markdown
  [a63ad114] Mmap
  [ca575930] NetworkOptions v1.2.0
  [44cfe95a] Pkg v1.10.0
  [de0858da] Printf
  [3fa0cd96] REPL
  [9a3f8284] Random
  [ea8e919c] SHA v0.7.0
  [9e88b[42](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:45)a] Serialization
  [6462fe0b] Sockets
  [fa267f1f] TOML v1.0.3
  [a4e569a6] Tar v1.10.0
  [8dfed614] Test
  [cf7118a7] UUIDs
  [4ec0a83e] Unicode
  [deac9b47] LibCURL_jll v8.4.0+0
  [e37daf67] LibGit2_jll v1.6.4+0
  [29816b5a] LibSSH2_jll v1.11.0+1
  [c8ffd9c3] MbedTLS_jll v2.28.2+1
  [14a3606d] MozillaCACerts_jll v2023.1.10
  [83775a58] Zlib_jll v1.2.13+1
  [8e850ede] nghttp2_jll v1.52.0+1
  [3f19e933] p7zip_jll v17.4.0+2
Precompiling packages...
   3159.7 ms  ✓ ZipArchives
  1 dependency successfully precompiled in 5 seconds. 50 already precompiled.
     Testing Running tests...
Test Summary:    | Pass  Total  Time
Method ambiguity |    1      1  1.5s
Test Summary:           | Pass  Total  Time
Unbound type parameters |    1      1  0.1s
Test Summary:     | Pass  Total  Time
Undefined exports |    1      1  0.0s
Test Summary:                              | Pass  Total  Time
Compare Project.toml and test/Project.toml |    1      1  0.1s
Test Summary:      | Pass  Total  Time
Stale dependencies |    1      1  1.4s
Test Summary: | Pass  Total  Time
Compat bounds |    4      4  0.2s
Test Summary: | Pass  Total  Time
Piracy        |    1      1  0.1s
Test Summary:    | Pass  Total  Time
Persistent tasks |    1      1  4.6s
Test Summary: | Pass  Total  Time
bytes2string  |   25     25  0.3s
Test Summary:                        | Pass  Total  Time
Write and Read zip file IO interface |   25     25  4.0s
Test Summary:              | Pass  Total  Time
check_name_used unit tests | 1999   1999  0.2s
Test Summary: | Pass  Total  Time
show methods  |    7      7  0.8s
    CondaPkg Found dependencies: C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\CondaPkg.toml
    CondaPkg Resolving changes
             + openssl
             + python
    CondaPkg Initialising pixi
             │ C:\Users\runneradmin\.julia\artifacts\aa881b8313f97d7b8797934574a1cfe551f85222\bin\pixi.exe
             │ init
             │ --format pixi
             └ C:\Users\RUNNER~1\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg
Created C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\pixi.toml
    CondaPkg Wrote C:\Users\RUNNER~1\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\pixi.toml
             │ [dependencies]
             │ openssl = ">=3, <3.1"
             │ 
             │     [dependencies.python]
             │     channel = "conda-forge"
             │     build = "*cpython*"
             │     version = ">=3.8,<4"
             │ 
             │ [project]
             │ name = ".CondaPkg"
             │ platforms = ["win-64"]
             │ channels = ["conda-forge"]
             │ channel-priority = "strict"
             └ description = "automatically generated by CondaPkg.jl"
    CondaPkg Installing packages
             │ C:\Users\runneradmin\.julia\artifacts\aa881b8313f97d7b8797934574a1cfe551f85222\bin\pixi.exe
             │ install
             └ --manifest-path C:\Users\RUNNER~1\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\pixi.toml
The default environment has been installed.

Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ACCESS_VIOLATION at 0x7ffb051b3346 -- Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
in expression starting at D:\a\ZipArchives.jl\ZipArchives.jl\test\external_unzippers.jl:7
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_New at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_DecodeUTF8 at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_AsUCS4Copy at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_AsUCS4Copy at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_FromFormatV at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyErr_BadInternalCall at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyErr_Format at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyObject_GenericGetAttrWithDict at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyObject_GetAttr at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_SetModuleString at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_ImportModuleLevelObject at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_Import at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_Import at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\C\pointers.jl:303
unknown function (ip: 000001d69ea0b3ae)
unknown function (ip: 000001d69ea0a47d)
unknown function (ip: 000001d69ea0a228)
macro expansion at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\Py.jl:132 [inlined]
pyimport at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\builtins.jl:1561
unknown function (ip: 000001d69ea0a14b)
unknown function (ip: 000001d69ea0a08d)
unknown function (ip: 000001d69ea09eab)
pyimport at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\builtins.jl:1562 [inlined]
init_consts at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\consts.jl:205
unknown function (ip: 000001d69ea09e64)
unknown function (ip: 000001d69ea0880d)
unknown function (ip: 000001d69ea08642)
__init__ at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\Core.jl:42
unknown function (ip: 000001d69ea085e5)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_module_run_initializer at C:/workdir/src\toplevel.c:76
run_module_init at .\loading.jl:1193
register_restored_modules at .\loading.jl:1181
_include_from_serialized at .\loading.jl:1126
_require_search_from_serialized at .\loading.jl:1651
_require at .\loading.jl:2008
__require_prelocked at .\loading.jl:1882
jfptr___require_prelocked_84968.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_in_world at C:/workdir/src\builtins.c:831
#invoke_in_world#3 at .\essentials.jl:926 [inlined]
invoke_in_world at .\essentials.jl:923 [inlined]
_require_prelocked at .\loading.jl:1873
macro expansion at .\loading.jl:1860 [inlined]
macro expansion at .\lock.jl:267 [inlined]
__require at .\loading.jl:1823
jfptr___require_84931.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_in_world at C:/workdir/src\builtins.c:831
#invoke_in_world#3 at .\essentials.jl:926 [inlined]
invoke_in_world at .\essentials.jl:923 [inlined]
require at .\loading.jl:1816
jfptr_require_84928.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
call_require at C:/workdir/src\toplevel.c:481 [inlined]
eval_import_path at C:/workdir/src\toplevel.c:518
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:805
eval_body at C:/workdir/src\interpreter.c:583
eval_body at C:/workdir/src\interpreter.c:544
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:9[43](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:46) [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2146
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2146
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2146
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
exec_options at .\client.jl:296
_start at .\client.jl:557
jfptr__start_86959.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
true_main at C:/workdir/src\jlapi.c:582
jl_repl_entrypoint at C:/workdir/src\jlapi.c:731
mainCRTStartup at C:/workdir/cli\loader_exe.c:58
BaseThreadInitThunk at C:\Windows\System32\KERNEL32.DLL (unknown line)
RtlUserThreadStart at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
Allocations: 14067838 (Pool: 14055488; Big: 12350); GC: 22

Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ACCESS_VIOLATION at 0x7ffb051b3346 -- Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
in expression starting at D:\a\ZipArchives.jl\ZipArchives.jl\test\external_unzippers.jl:7
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_New at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_DecodeUTF8 at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_FromString at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_InitializeMain at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_InitializeMain at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_FinalizeEx at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_FinalizeEx at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\C\pointers.jl:303 [inlined]
#37 at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\C\context.jl:194
unknown function (ip: 000001d69ea0c874)
_atexit at .\initdefs.jl:428
jfptr__atexit_83415.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
ijl_atexit_hook at C:/workdir/src\init.c:280
ijl_exit at C:/workdir/src\init.c:207
jl_exception_handler at C:/workdir/src\signals-win.c:337 [inlined]
jl_exception_handler at C:/workdir/src\signals-win.c:229
__julia_personality at C:/workdir/src\win32_ucontext.c:28
_chkstk at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
RtlVirtualUnwind2 at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
KiUserExceptionDispatcher at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
Py_GetAllocatedBlocks at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_New at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_DecodeUTF8 at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_AsUCS4Copy at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_AsUCS4Copy at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyUnicode_FromFormatV at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyErr_BadInternalCall at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyErr_Format at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyObject_GenericGetAttrWithDict at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyObject_GetAttr at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_SetModuleString at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_ImportModuleLevelObject at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_Import at C:\Users\runneradmin\AppData\Local\Temp\jl_lpu4Ht\.CondaPkg\.pixi\envs\default\python311.dll (unknown line)
PyImport_Import at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\C\pointers.jl:303
unknown function (ip: 000001d69ea0b3ae)
unknown function (ip: 000001d69ea0a47d)
unknown function (ip: 000001d69ea0a228)
macro expansion at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\Py.jl:132 [inlined]
pyimport at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\builtins.jl:1561
unknown function (ip: 000001d69ea0a14b)
unknown function (ip: 000001d69ea0a08d)
unknown function (ip: 000001d69ea09eab)
pyimport at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\builtins.jl:1562 [inlined]
init_consts at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\consts.jl:205
unknown function (ip: 000001d69ea09e64)
unknown function (ip: 000001d69ea0880d)
unknown function (ip: 000001d69ea08642)
__init__ at C:\Users\runneradmin\.julia\packages\PythonCall\WMWY0\src\Core\Core.jl:42
unknown function (ip: 000001d69ea085e5)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_module_run_initializer at C:/workdir/src\toplevel.c:76
run_module_init at .\loading.jl:1193
register_restored_modules at .\loading.jl:1181
_include_from_serialized at .\loading.jl:1126
_require_search_from_serialized at .\loading.jl:1651
_require at .\loading.jl:2008
__require_prelocked at .\loading.jl:1882
jfptr___require_prelocked_84968.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_in_world at C:/workdir/src\builtins.c:831
#invoke_in_world#3 at .\essentials.jl:926 [inlined]
invoke_in_world at .\essentials.jl:923 [inlined]
_require_prelocked at .\loading.jl:1873
macro expansion at .\loading.jl:1860 [inlined]
macro expansion at .\lock.jl:267 [inlined]
__require at .\loading.jl:1823
jfptr___require_84931.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
jl_f__call_in_world at C:/workdir/src\builtins.c:831
#invoke_in_world#3 at .\essentials.jl:926 [inlined]
invoke_in_world at .\essentials.jl:923 [inlined]
require at .\loading.jl:1816
jfptr_require_84928.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
call_require at C:/workdir/src\toplevel.c:481 [inlined]
eval_import_path at C:/workdir/src\toplevel.c:518
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:805
eval_body at C:/workdir/src\interpreter.c:583
eval_body at C:/workdir/src\interpreter.c:5[44](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:47)
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:21[46](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:49)
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2146
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
include_string at .\loading.jl:2146
_include at .\loading.jl:2206
include at .\client.jl:494
unknown function (ip: 000001d689ee02eb)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
do_call at C:/workdir/src\interpreter.c:126
eval_value at C:/workdir/src\interpreter.c:223
eval_stmt_value at C:/workdir/src\interpreter.c:174 [inlined]
eval_body at C:/workdir/src\interpreter.c:635
jl_interpret_toplevel_thunk at C:/workdir/src\interpreter.c:775
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:934
jl_toplevel_eval_flex at C:/workdir/src\toplevel.c:877
ijl_toplevel_eval at C:/workdir/src\toplevel.c:943 [inlined]
ijl_toplevel_eval_in at C:/workdir/src\toplevel.c:985
eval at .\boot.jl:385 [inlined]
exec_options at .\client.jl:296
_start at .\client.jl:557
jfptr__start_86959.1 at C:\hostedtoolcache\windows\julia\1.10.9\x64\lib\julia\sys.dll (unknown line)
jl_apply at C:/workdir/src\julia.h:1982 [inlined]
true_main at C:/workdir/src\jlapi.c:582
jl_repl_entrypoint at C:/workdir/src\jlapi.c:731
mainCRTStartup at C:/workdir/cli\loader_exe.c:58
BaseThreadInitThunk at C:\Windows\System32\KERNEL32.DLL (unknown line)
RtlUserThreadStart at C:\Windows\SYSTEM32\ntdll.dll (unknown line)
Allocations: 14067838 (Pool: 14055[48](https://github.com/JuliaIO/ZipArchives.jl/actions/runs/13886192680/job/38851223990?pr=89#step:6:51)8; Big: 12350); GC: 22
Package ZipArchives errored during testing
Error: Process completed with exit code 1.

@nhz2 nhz2 changed the title Segfault using PythonCall on Apple M1 with Julia 1.11.0-rc4 Segfault on import PythonCall Mar 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants