Skip to content

Commit

Permalink
Add alembic.ini (pypi#10053)
Browse files Browse the repository at this point in the history
  • Loading branch information
abitrolly committed Oct 13, 2021
1 parent ff6d405 commit fc1d1c3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 1 addition & 2 deletions warehouse/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,7 @@ def callback(scanner, _name, wrapped):


def _configure_alembic(config):
alembic_cfg = alembic.config.Config()
alembic_cfg.set_main_option("script_location", "warehouse:migrations")
alembic_cfg = alembic.config.Config("warehouse/migrations/alembic.ini")
alembic_cfg.set_main_option("url", config.registry.settings["database.url"])
return alembic_cfg

Expand Down
2 changes: 2 additions & 0 deletions warehouse/migrations/alembic.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[alembic]
script_location = warehouse:migrations

0 comments on commit fc1d1c3

Please sign in to comment.