Version Migrations
We need to be able to migrate from one version of Exaile to another. Currently, the most important job for this is the migration from 0.2.14 database and settings to 0.3.x.
Blueprint information
- Status:
- Not started
- Approver:
- None
- Priority:
- Undefined
- Drafter:
- None
- Direction:
- Needs approval
- Assignee:
- Adam Olsen
- Definition:
- Approved
- Series goal:
- Accepted for 0.3.x
- Implementation:
- Unknown
- Milestone target:
- 0.3.0
- Started by
- Completed by
Related branches
Related bugs
Sprints
Whiteboard
Basic idea:
should be a separate module in xl, xl/migration perhaps
a file or two for common migration utilities (eg. an easy way of mapping old settings to new), and for providing the means of selecting the appropriate upgrade path.
0.2.14 to 0.3.0+:
this path is the easiest, we can handle it by seeing if firstrun is set, and if it is, check to see if 0.2's settings exist. if they do, prompt the user (if gui is enabled) as to whether they want to import or not. if they do (or there is no gui to prompt with), then import the migration framework for 0.2.14->0.3.0 and run it.
0.3.x to 0.3.y:
we'll need to add versioning data to the settings file and possibly other files (the db already has versioning). these versions should be incremented ONLY on backwards-
possible basic outwards api calls:
per module, as in 0.3.x to 0.3.y:
from xl import migration
migration.
global, as in 0.2.14 to 0.3.0:
if firstrun:
from xl import migration
migration.
random thoughts:
plugins might need upgrade paths too, how can we provide for this?