Skip to content

Commit

Permalink
Fixed automatic generation of the db again
Browse files Browse the repository at this point in the history
  • Loading branch information
micheles committed Sep 18, 2024
1 parent fad81b4 commit 0870e88
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion openquake/commands/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,8 @@ def main(job_ini,
user_name = getpass.getuser()

# automatically create the user db if missing
if config.dbserver.host == '127.0.0.1' and not config.multi_user:
if config.dbserver.host == '127.0.0.1' and (
config.dbserver.file == '~/oqdata/db.sqlite3'):
dbfile = os.path.expanduser(config.dbserver.file)
if not os.path.exists(dbfile):
db.actions.upgrade_db(dbapi.db)
Expand Down

0 comments on commit 0870e88

Please sign in to comment.