-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert database.xml to migrations #865
Comments
requires NC 21 as the command was removed in NC 22 |
Actually, that has already been handled by the commit 6982d91. But I guess I need to make a new Music app release including this commit soon, as the release of NC22 is closing in. Any idea about when the RC1 will be available? I wouldn't want to claim support for NC22 before actually testing with a release candidate; it has happened before that the compatibility has broken between the beta releases. |
Ah, nice! NC 22 is currently on 22.0.0beta5, not sure about the timeline for RC1 though. |
Okay, thanks for the info! |
Music v1.2.1 with support for NC22 is now released. |
Thanks for the release! 👍 I've updated to that version from NC 21 and did a quick test with the following, which worked fine:
also worked with the Ultrasonic Android app for playlist listing and playback. |
@paulijar, thanks for your commit, this is very instructive for other apps too! |
@stefan123t No problem. If other apps use this as reference, then they should notice that there are some pit holes in the automatically generated Migration script as included in 6982d91. It does work correctly when installing on a clean environment, or an environment which already has an up-to-date database schema. But it cannot handle situations where there is an outdated DB schema from an older version of the app, and some existing table would need to be modified by adding and/or removing columns or indexes. To overcome this, my final implementation for the first Migrations script is like this: https://github.com/owncloud/music/blob/master/lib/Migration/Version010300Date20210906093000.php. It's fully hand-crafted although based on the automatically generated first version. It should now do the job, no matter which previous version of the Music app the user might have installed. |
As of Nextcloud 22, the database.xml file has been deprecated:
we should migrate it to DB migrations
The text was updated successfully, but these errors were encountered: