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

SqlAlchemy mysql connections drop and crash the session #17

Open
henryhbk opened this issue Sep 21, 2021 · 1 comment
Open

SqlAlchemy mysql connections drop and crash the session #17

henryhbk opened this issue Sep 21, 2021 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@henryhbk
Copy link
Contributor

The classic "the MySQL server has gone away" error. This is due to Flask timing out an idle connection pool in the sqlalchemy engine and is fixed by either the pessimistic or optimistic strategies specified in the engine docs:

@henryhbk henryhbk added the bug Something isn't working label Sep 21, 2021
@henryhbk henryhbk self-assigned this Sep 21, 2021
@henryhbk
Copy link
Contributor Author

Fixed with commit #90978fd adding pool_pre_ping=True per SqlAclhemy docs (Pessimistic strategy)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant