madjar / nox

Tools to make nix nicer to use
MIT License
311 stars 35 forks source link

Improvement request: Be more helpful when "_gdbm.error: Malformed database file header" occurs in nox-review #90

Open das-g opened 6 years ago

das-g commented 6 years ago

Recently I used nox-review again after a longer time (and after having switched from NixOS 18.03 to NixOS 18.09) just to be greeted by a Python stacktrace and the error message

_gdbm.error: Malformed database file header

(Reported as NixOS/nixpkgs#48878)

The solution was to delete /tmp/nox.dbm.${USER}, however as a mere nox enduser lacking knowledge about nox' inner workings I wouldn't have found out that without the helpful comment by @symphorien (Thanks!).

Maybe if that error occurs, nox itself could attempt to invalidate/clear/remove that cache? Or, if that's problematic, at least output some hint that the user may try that? (And if known, with the criteria on when to do that and when not to.)