asciidoctor / asciidoctor-bibtex

Add bibtex citation support for asciidoc documents
Other
66 stars 28 forks source link

undefined method `to_citeproc' for an instance of String (NoMethodError) #98

Closed wmat closed 6 months ago

wmat commented 6 months ago

This is on Fedora 39, Ruby-2.2.0:

/home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in block in to_citeproc': asciidoctor: FAILED: /home/wmat/dev/riscv-isa-manual/src/riscv-unprivileged.adoc: Failed to load AsciiDoc document - undefined methodto_citeproc' for an instance of String (NoMethodError)

  map { |n| n.to_citeproc(options) }
             ^^^^^^^^^^^^
    from /home/wmat/.rvm/rubies/ruby-3.3.0/lib/ruby/3.3.0/forwardable.rb:240:in `each'
    from /home/wmat/.rvm/rubies/ruby-3.3.0/lib/ruby/3.3.0/forwardable.rb:240:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in `map'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:172:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:69:in `block in convert!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:132:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:132:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:68:in `convert!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:55:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:610:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `block in to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `map'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/processor.rb:76:in `initialize'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/extensions.rb:96:in `new'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/extensions.rb:96:in `process'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:545:in `[]'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:545:in `block in parse'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:544:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:544:in `parse'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/load.rb:84:in `load'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:78:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `block in convert_file'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `open'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `convert_file'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:129:in `block in invoke!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:112:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:112:in `invoke!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-pdf-2.3.12/bin/asciidoctor-pdf:46:in `<top (required)>'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/asciidoctor-pdf:25:in `load'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/asciidoctor-pdf:25:in `<main>'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/ruby_executable_hooks:22:in `eval'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/ruby_executable_hooks:22:in `<main>'

/home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in block in to_citeproc': undefined methodto_citeproc' for an instance of String (NoMethodError)

  map { |n| n.to_citeproc(options) }
             ^^^^^^^^^^^^
    from /home/wmat/.rvm/rubies/ruby-3.3.0/lib/ruby/3.3.0/forwardable.rb:240:in `each'
    from /home/wmat/.rvm/rubies/ruby-3.3.0/lib/ruby/3.3.0/forwardable.rb:240:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in `map'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/names.rb:81:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:172:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:69:in `block in convert!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:132:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:132:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:68:in `convert!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry/citeproc_converter.rb:55:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/entry.rb:610:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `block in to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `map'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/bibtex-ruby-5.1.6/lib/bibtex/bibliography.rb:407:in `to_citeproc'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/processor.rb:76:in `initialize'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/extensions.rb:96:in `new'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-bibtex-0.8.0/lib/asciidoctor-bibtex/extensions.rb:96:in `process'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:545:in `[]'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:545:in `block in parse'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:544:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/document.rb:544:in `parse'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/load.rb:84:in `load'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:78:in `convert'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `block in convert_file'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `open'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/convert.rb:190:in `convert_file'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:129:in `block in invoke!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:112:in `each'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-2.0.20/lib/asciidoctor/cli/invoker.rb:112:in `invoke!'
    from /home/wmat/.rvm/gems/ruby-3.3.0/gems/asciidoctor-pdf-2.3.12/bin/asciidoctor-pdf:46:in `<top (required)>'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/asciidoctor-pdf:25:in `load'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/asciidoctor-pdf:25:in `<main>'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/ruby_executable_hooks:22:in `eval'
    from /home/wmat/.rvm/gems/ruby-3.3.0/bin/ruby_executable_hooks:22:in `<main>'

make: *** [Makefile:60: unpriv-isa-asciidoc.pdf] Error 1

mojavelinux commented 6 months ago

This is a duplicate of #95 and has already been fixed in main. We are awaiting a new release.

@ProgramFan Could you push out another release when you get a chance?

ProgramFan commented 5 months ago

OK. I will do it today.

mojavelinux commented 5 months ago

Thanks! I appreciate it.