Closed
Bug 1025228
Opened 11 years ago
Closed 11 years ago
some thimble remixes won't save because of a 500 error
Categories
(Webmaker Graveyard :: Thimble, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: flore, Assigned: jon)
References
()
Details
Attachments
(3 files)
Example of 2 remixes impossible to save (even without making any modification other than remix):
https://thimble.webmaker.org/project/58829/remix
https://thimble.webmaker.org/project/58705/remix
Error generated : Désolé, une erreur s'est produite lors de la publication. {"status":500,"message":"Error: [object Object]"}
However, it is possible to save other makes with the same account and computer. So not a local problem, obviously.
| Reporter | ||
Updated•11 years ago
|
OS: Mac OS X → All
| Assignee | ||
Updated•11 years ago
|
Assignee: nobody → jon
Status: NEW → ASSIGNED
| Assignee | ||
Comment 1•11 years ago
|
||
Attachment #8440116 -
Flags: review?(cade)
| Assignee | ||
Comment 2•11 years ago
|
||
| Assignee | ||
Updated•11 years ago
|
Attachment #8440116 -
Flags: review?(cade)
| Assignee | ||
Comment 3•11 years ago
|
||
| Assignee | ||
Comment 4•11 years ago
|
||
STR:
1) Put Thimble UI into French
2) Save the default project (project a)
3) Remix project a (project b)
4) Attempt to save project b, curse your misfortune as you only get HTTP 500's for your trouble
Analysis:
This is a hilariously obtuse bug. The root cause was having a é (e with accent) character in thimble project a's URL. When you attempt to save the remix, it looks up the original thimble project by URL. The MakeAPI had a bug where it would decide the URL twice, turning '%C3%A9' into 'é' into the unicode not found character (I can't type it in bugzilla, it'll strip my comment). This actually appears to be a bug within the node querystring module, which it has its own decoding method. Since it couldn't find the original thimble project, it left the URL in the `req.body.remixedFrom` variable. When Thimble attempted to publish the remix to the MakeAPI, Thimble would pass the URL as the remixedFrom parameter, which is not valid. You can only pass an ID to remixedFrom. On a side note, this would cause an exception inside the MakeAPI, when it tried to access the email key of undefined.
So, we fixed Thimble to not mix up a remixedFromURL and a remixedFromMakeId, and modified the MakeAPI to not decode URLs twice. Then the make-valet broke because it sent a double-escaped URL to the MakeAPI. So we had to fix that too.
Yay!
Comment 5•11 years ago
|
||
Commit pushed to master at https://github.com/mozilla/thimble.webmaker.org
https://github.com/mozilla/thimble.webmaker.org/commit/ac06a1ab7ffec317721a51a95a82a46723237a41
Bug 1025228 - Don't mix data types in the same variable
Comment 6•11 years ago
|
||
Commit pushed to master at https://github.com/mozilla/MakeAPI
https://github.com/mozilla/MakeAPI/commit/7d50aab5f200aea9a5df679689c319953e548785
Bug 1025228 - Don't decode URLs twice
Comment 7•11 years ago
|
||
Commit pushed to master at https://github.com/mozilla/make-valet
https://github.com/mozilla/make-valet/commit/b8c8745ece49efafeee8597d1b3df34bd329028b
Bug 1025228 - Decode path component of URL
| Assignee | ||
Comment 8•11 years ago
|
||
And we're good on prod.
:flore - Thank you so much for reporting this bug!
| Assignee | ||
Updated•11 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
| Reporter | ||
Comment 9•11 years ago
|
||
Thank you so much :jbuck for having solved this issue so quickly :)
You need to log in
before you can comment on or make changes to this bug.
Description
•