Skip to content

Commit

Permalink
Add fallback for settings["here"]
Browse files Browse the repository at this point in the history
- In the context of a DativeTop deploy, the OLD was failing during
  database initialization because settings['here'] was throwing a
  KeyError. The root cause of this is still not understood. However,
  this change is a fallback/workaround for the issue.
  • Loading branch information
jrwdunham committed Jul 26, 2021
1 parent d538e8b commit 62962cd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion old/scripts/initialize.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ def main(argv=None):
args.old_name, os.path.join(
settings['permanent_store'],
settings['old_name']))
languages = omb.get_language_objects(settings['here'], truncated=False)
here = settings.get('here', os.path.dirname(settings['permanent_store']))
languages = omb.get_language_objects(here, truncated=False)
administrator = omb.generate_default_administrator(settings=settings)
contributor = omb.generate_default_contributor(settings=settings)
viewer = omb.generate_default_viewer(settings=settings)
Expand Down

0 comments on commit 62962cd

Please sign in to comment.