Commit Graph
62881 Commits
Author SHA1 Message Date
John DavisandMarius van den Beek 7e5fa1f1c8 Update lib/galaxy/model/migrations/README.md
Co-authored-by: Marius van den Beek <m.vandenbeek@gmail.com>
2022-09-16 00:39:03 -04:00
John DavisandMarius van den Beek 766b4d8c7a Update lib/galaxy/model/migrations/README.md
Co-authored-by: Marius van den Beek <m.vandenbeek@gmail.com>
2022-09-16 00:39:03 -04:00
John Davis 78dc54e8c7 Rewrite migrations documentation 2022-09-16 00:39:03 -04:00
John Davis 2aaf6b8896 Override script name to display correct usage in cli help 2022-09-16 00:39:03 -04:00
John Davis 3c094790a1 Update test comments 2022-09-16 00:39:03 -04:00
John Davis 372d4af0b8 Add type hints 2022-09-16 00:39:03 -04:00
John Davis 9e7d82b295 Remove duplicate migration code 2022-09-16 00:39:03 -04:00
John Davis 1f5b0e6bba Drop LegacyScripts: no longer used 2022-09-16 00:39:03 -04:00
John Davis 5b7d46efe6 Remove manage_db_adapter.py
We no longer need to translate the arguments of manage_db.sh into
arguments for alembic. The new facade script for alembic (db.sh)
accesses the alembic api programmatically.
2022-09-16 00:39:03 -04:00
John Davis 9b66c57fe0 Rename migrate_db.py > run_alembic.py
This is consistent with other similar pairs of files:
[script-name].sh invoking scripts/[script-name].py (check_model, create_roolshed_db, db)

Also, the python file does not require exec permissions.
2022-09-16 00:39:03 -04:00
John Davis 6bb29939e2 Drop create_db.sh, create_db.py (see note)
For ToolShed, we have create_toolshed_db.sh.

For galaxy and toolshed install databases (gxy and tsi branches under
alembic), we use the `init` subcommand of the `db.sh` script (`./db.sh
init`), which has exactly the same functionality as these deleted
scripts.

To the best of my knowledge, these are not used anywhere else (unlike,
for example, scripts/manage_db.py, which is called from the
ansible-galaxy role).
2022-09-16 00:39:03 -04:00
John Davis 36850443f1 Rename manage_db.sh to manage_toolshed_db.sh. Limit to TS operations.
Becuase everything else is handled via db.sh or run_alembic.sh
2022-09-16 00:39:03 -04:00
John Davis dc89cf2b4f Misc edits to db.sh 2022-09-16 00:39:03 -04:00
John Davis 7e238bf591 Add --raiseerr option; hide error traceback by default 2022-09-16 00:39:03 -04:00
John Davis 959bc49e66 Add missing tests 2022-09-16 00:39:03 -04:00
John Davis 330d2043c1 Revise db.sh cli command aliases
1. Remove aliases from subcommands that change things (upgrade, downgrade,
revision, init) to reduce risk of accidental usage.

2. Add aliases to readonly subcommands (history, show, version,
   dbversion)

3. Minor edits
2022-09-16 00:39:03 -04:00
John Davis 1f25c6ee96 Change parsing of --galaxy-config option
Rationale: alternate config file applies to all subcommands, so, I
think, it is more correct to run this:

> ./db.sh -c mygalaxy.yml upgrade some-revision-id

than this:

> ./db.sh upgrade some-revision-id -c mygalaxy.yml

