Page MenuHomePhabricator

Improve warning for \ca macro when used outside of chem tag
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

  • \ca is a whitelisted command in chemistry mode

What happens?:

The following error is shown
Failed to parse (Conversion error. Server ("https://wikimedia.org/api/rest_") reported: "Cannot get mml. TeX parse error: Undefined control sequence \ca"): {\displaystyle {\ce {\ca{x}}}}

https://www.mediawiki.org/w/index.php?title=User:Physikerwelt/sandbox/ca&oldid=5625515

What should have happened instead?:

It should show an error message that the command ca is not supported

Software version (skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

The macro is actually used and there are tests for it.

Physikerwelt renamed this task from Remove \ca macro from texvc to Improve warning for \ca macro when used outside of chem tag.Feb 8 2026, 4:37 PM

Screenshot 2026-02-08 at 17.38.13.png (334×350 px, 19 KB)

Change #1237696 had a related patch set uploaded (by Physikerwelt; author: Physikerwelt):

[mediawiki/extensions/Math@master] Improve the error message for \ca macro if used outside chem context

https://gerrit.wikimedia.org/r/1237696

Physikerwelt triaged this task as Low priority.
Physikerwelt moved this task from Inbox to Code Review on the Math board.

Change #1237696 merged by jenkins-bot:

[mediawiki/extensions/Math@master] Improve the error message for \ca macro if used outside chem context

https://gerrit.wikimedia.org/r/1237696