-
Notifications
You must be signed in to change notification settings - Fork 391
Update to Pandoc 3.6.3 and Typst 0.13.0 #12262
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
Conversation
upstream pandoc no longer has a definitions.typst but we are keeping definitions.typ they moved horizontalrule into their default.typst base template and IMO our template.typ is already so dissimilar from their default.typst that we might as well keep this where it was
some deprecation warnings. i am less sure about the s/amount/abs change but was getting the error
error: length does not contain field amount
┌─ docs/smoke-all/typst/callout.typ:38:32
│
38 │ fields.below = fields.below.amount
│ ^^^^^^
can't find any documentation of amount so i'm hoping abs was meant here
and small change in HTML styles template
from jgm/pandoc@1eed55f Add CRediT roles to JATS Enable annotating author roles using the Contribution Role Taxonomy (CRediT) and export this information in conformant JATS
|
We have a few issues in our snapshot test that I have seen in the other PR I am working one. Some differences related to table it seems.
+ <w:sectPr />
- <w:sectPr>
- <w:footnotePr>
-
-
- <w:numRestart w:val="eachSect" />
-
-
- </w:footnotePr>
- </w:sectPr>
| Dog | 4/5 |
| Cat | 4/5 |
| Horse | 3/5 |
| Ant | 5/5 |
+
</div>
See <a href="#tbl-pets_rating" class="quarto-xref">Table 1</a>.
Lua error
./run-tests.sh docs/smoke-all/2023/11/16/tbl-cap-classes.qmd
> Activating virtualenv from .venv for Python tests in Quarto
> Using Python from /home/cderv/project/quarto-cli/tests/.venv/bin/python
> VIRTUAL_ENV: /home/cderv/project/quarto-cli/tests/.venv
docs/smoke-all/2023/11/16/tbl-cap-classes.qmd
running 1 test from ./smoke/smoke-all.test.ts
[smoke] > quarto render docs/smoke-all/2023/11/16/tbl-cap-classes.qmd --to html ...
------- output -------
[verify] > No Errors or Warnings
----- output end -----
[smoke] > quarto render docs/smoke-all/2023/11/16/tbl-cap-classes.qmd --to html ... FAILED (1s)
ERRORS
[smoke] > quarto render docs/smoke-all/2023/11/16/tbl-cap-classes.qmd --to html => ./test.ts:329:8
error: AssertionError: Failed assertion:
--------------------------------------------------------------------------------
[smoke] > quarto render docs/smoke-all/2023/11/16/tbl-cap-classes.qmd --to html
./run-tests.sh smoke/smoke-all.test.ts
[verify] > No Errors or Warnings
Error or Warnings During Execution
|Error
at renderFiles (file:///home/cderv/project/quarto-cli/src/command/render/render-files.ts:350:23)
at eventLoopTick (ext:core/01_core.js:175:7)
at async render (file:///home/cderv/project/quarto-cli/src/command/render/render-shared.ts:104:18)
at async Command.actionHandler (file:///home/cderv/project/quarto-cli/src/command/render/cmd.ts:251:26)
at async Command.execute (https://deno.land/x/[email protected]/command/command.ts:1948:7)
at async Command.parseCommand (https://deno.land/x/[email protected]/command/command.ts:1780:14)
at async quarto (file:///home/cderv/project/quarto-cli/src/quarto.ts:190:5)
at async Object.execute (file:///home/cderv/project/quarto-cli/tests/test.ts:119:7)
at async fn (file:///home/cderv/project/quarto-cli/tests/test.ts:221:13)
at async innerWrapped (ext:cli/40_test.js:191:5)|
AssertionError: Error or Warnings During Execution
|Error
at renderFiles (file:///home/cderv/project/quarto-cli/src/command/render/render-files.ts:350:23)
at eventLoopTick (ext:core/01_core.js:175:7)
at async render (file:///home/cderv/project/quarto-cli/src/command/render/render-shared.ts:104:18)
at async Command.actionHandler (file:///home/cderv/project/quarto-cli/src/command/render/cmd.ts:251:26)
at async Command.execute (https://deno.land/x/[email protected]/command/command.ts:1948:7)
at async Command.parseCommand (https://deno.land/x/[email protected]/command/command.ts:1780:14)
at async quarto (file:///home/cderv/project/quarto-cli/src/quarto.ts:190:5)
at async Object.execute (file:///home/cderv/project/quarto-cli/tests/test.ts:119:7)
at async fn (file:///home/cderv/project/quarto-cli/tests/test.ts:221:13)
at async innerWrapped (ext:cli/40_test.js:191:5)|
at Module.assert (https://jsr.io/@std/assert/0.224.0/assert.ts:18:11)
at assert (https://jsr.io/@std/testing/0.224.0/asserts.ts:608:11)
at Object.verify (file:///home/cderv/project/quarto-cli/tests/verify.ts:126:7)
at fn (file:///home/cderv/project/quarto-cli/tests/test.ts:240:25)
at eventLoopTick (ext:core/01_core.js:175:7)
at async innerWrapped (ext:cli/40_test.js:191:5)
at async outerWrapped (ext:cli/40_test.js:134:14)Because of check in Lua quarto-cli/tests/docs/smoke-all/2023/11/16/checktable.lua Lines 1 to 5 in 52beccf
I am looking into those, starting by last one. |
|
So it seems the feature to set classes on table is no more working as it was This is why the check fails It seems setting to quarto-cli/src/resources/filters/quarto-pre/table-classes.lua Lines 55 to 57 in 91c665a
I did not found which change caused this, but Caption long is using Block, so I changed to empty blocks |
|
Regarding the docx issue, it is a change in Pandoc for Docx (jgm/pandoc@6fbb50f) to solve jgm/pandoc#10577 So I'll update the snapshot |
Related to this change in pandoc - jgm/pandoc@6fbb50f) to solve jgm/pandoc#10577
|
And I finally found the last change. Pandoc is no more collapsing initial newline in Rawblock Previous pandoc Updated pandoc We see one more newline in newest pandoc. This comes from our Table processing with add some quarto-cli/src/resources/filters/customnodes/floatreftarget.lua Lines 1053 to 1054 in 52beccf
and we use newline at the start. It seems we do it also at
So I'll fix that too. |
They add no effect prior to Pandoc 3.6.3 are they were collapse. From Pandoc 3.6.3 they are not anymore Related Pandoc change: jgm/pandoc@d9281d1 to solve jgm/pandoc#10477
follow up of 0d0fc8d
This reverts commit 73244fb.
…>` when caption location is bottom.
|
This PR passes tests now. So update to Pandoc 3.6.3 seems ok. We could even do the update without the latex template change, as in Quarto, we are providing all the templates, and it seems the new version of Pandoc didn't break our previous template. To be discussed. |
| if #quarto.utils.as_inlines(tbl.caption.long) == 0 then | ||
| tbl.caption.long = nil | ||
| tbl.caption.long = pandoc.Blocks({}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tarleb this is surprising to us. Do you know why setting to nil was not replacing the value ?
tbl.caption.long was not modified
This is related to pandoc 3.4 to 3.6.3 update
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's kind of the same as when filter functions return nil. But I'll need to check.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this new for element content ?
Only the update triggered it.
From jgm/pandoc@9be0963 Introducing new `babeloptions` and moving option in `doc-class.tex` partial
…emplate This helps with comparing original and ours
… in its own template This is a breaking change for users who have custom templates. The new templates are more modular and easier to customize, but they now mix Pandoc's partial and Quarto's partials. Changes: - Add an new template logic dedicated to beamer as Pandoc has split beamer in its own template. Aim is to make it easy to update the beamer template in the future. - Add a new LaTeX template that is based on the default template, but it is split into several partials that are provided by Pandoc and by Quarto. - Adapt the update script to use the new partials and to update the beamer template separately. - Add two Quarto partials that are used in the new LaTeX template: `babel-lang.tex` and `biblio-config.tex`. The new organization possibly could break custom format that tweak the `pandoc.tex` partials as it now contains part of the default `common.latex` partial from Pandoc. This means that if you have a custom template that uses `pandoc.tex` you will need to update it to use the new partials.
It means previous missing package is not needed anymore. Pandoc related change: jgm/pandoc@9be0963
Opening this PR to run the tests as I noticed some issues locally.
LaTeX template updates are done separately in