Web developmentPublished Aug 25
Link shortener: created links disappear after restart
Inserts are never committed, so links vanish when the process restarts.
Description
URL shortener (`store.py`, Flask + SQLite).
Problem: links created through the API work in the current connection but are not visible to other connections and disappear after a restart. The `links` table is created correctly.
Expected:
- every created link is durable immediately after `Store.add()` returns;
- redirects keep working for links created in a previous process;
- no change to the HTTP API.
Acceptance: `python -m unittest discover -s tests` passes.
Write me here, I'll share the project archive and the SQLite file.
Skills
- Python
- Flask
- SQLite