Last modified: 2014-05-29 14:24:27 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T66893, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 64893 - Cannot upload utf-8 characters via "Paste Usernames" input box
Cannot upload utf-8 characters via "Paste Usernames" input box
Status: RESOLVED FIXED
Product: Analytics
Classification: Unclassified
Wikimetrics (Other open bugs)
unspecified
All All
: High normal
: ---
Assigned To: Nobody - You can work on this!
: utf8
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-05-05 13:27 UTC by Sage Ross
Modified: 2014-05-29 14:24 UTC (History)
5 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Sage Ross 2014-05-05 13:27:45 UTC
If usernames pasted into the Paste Usernames box include any utf-8 characters, they cannot be uploaded. The error message is: "Error! Server error while processing your upload"


Here are some example usernames that cannot be uploaded via Paste Usernames:

محمد الفلسطيني
אצטרובל
José Puigjaner
Comment 1 Dan Andreescu 2014-05-06 16:52:39 UTC
Thanks Sage.  We're all in Zurich until the 12th but we'll try to fix this soon.  Here's the familiar dreaded stack trace that confirms the problem (collected while pasting the usernames in your bug description):

[Tue May 06 16:50:15 2014] [error] 'ascii' codec can't encode characters in position 0-3: ordinal not in range(128)
[Tue May 06 16:50:15 2014] [error] Traceback (most recent call last):
[Tue May 06 16:50:15 2014] [error]   File "/srv/wikimetrics/wikimetrics/controllers/cohorts.py", line 178, in cohort_upload
[Tue May 06 16:50:15 2014] [error]     form.parse_records()
[Tue May 06 16:50:15 2014] [error]   File "/srv/wikimetrics/wikimetrics/controllers/forms/cohort_upload.py", line 51, in parse_records
[Tue May 06 16:50:15 2014] [error]     self.records = parse_records(unparsed, self.project.data)
[Tue May 06 16:50:15 2014] [error]   File "/srv/wikimetrics/wikimetrics/controllers/forms/cohort_upload.py", line 83, in parse_records
[Tue May 06 16:50:15 2014] [error]     'username'  : parse_username(username),
[Tue May 06 16:50:15 2014] [error]   File "/srv/wikimetrics/wikimetrics/utils.py", line 231, in parse_username
[Tue May 06 16:50:15 2014] [error]     username = str(username)
[Tue May 06 16:50:15 2014] [error] UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-3: ordinal not in range(128)
Comment 2 Sage Ross 2014-05-06 17:00:31 UTC
Thanks Dan. This is not an urgent bug for me or other education program folks, because we mainly use the text file method for uploading cohorts. I just happened across it while working on an API to make it easier to pull lists of students out of the Education Program extension.
Comment 3 Gerrit Notification Bot 2014-05-20 17:48:37 UTC
Change 134397 had a related patch set uploaded by Nuria:
Can upload names with utf-8 characters via "Paste Usernames" textbox

https://gerrit.wikimedia.org/r/134397
Comment 4 Gerrit Notification Bot 2014-05-24 03:30:55 UTC
Change 134397 merged by Milimetric:
Can upload names with utf-8 characters via "Paste Usernames" textbox

https://gerrit.wikimedia.org/r/134397
Comment 5 nuria 2014-05-29 14:24:27 UTC
Fix deployed to Prod 5/29

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links