Closed
Bug 910855
Opened 11 years ago
Closed 11 years ago
Searches containing non-english characters are causing the MakeAPI to 500
Categories
(Webmaker Graveyard :: Login, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: cade, Assigned: jon)
Details
Attachments
(1 file)
Sample URL: https://makeapi.webmaker.org/api/20130724/make/search?or=1&description=%D8%A7%D9%84%D9%81%D9%8A%D8%B3%20%D8%A8%D9%83&user=%D8%A7%D9%84%D9%81%D9%8A%D8%B3%20%D8%A8%D9%83&title=%D8%A7%D9%84%D9%81%D9%8A%D8%B3%20%D8%A8%D9%83&tags=and%2C%D8%A7%D9%84%D9%81%D9%8A%D8%B3%20%D8%A8%D9%83&limit=12&sortByField=createdAt%2Cdesc&page=1
I'm not sure how to fix this in Elastic Search. Will have to investigate.
Reporter | ||
Comment 1•11 years ago
|
||
I'm seeing this error:
{
"error": {
"code": "ER_CANT_AGGREGATE_",
"index": 0
},
"code": 500
}
research time!
Reporter | ||
Comment 2•11 years ago
|
||
Traced this to the login server:
"GET /user/الفيس%20بك HTTP/1.1" 500 69 "-" "-"
Component: MakeAPI → Login
Reporter | ||
Comment 3•11 years ago
|
||
possible solution:
`Sequelize.STRING + ' CHARSET utf8 COLLATE utf8_unicode_ci'`
to the "username" column. This would require a migration script.
Other than that, make an effort to not pass these kinds of strings into that system.
Assignee | ||
Comment 4•11 years ago
|
||
Waitwaitwait. You're saying that the login server doesn't support utf8? Lets fix that up!
Assignee: cade → jon
Assignee | ||
Comment 5•11 years ago
|
||
Nice catch Chris, I've changed the login db on prod and staging to be utf8: https://webmaker.org/en-US/search?type=title&q=%D8%A7%D9%84%D9%81%D9%8A%D8%B3+%D8%A8%D9%83
Patch incoming to make sure that this doesn't happen on local dev too
Assignee | ||
Comment 6•11 years ago
|
||
Attachment #797858 -
Flags: review?(cade)
Reporter | ||
Comment 7•11 years ago
|
||
Comment on attachment 797858 [details] [review]
https://github.com/mozilla/login.webmaker.org/pull/149
Thanks for getting on this one! R+
Attachment #797858 -
Flags: review?(cade) → review+
Comment 8•11 years ago
|
||
Commit pushed to master at https://github.com/mozilla/login.webmaker.org
https://github.com/mozilla/login.webmaker.org/commit/aa1d408feaf03d7aa8a4607004fba26f6ad6bbbe
Fix bug 910855 - Force utf8 on table creation
Updated•11 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Updated•11 years ago
|
Attachment mime type: text/plain → text/x-github-pull-request
You need to log in
before you can comment on or make changes to this bug.
Description
•