That's also consistent with how alembic handles this option.
2022-09-16 00:39:03 -04:00
John Davis 0745e2e05c Fix mypy by asserting object before accessing its attributes 2022-09-16 00:39:03 -04:00
John Davis 89f753767b Fix packages tests: script is one level up 2022-09-16 00:39:03 -04:00
John Davis ac6b0ceee0 Fix linting 2022-09-16 00:39:03 -04:00
John Davis de856e825a Add init command 2022-09-16 00:39:03 -04:00
John Davis e247afd8d7 Set dburl in alembic config 2022-09-16 00:39:03 -04:00
John Davis 0a798ea536 Test against 1 or 2 databases 2022-09-16 00:39:03 -04:00
John Davis b30e4e14ae Add inline testing documentation 2022-09-16 00:39:03 -04:00
John Davis 811392b468 Add logging to script 2022-09-16 00:39:03 -04:00
John Davis a69ab407a6 Add initial draft 2022-09-16 00:39:03 -04:00
John Davis 6abc9dc1c5 Refactor get_alembic_cfg: make available to other code 2022-09-16 00:39:03 -04:00
John Chilton 1b3da85119 Merge pull request #14628 from jmchilton/cleanup_update_repo_manager
Cleanup update_repository_manager in Galaxy repository install code.
2022-09-15 21:09:19 -04:00
Nicola Soranzo aa4443af18 Merge pull request #14596 from jdavcs/dev_alembic_fix3
Better + additional fix for alembic offline mode
2022-09-16 01:02:52 +01:00
Nicola Soranzo 331d0d2465 Merge pull request #14580 from nsoranzo/recommend_draft_instead_of_WIP
[PROCEDURES] Recommend to use PR draft state instead of WIP title/label
2022-09-15 19:05:40 +01:00
John Chilton c04dd77de0 Cleanup update_repository_manager in Galaxy repository install code. 2022-09-15 13:39:25 -04:00
Björn Grüning 01fffdf175 Merge pull request #14617 from jmchilton/remove_propertiary_datatypes
Remove legacy tool shed datatype handling
2022-09-15 18:21:43 +02:00
Björn Grüning 89803553db Merge pull request #14624 from davelopez/fix_invocation_export_with_celery
Fix `toolbox` access in invocation export
2022-09-15 18:20:12 +02:00
John Chilton a887fc894d Merge pull request #14616 from jmchilton/ts_tests_1
More tool shed API tests (+fixes)
2022-09-15 09:08:31 -04:00
John Chilton 1c6c697d55 Merge pull request #14615 from jmchilton/ts_cleanup_3
More Tool Shed Cleanup
2022-09-15 09:04:39 -04:00
davelopezandMarius van den Beek 07b38ba429 Fix toolbox access in invocation export
When exporting an invocation using Celery we don't have access to the ToolBox and also don't need it so we make it optional.
Thanks Marius for the solution.

In addition:
- Fix mypy by raising a tool missing exception in the `augment` method
- Also remove unused `inputs` parameter

Co-authored-by: Marius van den Beek <m.vandenbeek@gmail.com>
2022-09-15 14:42:50 +02:00
Dannon 705d8fbffd Merge pull request #14623 from ElectronicBlueberry/vue-jest-upgrade
Upgrade vue2-jest to 29.1.0
2022-09-15 07:56:48 -04:00
Laila Los 87b7085941 upgrade vue-jest to 29.1.0 2022-09-15 12:30:11 +02:00
David López 2741b20841 Merge pull request #14595 from jmchilton/ro_crate
Implement RO Crate export of Galaxy histories and invocations.
2022-09-15 08:55:19 +02:00
Nicola Soranzo 9a8efa6c28 Merge pull request #14614 from nsoranzo/deprecated_method_status_code
Change HTTP status code for ``DeprecatedMethod`` exception to 410
2022-09-14 20:07:40 +01:00
John Chilton 0f9dbb4045 Remove more datatype legacy handling code. 2022-09-14 11:51:39 -04:00
John Chilton 3b1331de51 Remove code and config option related to loading shed datatypes. 2022-09-14 11:51:38 -04:00
John Chilton f8c1c11016 API tests for tool shed search APIs. 2022-09-14 09:31:27 -04:00
John Chilton e5bbad2f36 Flush out pydantic models for tool shed metadata. 2022-09-14 09:31:25 -04:00
John Chilton b2a4cdeb82 Remove now unused function. 2022-09-14 09:24:25 -04:00
John Chilton 0869bfd17f Rename method to indicate an internal method. 2022-09-14 09:23:55 -04:00
John Chilton 9351be5c96 Refactor method name to make clear it is private. 2022-09-14 09:07:43 -04:00
John Chilton d26cade072 Remove more unused tool shed code. 2022-09-14 09:07:43 -04:00
John Chilton 90858d3137 Move create_element into the only place it is used. 2022-09-14 09:07:43 -04:00
Nicola Soranzo b4a3735999 Change HTTP status code for `DeprecatedMethod` exception to 410
Replaced the 404 (Not Found) HTTP response status code with 410 (Gone),
which is more correct, see details at:

https://developer.mozilla.org/en-US/docs/Web/HTTP/Status#client_error_responses
2022-09-14 13:24:24 +01:00