We use __NEXT_DATA__ from the page to find the user's latest rated
movies.
We found that at least in one case (of a Video Game) the movie details
were wrong. Normally this shouldn't be a problem though because we know
all the movies already and we keep the values we already have. Otherwise
the data from __NEXT_DATA__ seems more accurate and complete.
The previous version had all 100 movies rendered into the HTML. The new
version has only the top 25 rendered into HTML, but the whole list has
been made available as LD+JSON data.
Since we can easily support both, we don't (yet) remove the old parser.
This completely removes the previous DB patching mechanism.
When this is first run for an existing installation of Unwind, depending
on its version it might lead to problems because the database's schema
won't match the code.
To avoid that issue, when upgrading Unwind to this version make sure to
STOP the old application, install this new version but DON'T start it,
instead use `alembic upgrade head` to run the outstanding patches, and
only then start the application.
We used NUMBER[sic!] as column type in our SQL, which does not exist.
The way SQLite works this mapped to NUMERIC, which is not what we meant,
we really wanted INTEGER here.
Among the many changes we switch to using SQLAlchemy's connection pool,
which means we are no longer required to guard against multiple threads
working on the database.
All db funcs now receive a connection to use as their first argument,
this allows the caller to control transaction & rollback behavior.
This includes only the most basic steps of the upgrade, to make the
existing code run with Python 3.12. No refactoring to make use of new
features is included.