cubicweb/web/views/basecontrollers.py
changeset 12567 26744ad37953
parent 12503 b01dd0ef43aa
child 12912 3966f09d5f5c
--- a/cubicweb/web/views/basecontrollers.py	Fri Apr 05 17:21:14 2019 +0200
+++ b/cubicweb/web/views/basecontrollers.py	Fri Apr 05 17:58:19 2019 +0200
@@ -19,8 +19,7 @@
 object to handle publication.
 """
 
-from six import text_type
-from six.moves import http_client
+import http.client
 
 from cubicweb import (NoSelectableObject, ObjectNotFound, ValidationError,
                       AuthenticationError, UndoTransactionException,
@@ -44,7 +43,7 @@
             raise AuthenticationError()
         else:
             # Cookie authentication
-            self._cw.status_out = http_client.FORBIDDEN
+            self._cw.status_out = http.client.FORBIDDEN
             return self.appli.need_login_content(self._cw)
 
 class LoginControllerForAuthed(Controller):
@@ -187,7 +186,7 @@
     except Exception as ex:
         req.cnx.rollback()
         req.exception('unexpected error while validating form')
-        return (False, text_type(ex), ctrl._edited_entity)
+        return (False, str(ex), ctrl._edited_entity)
     return (False, '???', None)