Skip to content

Create a PGCritic file to check for \begin{align*} or \begin{align} - #1574

Open
pstaabp wants to merge 3 commits into
openwebwork:developfrom
pstaabp:pgcritic-align
Open

pstaabp wants to merge 3 commits into
openwebwork:developfrom
pstaabp:pgcritic-align

Conversation

@pstaabp

@pstaabp pstaabp commented Nov 7, 2026

Copy link
Copy Markdown
Member

Cleaning up problems in the OPL, there are a number of places that \begin{align*} \end{align*} are used inside of latex blocks. Often in SOLUTION blocks.

These typically render okay in the browser with MathJax, but will produce errors when making a hardcopy.

This creates a pg-critic file to flag this.

which shouldn't be used in a latex block.  Use will produce an error
in hardcopy.
@somiaj

somiaj commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

Note, these will also fail now if wrapped inside another environment, such as displaymode, [``\begin{align*}...\end{align*}``]. I had a lot of broken problems because MathJax 4.x will only allow align* to be a top level environment (while 3.2 didn't have this restriction), and nesting it in display mode or anything will cause MathJax to fail to render it.

@drgrice1 drgrice1 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This generally looks fine. Just a few minor details to fix.

This branch has not been deployed

No deployments
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

Successfully merging this pull request may close these issues.

3 participants