Errors/Warnings/Bugs

Announcements, comments, ideas, feedback, and "How do I... ?" questions
justusw
Posts: 2
Joined: Fri Jul 03, 2020 3:59 am

Re: Errors/Warnings/Bugs

Post by justusw »

Hi, I am having some trouble using the code blocks in J.
I just posted my answer to Thread 37 on projecteuler.net and the syntax highlighting appears to choke up upon seeing the "NB." token. Did I create the code block correctly? I assumed it's [code=J] +/ i. 123 [/code]

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

The syntax highlighting on the main website relies on the superb highlight.js to do it's magic. I've just updated the version and it does appear to have solved your problem. It is possible that this change will have a slight impact on the "cosmetics" with some other languages, but I hope none of those changes are harmful to the display of the code.
Image
impudens simia et macrologus profundus fabulae

justusw
Posts: 2
Joined: Fri Jul 03, 2020 3:59 am

Re: Errors/Warnings/Bugs

Post by justusw »

Thank you for looking into this. I can confirm that the syntax highlighting has improved. :D

philiplu
Posts: 31
Joined: Wed Aug 02, 2017 8:51 pm
Location: Redmond, WA, USA

Re: Errors/Warnings/Bugs

Post by philiplu »

Something seems to have changed in the past couple weeks (maybe the syntax highlighting mentioned above?), but I'm seeing really long delays before a forum post has its final format. For instance, take a look at my post at the end of problem #723's forum. When I hit refresh, the MathJax mostly renders in about 6 seconds, but it's not finished. Text sizes are smaller than expected, the font is too light, and some more complicated multiline formulas (using \$\$...\$\$?) are all run together on one line.

The text then stays like that for over 2 minutes, with no sign of anything changing, even though a program monitor shows chrome.exe is very busy (one thread pegged). Finally, at 2m20s after hitting refresh, the final text format renders as expected.

This is with the latest Chrome browser running on Windows 10 (version 1909, not 2004, if that matters).

Any idea what's up?
Image

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

If you look collectively at all of the posts in that thread you will see that almost everyone has written exceptionally good posts. They include a lot of detail and a significant amount of mathematical notation. So rendering is going to take a bit of time. After the page has finished rendering and everything has settled, which takes about 5-6 seconds, I am not noticing anything unusual. I can scroll through the entire thread and everything appears to be displaying as expected; one of the formulae extends slightly beyond the post window.

At the time of posting this, I tested that thread in the latest versions of Firefox (78.0.2) and Chrome (83.0.4103.116).

As we rely on a CDN for MathJax it is possible that they were having a temporary issue when you were testing. But let's keep an eye on the situation.
Image
impudens simia et macrologus profundus fabulae

philiplu
Posts: 31
Joined: Wed Aug 02, 2017 8:51 pm
Location: Redmond, WA, USA

Re: Errors/Warnings/Bugs

Post by philiplu »

Thanks for the reply. The 6 second delay to render isn't surprising, but that 2+ minutes of inactivity is. I'm running the same versions of Firefox and Chrome as you. Just checked Firefox, and everything renders in about 8 seconds. But I'm currently running about 80 tabs open in Chrome (a big improvement over the 200 open tabs I had until a big purge a month or so ago :shock: ). I restarted Chrome with only PE open, and, yep, render time is about 7 seconds. So this is some interaction with either the plethora of tabs I've got open, or some other specific tab causing trouble. I'll see if I can figure out anything actionable, but it looks like this is some local problem on my side.
Image

shs.10978
Posts: 1
Joined: Sun Mar 03, 2019 9:33 pm

Re: Errors/Warnings/Bugs

Post by shs.10978 »

Hi, I am having trouble opening the thread for Problem 497. Chrome would load a few posts but when I scrolled down further, it became just a blank screen. Maths formulas were not rendered and code sections would not open.

User avatar
RobertStanforth
Administrator
Posts: 1360
Joined: Mon Dec 30, 2013 11:25 pm

Re: Errors/Warnings/Bugs

Post by RobertStanforth »

shs.10978 wrote:
Fri Jul 24, 2020 6:05 am
Hi, I am having trouble opening the thread for Problem 497. Chrome would load a few posts but when I scrolled down further, it became just a blank screen. Maths formulas were not rendered and code sections would not open.
Thank you for reporting this. I cannot load the thread either: the Chrome tab hangs.

User avatar
jaap
Posts: 552
Joined: Tue Mar 25, 2008 3:57 pm
Contact:

Re: Errors/Warnings/Bugs

Post by jaap »

