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

Update to ImageMagick 7.1 #232

Open
ViralBShah opened this issue Jun 4, 2024 · 3 comments · May be fixed by #234
Open

Update to ImageMagick 7.1 #232

ViralBShah opened this issue Jun 4, 2024 · 3 comments · May be fixed by #234

Comments

@ViralBShah
Copy link
Contributor

ImageMagick 7.1 is now in Yggdrasil. JuliaRegistries/General#105903. Would be nice to get this package to upgrade. I imagine the upgrade may not be easy or straightforward, and hence opening this issue to see if someone might be interested in trying it out and seeing what it takes.

@ViralBShah
Copy link
Contributor Author

ViralBShah commented Jun 4, 2024

Dup of #69. cc @musm.

@ViralBShah ViralBShah reopened this Jun 4, 2024
@ViralBShah
Copy link
Contributor Author

ViralBShah commented Jun 4, 2024

Keeping this one open instead of the older one, so that it is on top.

Just casually bumping the version number in Project.toml yields various issues. It seems that the ImageMagick 7 does not have the GetImageChannelDepth API any more:

        Info Packages marked with ⌃ and ⌅ have new versions available. Those with ⌃ may be upgradable, but those with ⌅ are restricted by compatibility constraints from upgrading.
Precompiling project...
  87 dependencies successfully precompiled in 43 seconds. 10 already precompiled.
  1 dependency had output during precompilation:
┌ ImageMagick
│  WARNING: using deprecated binding Colors.RGB1 in ImageCore.
│  , use XRGB instead.
│  WARNING: using deprecated binding Colors.RGB4 in ImageCore.
│  , use RGBX instead.
└  
     Testing Running tests...
Binary png: Error During Test at /home/viralbshah/.julia/dev/ImageMagick/test/constructed_images.jl:27
  Got exception outside of a @test
  could not load symbol "MagickGetImageChannelDepth":
  /home/viralbshah/.julia/artifacts/049f45ea8fb58e8e3a4bec857f50a240394776d3/lib/libMagickWand-7.Q16HDRI.so: undefined symbol: MagickGetImageChannelDepth
  Stacktrace:
    [1] getimagechanneldepth
      @ ~/.julia/dev/ImageMagick/src/libmagickwand.jl:430 [inlined]
    [2] _metadata(wand::MagickWand)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:85
    [3] load_(file::String, permute_horizontal::Bool; ImageType::Type, extraprop::String, extrapropertynames::Nothing, view::Bool)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:149
    [4] load_ (repeats 2 times)
      @ ~/.julia/dev/ImageMagick/src/ImageMagick.jl:138 [inlined]
    [5] load(::String)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:126
    [6] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:31 [inlined]
    [7] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
    [8] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:28 [inlined]
    [9] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
   [10] top-level scope
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:11
   [11] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [12] top-level scope
      @ ~/.julia/dev/ImageMagick/test/runtests.jl:6
   [13] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [14] top-level scope
      @ none:6
   [15] eval
      @ ./boot.jl:385 [inlined]
   [16] exec_options(opts::Base.JLOptions)
      @ Base ./client.jl:291
   [17] _start()
      @ Base ./client.jl:552
Gray png: Error During Test at /home/viralbshah/.julia/dev/ImageMagick/test/constructed_images.jl:59
  Got exception outside of a @test
  could not load symbol "MagickGetImageChannelDepth":
  /home/viralbshah/.julia/artifacts/049f45ea8fb58e8e3a4bec857f50a240394776d3/lib/libMagickWand-7.Q16HDRI.so: undefined symbol: MagickGetImageChannelDepth
  Stacktrace:
    [1] getimagechanneldepth
      @ ~/.julia/dev/ImageMagick/src/libmagickwand.jl:430 [inlined]
    [2] _metadata(wand::MagickWand)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:85
    [3] load_(file::String, permute_horizontal::Bool; ImageType::Type, extraprop::String, extrapropertynames::Nothing, view::Bool)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:149
    [4] load_ (repeats 2 times)
      @ ~/.julia/dev/ImageMagick/src/ImageMagick.jl:138 [inlined]
    [5] load(::String)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:126
    [6] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:64 [inlined]
    [7] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
    [8] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:60 [inlined]
    [9] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
   [10] top-level scope
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:11
   [11] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [12] top-level scope
      @ ~/.julia/dev/ImageMagick/test/runtests.jl:6
   [13] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [14] top-level scope
      @ none:6
   [15] eval
      @ ./boot.jl:385 [inlined]
   [16] exec_options(opts::Base.JLOptions)
      @ Base ./client.jl:291
   [17] _start()
      @ Base ./client.jl:552
