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

issues with mintinline and curly braces #170

Open
DanySK opened this issue Mar 30, 2021 · 4 comments
Open

issues with mintinline and curly braces #170

DanySK opened this issue Mar 30, 2021 · 4 comments

Comments

@DanySK
Copy link

DanySK commented Mar 30, 2021

Hi,
I am using minted to highlight yaml in my document, and apparently this gives a hard time to pandoc. In particular, I get an error at this line of code:

Seeds are set at the top level of the simulation specification, as in the following snippet: \mintinline{yaml}{seeds: { simulation: 0, scenario: 0 }}.

when running pandoc --to=plain --wrap=none alchemist-tutorial.tex I get:

Error at "source" (line 679, column 150):
unexpected }
expecting \end{document}
Seeds are set at the top level of the simulation specification, as in the following snippet: \mintinline{yaml}{seeds: { simulation: 0, scenario: 0 } }.
                                                                                                                                                     ^

Is this a bug in Pandoc? Thanks

@DanySK DanySK changed the title issues with mintinline and curly brackets issues with mintinline and curly braces Mar 30, 2021
@svenevs
Copy link
Member

svenevs commented Mar 31, 2021

Hey @DanySK this seems like a bug in the filter, can you look at #43 and see if there are some changes that fix your issue? When I wrote it I didn't consider { brace problems } but that PR fixed them to my knowledge.

Otherwise, please include alchemist-tutorial.tex and the generated output and any other information you can (e.g., pandoc version). I'm not familiar with that specific usage of pandoc (the plain format and wrap), but \mintinline{yaml}{seeds: { simulation: 0, scenario: 0 }} looks extremely suspicious -- if the minted.lua filter emitted that then it should get fixed (the interior braces for the actual yaml code are a problem) 🙂

@DanySK
Copy link
Author

DanySK commented Apr 9, 2021

Hi @svenevs,
I cannot attach the whole file as it is protected by NDA. Should I try to produce an excerpt?

❯ pandoc --version
pandoc 2.11.4
Compiled with pandoc-types 1.22, texmath 0.12.1.1, skylighting 0.10.4,
citeproc 0.3.0.9, ipynb 0.1.0.1
User data directory: /home/danysk/.local/share/pandoc or /home/danysk/.pandoc
Copyright (C) 2006-2021 John MacFarlane. Web:  https://pandoc.org
This is free software; see the source for copying conditions. There is no
warranty, not even for merchantability or fitness for a particular purpose.

I'm not sure #43 applies: braces are correctly matched there.

@svenevs
Copy link
Member

svenevs commented Apr 9, 2021

I wrote that filter and tried to give some educated guesses but I'm not going to be able to help fix this anytime soon (personal reasons). Please provide a minimal example that can be reproduced if you would like somebody to help fix it. It doesn't seem like you are even using the minted filter here, which is why a reproducible example will help identify where the bug is.

@DanySK
Copy link
Author

DanySK commented Apr 12, 2021

@svenevs could you point me to the instructions to appropriately use the minted filter? At this point, it is possible that I am doing something wrong and this report is actually invalid.

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