Name the path and the real failure when SQLite cannot use a database file
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 50/100
Research direction
Start in dbkit/sqlite where the database path is opened and checked, and in the Classify function the issue names as the place to map SQLite failures to messages. Reproduce the four cases in the table (folder, non-database file, read-only file, file in a read-only folder) and see which prefix each one currently gets. Done means each case returns an error that names the path and states the cause, and the "read the database path" prefix appears only for read failures. The payload names no test file.
Written by the indexing model from the issue text.
Description
What
When a SQLite address names something SQLite cannot use, dbkit/sqlite v0.1.0 lets the handle open and the first statement fails with an unclear error. Measured with Gophenberg, which opens through dbkit/sqlite:
| The path names | First statement fails with |
|---|---|
| a folder | dbkit: read the database path: unable to open database file (14) |
| a file that is not a database | dbkit: read the database path: file is not a database (26) |
| a read-only file | dbkit: read the database path: attempt to write a readonly database (8) |
| a file in a read-only folder | dbkit: read the database path: ... (1544) |
Two things are off:
- The prefix says "read the database path" even when SQLite failed a write.
- No message names the path, so the operator cannot tell which file is wrong.
Why
An operator who points a site at the wrong file should learn which file and what is wrong with it, for example "is a folder, not a database file" or "is read only". Classify and the open-time file check in dbkit/sqlite are the natural place, so every product on dbkit gets the same answers.
- Dominant language
- Go
- Stars
- 69
- Forks
- 3
- Avg merge
- 9h 11m
- Merged PRs (30d)
- 38
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from gopherium/framework
-
bug help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
enhancement help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
enhancement help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
enhancement help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Stop a SQLite commit that waits for a lock once its transaction's context endsPossibly taken @SirLouen claimed this 1 day ago. Openbug
Difficulty 4/5 3-5 days Newbie friendliness 48/100
gopherium/framework#104 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
All issues in gopherium/framework
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
FiloSottile/age#758 ·
-
nginx configOpen
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 63/100
Maintainers usually reply within 1 day