Open response assignment (ORA) upload file "Could not retrieve upload url"

As I can see in above error json.dump() fails to create JSON from object passed in /edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/xblock/mixins.py

Mr. @omar even highlighted something similar here : Translate the default XBlock data - #3 by omar

Will it be right to use following code inside xblock/mixins.py

from rest_framework.utils.encoders import JSONEncoder
value = json.dumps(..., cls=JSONEncoder)

For file “/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/xblock/mixins.py”, line 74, in wrapper

return Response(json.dumps(response), content_type=‘application/json’, charset=‘utf8’)