Skip to content
Snippets Groups Projects
Forked from Platform / Development / swh-core
26 commits behind the upstream repository.
David Douard's avatar
David Douard authored
We used to run all the sql init scripts before trying to determine the
backend's version, only to gather this piece of information at time we
want to write it in the dbversion table.

However, the presence of the dbversion is actually used to determine
whether a db has been initialized or not.

So if the configuration for the backend prevent it from being
instantiated, which is done to retrieve the backend version, then this
last initialization step will fail preventing any future 'swh db' handling
operation from working properly.

In this change, we move the backend version identification logic before
attempting any actual db initialization process so this situation does
not occur.
582eba15
History

Software Heritage - Core foundations

Low-level utilities and helpers used by almost all other modules in the stack.

core library for swh's modules:

  • config parser
  • serialization
  • logging mechanism
  • database connection
  • http-based RPC client/server