Do not assume v1.12 when there is no index-scheduler version

This commit is contained in:
Louis Dureuil 2025-01-23 17:16:53 +01:00
parent 718a98fbbf
commit c1e5897076
No known key found for this signature in database

View File

@ -47,13 +47,10 @@ impl Versioning {
let this = Self { version }; let this = Self { version };
let from = match this.get_version(&wtxn)? { let from = match this.get_version(&wtxn)? {
Some(version) => version, Some(version) => version,
// fresh DB: use the db version
None => { None => {
let assumed_version = match db_version { this.set_version(&mut wtxn, db_version)?;
(1, 12, _) => db_version, db_version
_ => (1, 12, 7),
};
this.set_version(&mut wtxn, assumed_version)?;
assumed_version
} }
}; };
wtxn.commit()?; wtxn.commit()?;