#25 Add databse-upgrade tool to manage database schemas
Merged 8 years ago by puiterwijk. Opened 8 years ago by puiterwijk.

No commits found

no initial comment

python3 future-proofing use "as" instead of comma.

Should the time be hardcoded or user-configurable?

Is it possible to go backwards? Probably better to ensure that current_version > code_schema_version

Another comma to as for python3

Is it more readable to collapse this without the intermediate variable?

Typo in initialization.
Should this be the warn or info level instead of error?

Oh, never mind about error level, missed next line that exits

I will be refactoring this code with the cleanup patch that's coming soon.

People might have done a yum downgrade, and I was not planning to implement database downgrading (if they want that, they can just put back a database backup from before the upgrade).

If I would use current_version > code_schema_version, they might be running with a newer database scheme that's not known by the current Ipsilon version.

With the code in this patch set, it would see it's not the correct version, try to find an upgrade path, and given that there will be none, drop in the NotImplementedError, failing safely (without doing stuff in a database that we do not know the schema of).

Is "scheme" a typo? Should it be schema?

Would it be simpler to return an empty list instead of None so you could just do the contains comparison?

Worth creating a specific Exception subclass for this, DatabaseError?

Yes, will fix that for current_version reading and writing.

Metadata