RobertStanforth wrote:
Fri Jul 24, 2020 8:26 am
shs.10978 wrote:
Fri Jul 24, 2020 6:05 am
Hi, I am having trouble opening the thread for Problem 497. Chrome would load a few posts but when I scrolled down further, it became just a blank screen. Maths formulas were not rendered and code sections would not open.
Thank you for reporting this. I cannot load the thread either: the Chrome tab hangs.
I use Firefox and it gives a pop up message that the page is slowing down the browser (presumably because of MathJax), but if you let it continue it finishes loading and rendering the page, and it looks normal.

User avatar
hk
Administrator
Posts: 10942
Joined: Sun Mar 26, 2006 10:34 am
Location: Haren, Netherlands

Re: Errors/Warnings/Bugs

Post by hk »

Same problem here. (both on Chrome and Edge)
Other pages using Mathjax load perfectly. Even the second page of the forum for Problem 497 (View Problem) loads without delay.
The page hangs in the middle of the post by nhmllr.
Error code: RESULT_CODE_HUNG
Image

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

Thank you for reporting it, shs.10978. And thank you to everyone else for confirming the issue.

The problem was caused by two posts where the members had included the complete answer, which contained over 20000 digits in a code block. The syntax highlighter was having a terrible time trying to autodetect the language! :lol:

It would have made more sense to use the "collapse" tag, but I've modified the script that parses code tags to automatically convert it to a collapse tag when it displays on the page if it detects a long string of characters. This does mean that some genuine programs that contain very few spaces might now get caught by this, so we'll have to keep an eye on things. But it does mean that the page now loads properly.
Image
impudens simia et macrologus profundus fabulae

Ignis_Necrosy
Posts: 4
Joined: Tue Aug 04, 2020 1:09 pm

Re: Errors/Warnings/Bugs

Post by Ignis_Necrosy »

"The requested statistics page is currently unavailable" with Levels and Languages

For example, showing active members only, stats for level 5 have 7 pages. Then switch to all registered members, the stats now contain 27 pages. However, the cache doesn't seem to be updating correctly, and trying to visit page 8 to 27 produces this error.

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

Thanks for reporting that error, Ignis_Necrosy. The levels summary page was not making a distinction between all and active members. There are only 629 active members at level 5, so there should only be 7 pages. I've fixed it so that the member count should be correct now.

What were you doing to get the error, "The requested statistics page is currently unavailable"?
Image
impudens simia et macrologus profundus fabulae

Ignis_Necrosy
Posts: 4
Joined: Tue Aug 04, 2020 1:09 pm

Re: Errors/Warnings/Bugs

Post by Ignis_Necrosy »

Thank you for looking into this. Though I probably didn't state the problem very clearly... I visited the statistics page for level 5, switched from active members to all members, then returned to that page. The member count was correct, and everything else on the page looked fine – just those hyperlinks for page 8 to 27 wouldn't actually work, they led me to this error. Maybe something caused these data to be truncated in the cache.

Correct a thing from my last post:
"The requested statistics page is currently unavailable" with Levels and Languages
As I retest it now, all statistics pages (Locations, Languages, Levels, Awards) are prone to this error.

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

Thanks for persisting with it. I figured out the issue and it should all be working again now. Rather than delete all the cached data, I'll let everything update naturally, but in the meantime I've fixed level 5 right now.

For some reason I wasn't modifying the cache identifiers for the purge list with whether or not it was for all members or active members only. So when it rebuilt the cache for level 5 active members it had determined that there were 7 pages and then set about checking for the existence of any cached data beyond this. However, because the cache identifier wasn't being set correctly, it found and removed the cached data for pages 8 to 29 from the all members cache.
Image
impudens simia et macrologus profundus fabulae

Ignis_Necrosy
Posts: 4
Joined: Tue Aug 04, 2020 1:09 pm

Re: Errors/Warnings/Bugs

Post by Ignis_Necrosy »

Yes, it works now.

I happen to have noticed another bug: https://projecteuler.net/awards always displays member counts for all registered members even with "show active members only".

User avatar
euler
Administrator
Posts: 3375
Joined: Sun Mar 05, 2006 4:49 pm
Location: Cheshire, England
Contact:

Re: Errors/Warnings/Bugs

Post by euler »

This is all very helpful. Thank you.

It was the same issue you mentioned with the "levels" summary page. I have now double checked all of the other scripts and awards was the only other one. They should all be working as expected now.
Image
impudens simia et macrologus profundus fabulae

Ignis_Necrosy
Posts: 4
Joined: Tue Aug 04, 2020 1:09 pm

Re: Errors/Warnings/Bugs

Post by Ignis_Necrosy »

Thank you for the fixes. :D

Post Reply