#1: MrsThing (mrsthing2) on Nov 13, 2013
HELP!!!! I cannot save gigantic puzzle #13230. It tells me it is saving, but never finishes. I've typed in 'S', clicked Save, re-sized it smaller and bigger to try to regain control of the board. I've blanked out a pixel and re-entered it. This tries to auto-save, but does not finish. Nothing helps. I don't want to log out and back in for fear of losing my work. Any ideas?#2: Jan Wolter (jan) on Nov 15, 2013
Hmmm...I'll have to look at this. I don't usually do giant puzzles. It's conceivable that there are some kind of browser limits your are running up against.#3: MrsThing (mrsthing2) on Nov 15, 2013
Hmmm...I scribbled it full of stuff and could still save it. No way I'm solving that. I'm using firefox. What browser are you using?
If you've finished the puzzle, you can just mark it as solved from the puzzle list page - hover the mouse to get the menu, select the "Rate Puzzle" option, and select "Mark as Complete". This actually does almost exactly the same thing in the database as saving a completed puzzle - well, except it doesn't save your undo history.
I'm a bit busy right now, but I'll try to find time to look at this. I think, however, that I am unlikely to be able to do anything that will allow you to solve your puzzle. Any change I make to the software would require you to reload the page to get the new software, which would lose your solution.
Jan, you are so thoughtful. How lucky we are to have a web-master as responsive as you. Even though you are busy, you still take time to interact with your fans. Thank you.#4: MrsThing (mrsthing2) on Nov 15, 2013
Thanks for the "Mark as Complete" workaround. I'll gladly do that.
I, too, use Firefox, on a MacBook Pro.
As I looked into this further, I opened my last saved version of this puzzle in a new tab. I discovered that the bottom 60% or so of the puzzle was blank. I have seen this intermittently with large puzzles. (Don't you love 'intermittent' problems!) In those cases I have been able to reconstruct the complete puzzle and save it. I don't remember if I had to do it several times for it to take.
I reverted to this broken puzzle and, using my completed solution as a template, I was able to complete the broken one a lot faster than re-solving it. I did save every couple of lines though, and successfully saved my solution.
On a probably unrelated topic, if I start a puzzle in SVG mode, save a partial solution, then switch to HTML mode, could this cause a problem?
(Btw, this puzzle has some long strings of single colors. It is easier than it looks at first.)
Thanks again. We all appreciate you, Jan!
OOPS! I thought I finally successfully saved it, but although the 'saving' completed, it was still truncated. But I am happy. When I recalled the saved solution, though truncated, it still congratulated me for my successful solution. :-)#5: Joe (infrapinklizzard) on Nov 16, 2013
I find that interesting. I know that Jan has said in the past that a complete picture is saved with completed puzzles. So, unless a "finished" flag is also saved, this implies that it is a rendering error rather than a save error.#6: Jan Wolter (jan) on Nov 20, 2013
That is interesting. It's been a while since I looked at the code, but I think the flow is like this:#7: Jan Wolter (jan) on Nov 20, 2013
SAVE:
(1) The Javascript program on your computer encodes the current puzzle state into a string.
(2) The Javascript sends the current puzzle state to the server in an HTTP request.
(3) A Perl program on the server decodes the puzzle, loads the goal solution from the MySQL database, and compares the two to see if you have completed the puzzle.
(4) If the puzzle is complete, it sets a flag in the MySQL database saying the puzzle is complete, but does not save your puzzle image (this is to save disk space - we don't need to save thousands of copies of the completed puzzle). If the puzzle is not complete, it saves your partial solution.
(5) The perl program then sends a response back to the Javascript, telling it, among other things, whether the puzzle was solved correctly.
(6) The Javascript displays the "Yahoo" message if the puzzle was complete.
So Joe's right. The puzzle might have been truncated during the encoding, HTTP transmission, or decoding stage, but then you wouldn't get a "Yahoo" message. It might have been truncated when saving to MySQL, but a completed puzzle isn't saved to MySQL. So it seems likely that the problem didn't happen during the save at all.
I need to study this further.
Interesting. As theorized, the puzzle is in fact saved correctly, which is to say, not saved at all. There is just a flag saying it is complete. So the save actually seems to be working right.#8: Jan Wolter (jan) on Nov 20, 2013
On the load, the browser does receive the complete 99x99 grid from the server. It just doesn't put it all up on the screen. It just draws the first 4056 pixels. Hmmm. I'd be happier if it was the first 4096 pixels, because then it would be a power of 2 and computer programmers like setting limits to powers of 2. Wait - that's 40 complete rows, and one incomplete row, and each complete row is terminated by a newline character, so that's 40 more characters, which makes 4096. Yippee! Doesn't answer anything but a limit of 4096 is much more plausible. Something is refusing to look at more than the first 4K of the puzzle.
I wonder what?
Well it kind of has to be the XML response parser built into Firefox, a thing called "responseXML".
So I google "responseXML 4096" and find a mozilla bug report: https://bugzilla.mozilla.org/show_bug.cgi?id=194231
It seems that if a field in an XML file was longer than 4096 characters, Firefox breaks it into 4096 character chunks, in violation of the standards. The Firefox people admitted this was a bug in 2003, partially fixed it in 2011 and then realized that they had only fixed half of it. The other half is still unfixed. In case anyone is wondering why Chrome is overtaking Firefox in the browser market, this kind of thing probably has something to do with it. Mozilla is glacial.
However, now that I understand the bug, I should be able to work around it.
OK, I think this bug is fixed. Should solve a lot of problems with loading big puzzles.#9: Joe (infrapinklizzard) on Nov 20, 2013
Thanks MrsThing2 and Joe.
"Yahoo! You solved it!"#10: MrsThing (mrsthing2) on Nov 21, 2013
Excellent! Thanks for giving me a little insight into the magic.
Btw, I did use the "Mark as Complete" workaround before I reconstructed the bottom half of the already completed puzzle. Maybe that triggered the Yahoo msg.
May be time for me to move to Chrome ...
Thanks to both of you. This has been fun.
You must register and log in to be able to participate in this discussion.