Record the maintenance-script .env fix in the changelog
This commit is contained in:
12
CHANGELOG.md
12
CHANGELOG.md
@@ -75,6 +75,18 @@ ADR-007 and ADR-002.
|
|||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
|
- **A maintenance script could not find the database the site actually uses.**
|
||||||
|
`python scripts/export_catalog.py` on a deployed site died with 1045 "Access
|
||||||
|
denied for user 'root'@'localhost'", naming a user that site does not have.
|
||||||
|
Nothing loads `.env` for a plain script run: `wsgi.py` does it for the served
|
||||||
|
app and the `flask` CLI does it for itself, so both reach the real database,
|
||||||
|
while a bare `python scripts/...` gets neither and falls back to a hardcoded
|
||||||
|
`root@localhost` URL. The read-only failure is the harmless version - six of
|
||||||
|
the seven scripts write, and on a box where those fallback credentials happen
|
||||||
|
to resolve they would have silently rewritten the wrong database. All seven
|
||||||
|
now load `.env` from the repo root, resolved from the script's own location
|
||||||
|
rather than the working directory.
|
||||||
|
|
||||||
- **A search result opened the list it sits in, not the record it found.** A
|
- **A search result opened the list it sits in, not the record it found.** A
|
||||||
NOTICE linked to `/notifications`, so clicking the row search had already
|
NOTICE linked to `/notifications`, so clicking the row search had already
|
||||||
identified sent the reader to the list page to find it again by hand. The id
|
identified sent the reader to the list page to find it again by hand. The id
|
||||||
|
|||||||
Reference in New Issue
Block a user