The `conda` package on PyPI is severely outdated and unmaintained, and
the output of `run_command("search", ...)` did not parse correctly.
Fix broken `test_conda_search` unit test.
We do need to include some kind of worker id in the server_name. If we
don't do this and we start with multiple workers the internal
QueueWorker won't work and multiple processes can pick up the same job
if the web process is also a job handler.
If the database is combined, running `./manage_db.sh upgrade` should upgrade
BOTH models: gxy and tsi. However, if tsi uses a separate database, only
the galaxy model should be updated.
Also, see this for context: https://github.com/galaxyproject/galaxy/pull/13108#discussion_r789108576
See inline comments for more details.
The new tests are examples of new behavior.
All refactoring is directly related to the changes in this commit.
- Preserves usage of legacy script while not hiding the Alembic script.
(see manage_db.sh and run_alembic.sh)
- Adds documentation (see top of script files)
- Includes misc. relevant refactorings
- Includes unit tests for testing legacy script handling
Also add exec permissions to create/migrate python scripts.
(not sure this is required, adding for consistency with previous
version)
+ A few fixes for TS scripts, tests
Squashed:
- pick b62443245e Add create/migrate scripts for Alembic dbs
- squash 06f0a923ca Fix integration test (test only relevant for TS)
- pick 058f09a7ec Integrate migrations design into config and model code
- squash 89ca1a537b Drop config.database_create_tables (not used)
Next squash:
- pick cbf29e138c Integrate migrations into config, model (squashed)
- squash dd51fd578e Address existing mypy error (see note)
Address existing mypy error (see note)
This is a (possible) bug that has existed on dev. To expose it, simply
change this call to init_models_from_config
(https://github.com/galaxyproject/galaxy/blob/release_21.09/lib/galaxy/config/__init__.py#L1302)
to a call directly to mapping.init(). The result will be 6 mypy errors.
The reason is that the mapping.init() function
(https://github.com/galaxyproject/galaxy/blob/release_21.09/lib/galaxy/model/mapping.py#L79)
specifies its return type as GalaxyModelMapping - which results in
several errors of this type:
lib/galaxy/app.py:178: error: Definition of "model" in base class "MinimalApp" is incompatible with definition in base class "ConfiguresGalaxyMixin"
When we call an intermediary function (that does not have a return type
specified), mypy is happy.
This should be addressed in a separate issue/PR. Removing the return
type is the simplest (temporary) solution.
Next squash:
- squash c8429737ab Add type hints to migrations modules
- squash a54be2259f Remove circular dependency between migrations and config
Setup infrastructure for running db scripts (squashed)
Squashed:
- pick 146ff8019a Setup infrastructure for running db scripts
- squash e0a26dcf3a Move is-one-db check into model.database_utils
Squashed:
- pick a82c44ac12 Setup infrastructure for running db scripts (squashed)
- squash 31a1a702fe Fix mypy error
Squashed:
- pick 14a4eb08e2 Setup infrastructure for running db scripts (squashed)
- squash b1c6acb0f1 When overriding, override.
Add type hints to migrations modules
Remove circular dependency between migrations and config