diderot-edu / diderot-feedback

0 stars 0 forks source link

Diderot compiler eats non-comment LaTeX lines beginning with % #112

Closed solb closed 3 years ago

solb commented 3 years ago

This appears to be a regression in dc. We (15-122) have project writeups that format Unix commands like so:

\begin{lstlisting}[language={[coin]C}]
% autolab122 feedback
\end{lstlisting}

This used to output lines like this:

<div class="sourceCode" id="cb2"><pre class="sourceCode coinC coinC"><code class="sourceCode coinc"><span id="cb2-1"><a href="#cb2-1" aria-hidden="true"></a><span class="ot">% autolab122 feedback  </span></span></code></pre></div>

But as of the version published in commit f4b8a73 of the diderot-guide repo, it produces this instead:

<div class="sourceCode" id="cb2"><pre class="sourceCode coinC coinC"><code class="sourceCode coinc"></code></pre></div>

Because dc doesn't appear to have a --version option or similar, I'm unable to provide a last known good version.

umutacar commented 3 years ago

this looks like a pandoc bug. i wonder when it was introduced. what version of pandoc are you using?

umutacar commented 3 years ago

confirmed. i have tried with an older version of pandoc 2.7 and it behaves as expected. the bug reproduces with 2.9 which is the oldest version that ApplePolice would allow me install. you can find older releases of pandoc here: https://github.com/jgm/pandoc/releases

probably best to report this bug to pandoc

solb commented 3 years ago

Indeed, downgrading Pandoc from 2.9.2.1 to 2.8.1 fixes the issue for me. Thanks Umut!