Closed dduportal closed 3 months ago
The equivalent code can be found here: https://github.com/ruby/base64/blob/master/lib/base64.rb#L328-L333
It would look something like this:
str = ([str].pack 'm0').tr '+/', '-_'
The extension shouldn't be relying on Asciidoctor to load a library from stdlib (and base64 is being removed from the stdlib in Ruby 3.4 anyway).
That's weird to remove such as useful and tiny lib from stdlib 🤔 I wonder why they thought it was a good idea.
I totally agree that it was a very unwise choice.
In the meantime, is a workaround available?
You can also just add -r base64
when invoking the asciidoctor command.
Thanks @ggrossetie , I'll watch when the new release will be available to ensure the Docker image of asciidoctor
picks it!
Hello @ggrossetie @mojavelinux could we release a new version of asciidoctor-kroki
to ensure the fix is available (as it is blocking https://github.com/asciidoctor/docker-asciidoctor/pull/437)?
As I'm requesting this, I do not mind to help if needed (and possible in term of permissions of course)
Sorry forgot to push the release, 0.10.0 should be available soon
@dduportal Could you please give it a try https://rubygems.org/gems/asciidoctor-kroki/versions/0.10.0 ?
@dduportal Could you please give it a try https://rubygems.org/gems/asciidoctor-kroki/versions/0.10.0 ?
Many thanks @ggrossetie !
Awesome 👍🏻
Hi! As caught in https://github.com/asciidoctor/docker-asciidoctor/pull/437/, asciidoctor-kroki
ruby-0.9.1
(latest available) does not work with asciidoctor2.0.22
.2.0.22
changelog clearly states this is deprecated to support upcoming Ruby 3.4.@mojavelinux recommens to use
String#pack
but I'm not good enough in Ruby to understand what it means (searching https://ruby-doc.org/3.3.0/String.html does not show me tangible result) so I'm opening an issue whether a PR.