SeaQL / SeaQL/sea-orm

Remove panic on DatabaseConnection::Disconnected

Open
#2,483 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Category:enhancement
Dominant language
Rust
Stars
9.9k
Forks
734
Avg merge
6h 36m
Merged PRs (30d)
8

Description

If our DB disconnects right now the code panics. Can we handle this safely?

src/database/db_connection.rs:119:49:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect src/database/db_connection.rs at line 119:49, starting from the DatabaseConnection::Disconnected path and the panic it currently causes. Determine the safe behavior for a database disconnect, then verify that the connection no longer panics and add or update coverage for this case.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
database
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.