openedx / openedx/edx-ora2

Export non ascii answers

Open
#934 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
65
Forks
218
PR merge metrics
No merged PRs in 30d

Description

submission['answer'] from here
https://github.com/edx/edx-ora2/blob/master/openassessment/data.py#L472
is a dictionary.

While processing we have a problem with non ascii answers

ащпцацушщпауц азцуатцощаз 48236492604^&%^&%&&*(%&(*%&^&GYgyuoge7r786342141!±!@#$%^&*(((**&&*L>?>">"> <>?>?<>./.';;[;[[]\''.'';l';l.'p['

In the csv file it looks like:

{u'parts': [{u'text': u'\u0430\u0449\u043f\u0446\u0430\u0446\u0443\u0448\u0449\u043f\u0430\u0443\u0446 \n\u0430\u0437\u0446\u0443\u0430\u0442\u0446\u043e\u0449\u0430\u0437\n48236492604^&%^&%&&*(%&(*%&^&GYgyuoge7r786342141!\xb1!@#$%^&*(((**&&*L>?>">">\n<>?>?<>./.\';;[;[[]\\\'\'.\'\';l\';l.\'p[\''}]}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at openassessment/data.py line 472 and trace how submission['answer'] is serialized into the CSV export. Reproduce the export with the non-ASCII answer shown in the issue, then verify that the CSV preserves readable Unicode text rather than a Python dictionary representation with escaped characters.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend, data
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.