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

Errors on generate #3

Open
atomfrede opened this issue Jul 31, 2024 · 5 comments
Open

Errors on generate #3

atomfrede opened this issue Jul 31, 2024 · 5 comments

Comments

@atomfrede
Copy link

I got the following issue when trying to generate from a fresh clone:

A problem occurred evaluating root project 'docToolchain'.
> Could not resolve all artifacts for configuration 'classpath'.
   > Could not find org.codehaus.groovy.modules.http-builder:http-builder:0.7.2.
     Searched in the following locations:
       - https://plugins.gradle.org/m2/org/codehaus/groovy/modules/http-builder/http-builder/0.7.2/http-builder-0.7.2.pom
     If the artifact you are trying to retrieve can be found in the repository but without metadata in 'Maven POM' format, you need to adjust the 'metadataSources { ... }' of the repository declaration.
     Required by:
         unspecified:unspecified:unspecified

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

This looks a bit like a version issue as 0.7.1 is available, but I don't know how/where to fix that version for testing. Or it also has to do with the recent f***up with jcenter and the gradle plugin portal.

By using the latest doctoolchain version inside the wrapper that error is gone, but the ruby asciidoc extension are not working (according to #1 thats the reason why using the older version). I tried to make it work, by first changing rubyExtensions = ['src/ruby/asciidoctor-lists'] to rubyExtensions = ['src/ruby/asciidoctor-lists/asciidoctor-lists.rb'] but just resulting in an other error message.

Exception in thread "main" org.jruby.exceptions.LoadError: (LoadError) no such file to load -- ../../git/github/atomfrede/iSAQB-Template/src/ruby/asciidoctor-lists/asciidoctor-lists.rb
        at org.jruby.RubyKernel.require(org/jruby/RubyKernel.java:1017)
        at uri_3a_classloader_3a_.META_minus_INF.jruby_dot_home.lib.ruby.stdlib.rubygems.core_ext.kernel_require.require(uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:85)
        at RUBY.<main>(<script>:1)

Just for testing removing the extension configuration completely gave me another error:

Caused by: org.asciidoctor.jruby.internal.AsciidoctorCoreException: org.jruby.exceptions.SystemCallError: (ENOENT) No such file or directory - mplus1mn-regular-ascii-conums.ttf not found in GEM_FONTS_DIR
        at org.asciidoctor.jruby.internal.JRubyAsciidoctor.convertFile(JRubyAsciidoctor.java:402)
        at org.asciidoctor.jruby.internal.JRubyAsciidoctor.convertFile(JRubyAsciidoctor.java:368)
        at org.asciidoctor.gradle.remote.AsciidoctorJavaExec$_convertFiles_closure4.doCall(AsciidoctorJavaExec.groovy:87)
        ... 22 more
Caused by: org.jruby.exceptions.SystemCallError: (ENOENT) No such file or directory - mplus1mn-regular-ascii-conums.ttf not found in GEM_FONTS_DIR

@MBoegers Can you still generate?

@atomfrede
Copy link
Author

I fixed it by changing the following the the local doctoolchain folder:

  • change version to 0.7.1
  • remove classpath 'nl.jworks.markdown_to_asciidoc:markdown_to_asciidoc:1.0' as it also can't be found (and it is not needed for this use case)

So works for me now. Thanks for providing the template.

@rdmueller
Copy link
Member

thanx for the issue report.
interesting fix. It took me longer to fix this in the main branch. this is because of the shut down of jcenter. doctoolchain 3.4.0 should resolve this too

@atomfrede
Copy link
Author

Yes partly it does (the dependency issues). But with 3.4.0 the asciidoctor ruby extensions are not working and the pdf generation fails because of a missing font (but maybe thats just my environment)

@rdmueller
Copy link
Member

oh, that are two important hints!
can you send your fix as PR?

@atomfrede
Copy link
Author

I did not change anything in this repo. Just in the downloaded local dtc for version 2.1.0 not sure if thats still relevant for the current 3.4.x

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

No branches or pull requests

2 participants