Color: Error During Test at /home/viralbshah/.julia/dev/ImageMagick/test/constructed_images.jl:88
  Got exception outside of a @test
  Colorspace 23 not recognized
  Stacktrace:
    [1] error(::String, ::Int32, ::String)
      @ Base ./error.jl:44
    [2] getimagecolorspace
      @ ~/.julia/dev/ImageMagick/src/libmagickwand.jl:365 [inlined]
    [3] _metadata(wand::MagickWand)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:75
    [4] load_(file::String, permute_horizontal::Bool; ImageType::Type, extraprop::String, extrapropertynames::Nothing, view::Bool)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:149
    [5] load_ (repeats 2 times)
      @ ~/.julia/dev/ImageMagick/src/ImageMagick.jl:138 [inlined]
    [6] load(::String)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:126
    [7] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:95 [inlined]
    [8] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
    [9] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:89 [inlined]
   [10] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
   [11] top-level scope
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:11
   [12] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [13] top-level scope
      @ ~/.julia/dev/ImageMagick/test/runtests.jl:6
   [14] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [15] top-level scope
      @ none:6
   [16] eval
      @ ./boot.jl:385 [inlined]
   [17] exec_options(opts::Base.JLOptions)
      @ Base ./client.jl:291
   [18] _start()
      @ Base ./client.jl:552
Alpha: Error During Test at /home/viralbshah/.julia/dev/ImageMagick/test/constructed_images.jl:126
  Got exception outside of a @test
  Colorspace 23 not recognized
  Stacktrace:
    [1] error(::String, ::Int32, ::String)
      @ Base ./error.jl:44
    [2] getimagecolorspace
      @ ~/.julia/dev/ImageMagick/src/libmagickwand.jl:365 [inlined]
    [3] _metadata(wand::MagickWand)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:75
    [4] load_(file::String, permute_horizontal::Bool; ImageType::Type, extraprop::String, extrapropertynames::Nothing, view::Bool)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:149
    [5] load_ (repeats 2 times)
      @ ~/.julia/dev/ImageMagick/src/ImageMagick.jl:138 [inlined]
    [6] load(::String)
      @ ImageMagick ~/.julia/dev/ImageMagick/src/ImageMagick.jl:126
    [7] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:130 [inlined]
    [8] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
    [9] macro expansion
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:127 [inlined]
   [10] macro expansion
      @ ~/.julia/juliaup/julia-1.10.3+0.x64.linux.gnu/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
   [11] top-level scope
      @ ~/.julia/dev/ImageMagick/test/constructed_images.jl:11
   [12] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [13] top-level scope
      @ ~/.julia/dev/ImageMagick/test/runtests.jl:6
   [14] include(fname::String)
      @ Base.MainInclude ./client.jl:489
   [15] top-level scope
      @ none:6
   [16] eval
      @ ./boot.jl:385 [inlined]
   [17] exec_options(opts::Base.JLOptions)
      @ Base ./client.jl:291
   [18] _start()
      @ Base ./client.jl:552

@dgleich
Copy link

dgleich commented Oct 8, 2024

Okay, I've been looking at this update... the stuff with image channel depth is easy to fix as you can just remove the getimagechanneldepth'' calls and replace them with getimagedepth'', which I think now does the same thing.

But after that issue, I'm running into a weird issue where ImageMagick seems to flip the interpretation of binary images entirely between 6 and 7. So all the tests on binary images break. (And then there are a few more after that...)

@dgleich dgleich linked a pull request Oct 8, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants