Exception in creating json response under py35
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
oslo.middleware |
Fix Released
|
Undecided
|
Yujun Zhang |
Bug Description
Code for testing, https:/
def test_json_
Exception raised, http://
2017-07-26 14:54:50.922294 | =======
2017-07-26 14:54:50.922316 | FAIL: oslo_middleware
2017-07-26 14:54:50.922325 | tags: worker-1
2017-07-26 14:54:50.922345 | -------
2017-07-26 14:54:50.922358 | Traceback (most recent call last):
2017-07-26 14:54:50.922396 | File "/home/
2017-07-26 14:54:50.922411 | accept=
2017-07-26 14:54:50.923016 | File "/home/
2017-07-26 14:54:50.923054 | server_
2017-07-26 14:54:50.923093 | File "/home/
2017-07-26 14:54:50.923108 | res = req.get_
2017-07-26 14:54:50.923144 | File "/home/
2017-07-26 14:54:50.923159 | application, catch_exc_
2017-07-26 14:54:50.923198 | File "/home/
2017-07-26 14:54:50.923217 | app_iter = application(
2017-07-26 14:54:50.923264 | File "/home/
2017-07-26 14:54:50.923293 | resp = self.call_func(req, *args, **self.kwargs)
2017-07-26 14:54:50.923337 | File "/home/
2017-07-26 14:54:50.923351 | return self.func(req, *args, **kwargs)
2017-07-26 14:54:50.923377 | File "/home/
2017-07-26 14:54:50.923391 | response = self.process_
2017-07-26 14:54:50.923423 | File "/home/
2017-07-26 14:54:50.923435 | return self.func(req, *args, **kw)
2017-07-26 14:54:50.923466 | File "/home/
2017-07-26 14:54:50.923477 | content_
2017-07-26 14:54:50.923510 | File "/home/
2017-07-26 14:54:50.923527 | "You cannot set the body to a text value without a "
2017-07-26 14:54:50.923545 | TypeError: You cannot set the body to a text value without a charset
Changed in oslo.middleware: | |
assignee: | nobody → Yujun Zhang (yujunz) |
status: | New → In Progress |
Reviewed: https:/ /review. openstack. org/487454 /git.openstack. org/cgit/ openstack/ oslo.middleware /commit/ ?id=c3c9891ddd6 0a1e6af61d7ab14 9f2f5b4a74227d
Committed: https:/
Submitter: Jenkins
Branch: master
commit c3c9891ddd60a1e 6af61d7ab149f2f 5b4a74227d
Author: Yujun Zhang <email address hidden>
Date: Wed Jul 26 22:51:23 2017 +0800
Fix exception in json response under py35
charset is required when response with body
Closes-Bug: #1707127 f972954eed5afbc 90389e06c3f
Change-Id: I9921c67866d252