Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when deleting a domain with users and/or aliases #30

Closed
kaiyou opened this issue Jul 31, 2016 · 0 comments
Closed

Error when deleting a domain with users and/or aliases #30

kaiyou opened this issue Jul 31, 2016 · 0 comments

Comments

@kaiyou
Copy link
Member

kaiyou commented Jul 31, 2016

When deleting a domain with users and/or aliaes, instead of cascade deletion, the domain i removed and not-null contraints are violated:

sqlalchemy.exc.IntegrityError: (sqlite3.IntegrityError) NOT NULL constraint failed: user.domain_name [SQL: 'UPDATE user SET updated_at=?, domain_name=? WHERE user.email = ?'] [parameters: ('2016-07-31', None, 'xxx@yyy.eu')]

There are two possible fixes:

  • refusing to delete a domain with users or aliases (which would make sense for safety)
  • force cascade deletion (unsafe but straightforward)
@kaiyou kaiyou added the bug label Jul 31, 2016
@kaiyou kaiyou closed this as completed in dcaf3e3 Aug 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant