atuinsh / atuin

✨ Magical shell history
https://atuin.sh
MIT License
20.31k stars 549 forks source link

[Bug]: "Error: error returned from database: (code: 4847) disk I/O error" if no space left on device #2334

Closed DoubleTheP closed 1 month ago

DoubleTheP commented 1 month ago

What did you expect to happen?

Atuin briefly informs that writing to the database is not possible due to no space left on disc

What happened?

If no space left on the disc, the next output is

Error: error returned from database: (code: 4874) disk I/O error                                                                                                                                              

Caused by:
    (code: 4874) disk I/O error

Location:
    crates/atuin/src/command/client.rs:126:18

And any other key press emits this error. No atuin-history, or atuin functionality is any longer available. Still, the terminal is still working (accepts and computes inputs), just gets polluted with every keystroke.

Atuin doctor output

no "atuin doctor" output available - used version 18.3.0

Code of Conduct

DoubleTheP commented 1 month ago

UPDATE: Providing again enough disk space makes the error message disappear.

ellie commented 1 month ago

This is expected behaviour. We have no way to function correctly if there is no space left on the disk, and have only two options - fail silently, or fail with an error.

In this case I think the error makes sense. No disk is a pretty severe condition for a system to be in, and resolving it immediately is the highest priority.

ellie commented 1 month ago

See #1886