Skip to content
Snippets Groups Projects
Verified Commit 240a8a9e authored by Timm Fitschen's avatar Timm Fitschen
Browse files

Merge branch 'dev' into f-encode

parents 84427f52 1d45e27d
No related branches found
No related tags found
1 merge request!55FIX: new systems expect encoded body
Pipeline #25297 passed
......@@ -22,6 +22,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
password method.
- `read()` of MockupResponse returns now an appropriate type on modern systems
* [caosdb-server#142](https://gitlab.com/caosdb/caosdb-server/-/issues/142)
Can't create users with dots in their user names
### Security ###
### Documentation ###
......
......@@ -196,17 +196,9 @@ def _update_user(name, realm=None, password=None, status=None,
e.msg = "You are not permitted to update this user."
raise e
except HTTPClientError as e:
if e.status == 409:
e.msg = "Entity does not exist."
if e.status == 422:
e.msg = """Maybe the password does not match the required standard?
The current requirements are:
- at least 8 characters
- at least 1 number
- at least 1 lower case character
- at least 1 upper case character
- at least 1 special character"""
for elem in etree.fromstring(e.body):
if elem.tag == "Error":
e.msg = elem.get("description")
raise
......@@ -231,17 +223,9 @@ def _insert_user(name, password=None, status=None, email=None, entity=None, **kw
e.msg = "You are not permitted to insert a new user."
raise e
except HTTPClientError as e:
if e.status == 409:
e.msg = "User name is already in use."
if e.status == 422:
e.msg = """Maybe the password does not match the required standard?
The current requirements are:
- at least 8 characters
- at least 1 number
- at least 1 lower case character
- at least 1 upper case character
- at least 1 special character"""
for elem in etree.fromstring(e.body):
if elem.tag == "Error":
e.msg = elem.get("description")
raise e
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment