Closed terracoda closed 1 week ago
I just reproduced the problem with the tactiles project. It is another case of the payload being too large, we are getting this response back from the server: "413 (Payload Too Large)"
So it seems we cannot save the entire project all at once. This one is going to be tricker than #188 because the projects table only has one entry for the project data - a JSON object for the entire thing. We will probably have to change the table or edit the saved JSON without reloading the whole thing.
The above commit is working well, its in a feature branch chunk-saves
. Before merging into main I want to
Look for other places where this payload error can happen.
Inspecting the api, here is where this can happen again potentially:
Could also happen if the user tries to upload massive image/audio files.
The size limits are way bigger for receiving data from the server. Since our entire db is less than 1mb, we don't have to worry about this when loading data from the db.
In summary, one of these is from the original paper programs code and the rest are not likely enough to hit to prioritize right now (IMO). However this may be something @brettfiedler wants to track for project management. I think this is most likely to happen again for massive programs (where a single program has >200 components or tons of custom code).
Lots of testing of save/load for existing projects.
I tested by
This was merged into main. I did some spot checking on main and it is OK.
@brettfiedler can you please review https://github.com/phetsims/paper-land/issues/202#issuecomment-1814735146 and let me know if there is anything else you would like to do here? For example, place a limit on the number of components a single program can have or something like that? Or spend more time chunking up the data within each program?
Opened a new issue in #250 to track future occurences.
Copied Programs not Saving I copied my X and X squared programs Tuesday around 4 pm CT, and then when I loaded PP the next morning they were not there. I assumed I had missed a step or had done something wrong. I copied them all again, and just noticed my copies did not stick. The database looks the same as it did this morning.
To Reproduce Steps to reproduce the behavior:
I just happened to have taken a screenshot this afternoon while making copies. You can see I have copies of X Tiles:
I don't have those or the rest of my copies anymore.