bugtex4ht - Bugs: bug #534, biblatex failure w/ datetime

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

bug #534: biblatex failure w/ datetime

Submitted by:  Jürgen Spitzmüller <jspitzm>
Submitted on:  Fri Nov 5 14:52:52 2021  
 
Category: NonePriority: 5 - Normal
Severity: 5 - NormalStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Closed

(Jump to the original submission Jump to the original submission)

Tue Dec 14 16:30:53 2021, comment #10:

Hi Deimi, really thanks for the tests, they are needed and I never managed to create them.

I am closing this issue again.

Michal Hoftich <michal_h21>
Project Member
Mon Dec 13 19:49:22 2021, comment #9:

Hi Michal, yes - [t-tex4ht] is an attempt to resurrect regression testing.

This case is 'green' now. Thanks for the fix.

Deimantas Galčius <deimi>
Project Member
Sat Dec 11 09:45:30 2021, comment #8:

Hi Deimi, I saw that you recently added more tests to https://github.com/dgalcius/t-tex4ht. That's really nice, thanks.

I finally fixed this issue yesterday. I've found that the issue with the Datetime package was that it loads the Ifthen package. Nameref then redefines the \ifthenelse command, which broke BibLaTeX in the sample file for this issue.

I had to put fixes to hyperref-hooks.4ht, to load Ifthen package explicitly before Nameref. We then revert \ifthenelse back to it's original definition in ifthen.4ht, before we apply TeX4ht hooks. With this, the redefinitions to \ifthenelse done by Nameref are lost. It were local redefinitions to \ref and \pageref commands. TeX4ht does some fixes to these commands in \ifthenelse too, so I guess that it should be OK to ignore Namerefs fixes.

Michal Hoftich <michal_h21>
Project Member
Wed Dec 8 20:23:11 2021, comment #7:

The last good revision for this case is rev. 972.
rev. 973 is offending. No idea how to fix it though :)

Deimantas Galčius <deimi>
Project Member
Wed Dec 8 14:35:11 2021, comment #6:

I've introduced Nameref back into hyperref-hooks.4ht, because it caused issues for other users:

https://tex.stackexchange.com/q/623902/2891

It also broke new TeX4ht documentation, where I use the Nameref package.

So now BibLaTeX + Hyperref fails again.

Michal Hoftich <michal_h21>
Project Member
Sat Nov 6 18:47:50 2021, comment #5:

Karl: Yes, Hyperref loads Nameref. I think the code in TeX4ht was originally from Eitan, although I modified it a bit. I really hope that we don't eventually find that it was actually useful, as issues related to it were really painful to debug.

Jürgen: That's great! So I am closing this.

Michal Hoftich <michal_h21>
Project Member
Sat Nov 6 05:54:18 2021, comment #4:

Yes, this fixes it. Thanks!

Jürgen Spitzmüller <jspitzm>
Fri Nov 5 22:36:53 2021, comment #3:

I believe hyperref implicitly loads nameref. That's probably Eitan set it up that way? Don't really know ... anyway, yay for any and all improvements :).

Karl Berry <karl>
Project Administrator
Fri Nov 5 17:13:31 2021, comment #2:

I've found that the real problem was loading of Nameref in hyperref-hooks.4ht file. I've found that when I remove it, it fixes this issue, but also several other issues that were recently reported. I don't even know why it was there, I think this code was quite old. Anyway, I haven't found any errors when I removed it, so I hope we don't find any in the future.

The updated biblatex-hooks.4ht and hyperref-hooks.4ht files are attached.

(file #443, file #444)

Michal Hoftich <michal_h21>
Project Member
Fri Nov 5 16:00:32 2021, comment #1:

Thanks for the report, Jürgen, I will take a look at this issue.

One thing that I noticed is that this error disappears with the Datetime2 package, which should be updated version of Datetime.

Michal Hoftich <michal_h21>
Project Member
Fri Nov 5 14:52:52 2021, original submission:

This is following https://tex.stackexchange.com/a/619816/19291

As of rev. 1005, documents with biblatex that also load datetime fail due to the automatic loading of nameref.

If you compile the attached MW with

make4ht -f odt biblatex-fail
biber biblatex-fail
make4ht -f odt biblatex-fail

you'll get on the second make4ht run:

[ERROR] htlatex: Compilation errors in the htlatex run
[ERROR] htlatex: Filename Line Message
[ERROR] htlatex: ./biblatex-fail.tex 10 Argument of \@secondoftwo has an extra }.
[ERROR] htlatex: ./biblatex-fail.tex 10 Paragraph ended before \@secondoftwo was complete.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing = inserted for \ifnum.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.
[ERROR] htlatex: Compilation errors in the htlatex run
[ERROR] htlatex: Filename Line Message
[ERROR] htlatex: ./biblatex-fail.tex 10 Argument of \@secondoftwo has an extra }.
[ERROR] htlatex: ./biblatex-fail.tex 10 Paragraph ended before \@secondoftwo was complete.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing = inserted for \ifnum.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.
[ERROR] htlatex: Compilation errors in the htlatex run
[ERROR] htlatex: Filename Line Message
[ERROR] htlatex: ./biblatex-fail.tex 10 Argument of \@secondoftwo has an extra }.
[ERROR] htlatex: ./biblatex-fail.tex 10 Paragraph ended before \@secondoftwo was complete.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing = inserted for \ifnum.
[ERROR] htlatex: ./biblatex-fail.tex 10 Missing number, treated as zero.

If you remove the call to datetime, compilation succeeds.

Jürgen Spitzmüller <jspitzm>

 

Attached Files
file #443:  hyperref-hooks.4ht added by michal_h21 (798B - application/octet-stream)
file #444:  biblatex-hooks.4ht added by michal_h21 (1kB - application/octet-stream)
file #442:  biblatex-fail.tex added by jspitzm (199B - text/x-tex)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by deimi (Posted a comment)
  • -unavailable- added by karl (Posted a comment)
  • -unavailable- added by michal_h21 (Posted a comment)
  • -unavailable- added by jspitzm (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    6 latest changes follow.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue Dec 14 16:30:53 2021michal_h21Open/ClosedOpen=>Closed
    Wed Dec 8 14:35:11 2021michal_h21Open/ClosedClosed=>Open
    Sat Nov 6 18:47:50 2021michal_h21Open/ClosedOpen=>Closed
    Fri Nov 5 17:13:31 2021michal_h21Attached File-=>Added hyperref-hooks.4ht, #443
      Attached File-=>Added biblatex-hooks.4ht, #444
    Fri Nov 5 14:52:52 2021jspitzmAttached File-=>Added biblatex-fail.tex, #442
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup+gray