We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
LoadError: type DataType has no field mutable
I'm having an issue while saving a PyObject together with PyCallJLD.jl. I'm doing:
PyObject
JLD.save(joinpath(ODINN.root_dir, "test/data/gdirs.jld"), "gdirs", gdirs)
Which returns the following error:
Error encountered while save FileIO.File{FileIO.DataFormat{:JLD}, String}("/home/jovyan/Julia/fork/ODINN/test/data/gdirs.jld"). Fatal error: ERROR: LoadError: type DataType has no field mutable Stacktrace: [1] getproperty @ ./Base.jl:37 [inlined] [2] write_ref(parent::JLD.JldFile, data::Vector{UInt8}, wsession::JLD.JldWriteSession) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:696 [3] macro expansion @ /srv/julia/pkg/packages/JLD/JHrZe/src/jld_types.jl:639 [inlined] [4] h5convert!(out::Ptr{UInt8}, file::JLD.JldFile, x::PyCallJLD.PyObjectSerialization, wsession::JLD.JldWriteSession) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/jld_types.jl:654 [5] write_compound(parent::JLD.JldFile, name::String, s::PyCallJLD.PyObjectSerialization, wsession::JLD.JldWriteSession; kargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:733 [6] write_compound @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:727 [inlined] [7] #_write#23 @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:723 [inlined] [8] _write @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:723 [inlined] [9] #write#17 @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:542 [inlined] [10] write @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:542 [inlined] [11] (::JLD.var"#41#42"{String, PyObject, Tuple{}})(file::JLD.JldFile) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:1260 [12] jldopen(::JLD.var"#41#42"{String, PyObject, Tuple{}}, ::String, ::Vararg{String}; kws::Base.Pairs{Symbol, Bool, Tuple{Symbol, Symbol}, NamedTuple{(:compatible, :compress), Tuple{Bool, Bool}}}) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:261 [13] #fileio_save#40 @ /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:1258 [inlined] [14] fileio_save(::FileIO.File{FileIO.DataFormat{:JLD}, String}, ::String, ::PyObject) @ JLD /srv/julia/pkg/packages/JLD/JHrZe/src/JLD.jl:1255 [15] invokelatest(::Any, ::Any, ::Vararg{Any}; kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ Base ./essentials.jl:716 [16] invokelatest(::Any, ::Any, ::Vararg{Any}) @ Base ./essentials.jl:714 [17] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::FileIO.Formatted, ::String, ::Vararg{Any}; options::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:219 [18] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::FileIO.Formatted, ::String, ::PyObject) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:197 [19] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::Symbol, ::String, ::String, ::Vararg{Any}; options::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:185 [20] action @ /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:185 [inlined] [21] #save#20 @ /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:129 [inlined] [22] save(::String, ::String, ::PyObject) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:126 [23] run() @ Main ~/Julia/fork/ODINN/src/scripts/toy_model.jl:45 [24] top-level scope @ ~/Julia/fork/ODINN/src/scripts/toy_model.jl:120 Stacktrace: [1] handle_error(e::ErrorException, q::Base.PkgId, bt::Vector{Union{Ptr{Nothing}, Base.InterpreterIP}}) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/error_handling.jl:61 [2] handle_exceptions(exceptions::Vector{Tuple{Any, Union{Base.PkgId, Module}, Vector}}, action::String) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/error_handling.jl:56 [3] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::FileIO.Formatted, ::String, ::Vararg{Any}; options::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:228 [4] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::FileIO.Formatted, ::String, ::PyObject) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:197 [5] action(::Symbol, ::Vector{Union{Base.PkgId, Module}}, ::Symbol, ::String, ::String, ::Vararg{Any}; options::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}}) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:185 [6] action @ /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:185 [inlined] [7] #save#20 @ /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:129 [inlined] [8] save(::String, ::String, ::PyObject) @ FileIO /srv/julia/pkg/packages/FileIO/u9YLx/src/loadsave.jl:126 [9] run() @ Main ~/Julia/fork/ODINN/src/scripts/toy_model.jl:45 [10] top-level scope @ ~/Julia/fork/ODINN/src/scripts/toy_model.jl:120 in expression starting at /home/jovyan/Julia/fork/ODINN/src/scripts/toy_model.jl:120
Other packages (e.g. Zygote.jl) have had similar issues, apparently starting from Julia 1.7. An example of a fix here: FluxML/Zygote.jl#1003
Any idea how to fix this or to get a workaround? Thanks in advance!
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I'm having an issue while saving a
PyObject
together with PyCallJLD.jl. I'm doing:JLD.save(joinpath(ODINN.root_dir, "test/data/gdirs.jld"), "gdirs", gdirs)
Which returns the following error:
Other packages (e.g. Zygote.jl) have had similar issues, apparently starting from Julia 1.7. An example of a fix here: FluxML/Zygote.jl#1003
Any idea how to fix this or to get a workaround? Thanks in advance!
The text was updated successfully, but these errors were encountered: