Closed kunyuan closed 2 years ago
Hi @kunyuan , thanks for reporting this.
The problem appears to be this: https://github.com/JuliaIO/JLD2.jl/blob/eebc00865eadbfcbc1dfc970f297039af62fb68c/src/compression.jl#L94
Loading CodecZlib
dynamically creates a new worldage.
This is meant to be taken care of by invokelatest
.
However, since your struct contains two compressible arrays,
there will be another call to get_compressor
from the old worldage leading to the error.
I have some problems with compressed data saving using JLD2.jl. I find the following simple script will go wrong if the CodecZlib is dynamically loaded.
I got the following error message.
Note that if I import CodecZlib explicitly in the test.jl script, then the above error message goes away. So the problem is related to dynamically loaded CodecZlib.
I am using julia 1.6.2 and JLD2 0.4.17, CodecZlib 0.7.0.
Do you have any idea how to fix this problem in the source code? Thanks for your help!