Odd inline mode MathJax rendering problem in the MathJax basic tutorial

I'm seeing something odd with the inline MathJax rendering on the MathJax basic tutorial.

There are 15 items in a numbered list in the tutorial. For items 1 to 5 (and also the first part of item 6) the inline mode MathJax rendering does not work. I tried Safari, Firefox and Chrome on macOS Mojave.

From somewhere in item 6 downward, the inline mode MathJax rendering works fine. Display mode rendering works fine throughout the tutorial.

See this screenshots with visual hints for clarification:

Can someone confirm this or is it just me? Does someone have a clue what's going on?

• Reproduced on Chrome 71, Windows 10: the post failed to render the inline MathJax, but they are rendered correctly when on the edit mode's preview. According to the Developer Console, there are 49 events about [Violation] 'setTimeout' handler took <N>ms related to MathJax.js. – Andrew T. Jan 13 '19 at 16:43
• A similar issue for me with MathJax in the Sandbox not displaying correctly on my phone was solved by going away for a quarter of an hour to give it time to plough through it all. I've never seen the rendered version of most MathJax in the tutorial. – timtfj Jan 13 '19 at 17:27
• Reproduced with Safari on macOS. – Martin R Jan 14 '19 at 10:24
• I heard from the folks at SE that this problem should now be fixed. – Davide Cervone Jan 31 '19 at 19:38

Sorry about that, that's my bad. The markup Davide Cervone is referring to is what tells our diff engine to treat formulas as atomic units and allows us to present rendered formulas in the post revision history. We insert it into the post's HTML before saving a revision.

Unfortunately, there was a bug with the parser in posts that had code blocks that also included MathJax. The bug has been fixed and I rebaked the tutorial post to correct its stored markup.

If any other posts are affected, they can be fixed by editing. Or alternatively, drop a link in the comments on this answer and I'll fix them up.

When I view the DOM for the page, I see

which shows that the closing dollar sign is inside an element <span class="math-container">. MathJax only processes math when the entire math expression (including its delimiters) are in the same text run, so that extra <span> is causing MathJax to not recognize the expression. That is why you are not seeing typeset math.

These spans are not in the original text, and don't show up in the editing preview, so I assume they are something inserted when the post/answer is pre-processed on the server after it is edited and is being put in its final form. It looks like someone has been trying to insert containers for the math, but has gotten the delimiter balancing wrong. It is not part of MathJax.

It may be that StackExchange has rolled out a new version of its software, and that it is a new bug introduced by that.