John Davis
16e18d404e
Merge pull request #19395 from mvdbeek/alternative_format_source_fix
...
Alternative `format_source` fix
2025-01-23 10:54:03 -05:00
Nicola Soranzo
e2636d774f
Merge pull request #19442 from nsoranzo/type_annot
...
Type annotations improvements
2025-01-23 13:53:58 +00:00
Nicola Soranzo
a79f518f49
Proper subclassing of `ModelManager` generic class
2025-01-22 23:18:53 +00:00
Nicola Soranzo
345d7a588b
Add type annotations
2025-01-22 23:18:53 +00:00
Nicola Soranzo
8797f1e4ef
Make `InstallationTarget` a runtime-checkable protocol
...
Also:
- Reuse its `installed_repository_manager` attribute instead of
instantiating a `InstalledRepositoryManager` in several places.
2025-01-22 23:14:48 +00:00
Nicola Soranzo
0f3a870be5
Fix typos
2025-01-22 23:14:48 +00:00
Aysam Guerler
42f190ea43
Merge pull request #19227 from guerler/vitessce
...
Add Vitessce Viewer
2025-01-22 10:32:16 -05:00
Nicola Soranzo
4a2bdac98b
Merge branch 'release_24.2' into dev
2025-01-22 09:33:23 +00:00
Martin Cech
d1ea6dd3a2
Merge pull request #19308 from guerler/fix_winbox_style
...
[24.2] Fixes window manager scrolling and resizing
2025-01-22 09:30:27 +01:00
Ahmed Awan
3baafc2477
Merge remote-tracking branch 'upstream/release_24.1' into HEAD
2025-01-21 10:24:32 -06:00
Marius van den Beek
b0fe8c9dbf
Merge pull request #19423 from ahmedhamidawan/catch_errors_in_toolStore
...
[24.1] Catch errors in `toolStore` and `ToolPanel`
2025-01-21 14:55:56 +01:00
Laila Los
f3e9ff4eef
Merge pull request #19426 from ElectronicBlueberry/fix-ref-sync
...
[24.2] Fix Activity Bar state lost on page reload
2025-01-21 14:14:04 +01:00
Laila Los
34d127254a
fix synced ref resets empty values
2025-01-21 13:04:38 +01:00
Ahmed Awan
5ebece7168
[24.1] Catch errors in toolStore and ToolPanel
...
Fixes https://github.com/galaxyproject/galaxy/issues/19422
2025-01-20 13:17:56 -06:00
Laila Los
5f484fca62
Merge pull request #19420 from ElectronicBlueberry/duplicate-subworkflows-button
...
Enable cloning subworkflows
2025-01-20 18:30:58 +01:00
John Chilton
a7fcdd3046
Merge pull request #19393 from ahmedhamidawan/hide_upload_help_after_one_view
...
[24.2] Display upload help highlight only once and include Rule-based upload info
2025-01-20 10:14:00 -05:00
David López
28e5f7d84b
Merge pull request #19154 from kysrpex/file_sources_assign_paths
...
Let file sources choose a path for uploaded files
2025-01-20 16:11:57 +01:00
José Manuel Domínguez and David López
3b1516c0c5
Remove remark concerning ExportObjectResultMetadata model validation
...
`ExportObjectResultMetadata.validate_uri()` includes commented out code as a remark for the reader that short term exports need not to have a URI as part of their result metadata. Remove this remark.
Co-authored-by: David López <46503462+davelopez@users.noreply.github.com >
2025-01-20 15:14:15 +01:00
Laila Los
9d0ce932ef
remove test counting i elements
2025-01-20 14:55:14 +01:00
Laila Los
e1c9e7fb2e
enable cloning
2025-01-20 13:58:59 +01:00
Nicola Soranzo
42bf463829
Merge pull request #19406 from nsoranzo/TarFile.extraction_filter
...
Set safe default extraction filter for tar archives
2025-01-18 16:48:01 +00:00
Nicola Soranzo
54df792117
Use CompressedFile.open_tar() to open tar files
2025-01-18 15:03:02 +00:00
Nicola Soranzo
aa49793ecf
Make CompressedFile a context manager
...
to ensure that the archive is closed.
2025-01-18 14:40:30 +00:00
Nicola Soranzo
ccebdcb1f2
Set safe default extraction filter for tar archives
...
[PEP 706](https://peps.python.org/pep-0706/ ), first implemented in Python
3.11.4, mitigates some of the security issues of `TarFile.extract()` and
`TarFile.extractall()` by allowing to specify a `filter` keyword-only
parameter.
Set a safe default (`data_filter`) for the filter if available,
reverting to Python 3.11 behavior ('fully_trusted') otherwise, see
https://docs.python.org/3/library/tarfile.html#supporting-older-python-versions
Also:
- Remove unused `tar` parameter from `upload_tar()`
2025-01-18 14:40:29 +00:00
Nicola Soranzo
371242cbf7
Merge pull request #19418 from galaxybot/dev_auto_update_dependencies
...
Update Python dependencies
2025-01-18 12:27:48 +00:00
galaxybot
b0ce7ccfa9
Update Python dependencies
...
by running `make update-dependencies`.
2025-01-18 03:06:32 +00:00
John Davis
d18ab5495f
Merge pull request #19414 from davelopez/24.1_fix_config_templates_validation
...
[24.1] Fix config template validation for file sources and object store templates
2025-01-17 09:41:00 -05:00
davelopez
eef942a240
Add number coercion to string in StrictModel configuration
...
This will workaround an issue with jinja templates rendering a field composed only by numbers to be considered a number when the field is of type string, causing the config model validation to fail. Trying to cast the value to string using the jinja template itself did not work.
2025-01-17 11:22:27 +01:00
Martin Cech
4e781cd02e
Merge pull request #19409 from jdavcs/dev_pagination_fix
...
Prevent negative offset
2025-01-16 11:12:02 +01:00
Martin Cech
2411fb8887
Merge pull request #19402 from jdavcs/dev_user_email_api_help
...
Display email activation help only if user activation is enabled
2025-01-16 11:10:27 +01:00
John Davis
75cf57adbc
Prevent negative offset
2025-01-15 15:16:40 -05:00
José Manuel Domínguez
7a9a52af67
Add new field uri to ExportObjectResultMetadata model
...
Write the actual URIs where files are saved to by file sources to a new `uri` field of the `ExportObjectResultMetadata` model. Restore behavior before commit 53012bf , namely setting the history export request metadata before attempting the export.
---
Before applying the set of changes from 53012bf , the method `ModelStoreManager.set_history_export_request_metadata()` instantiates a `ExportObjectMetadata` Pydantic model and dumps it to the database in the form of JSON as the field `StoreExportAssociation.export_metadata`. After the export is complete, the method `set_history_export_result_metadata()` takes the same instance of `ExportObjectMetadata`, instantiates a `ExportObjectResultMetadata` Pydantic model, sets it as the `result_data` of the `ExportObjectMetadata` instance, and then saves the `ExportObjectMetadata` Pydantic model in the form of JSON to the database again.
After applying the set of changes, the call to `ModelStoreManager.set_history_export_request_metadata()` is delayed until the file has already been saved to the file source, as the actual URI that the file source assigns to the file is otherwise unknown.
The URI assigned by the file source overwrites the original target URI in the request. This involves a slight deviation from the previous behavior: if for example, power gets cut at the right time, `StoreExportAssociation.export_metadata` may not exist despite the history having been already saved to the file source, because database writes happen within the `finally:` block.
Moreover, overwriting the original target URI from the request is formally wrong, because the actual URI assigned by the file source should be part of the export result metadata, as it becomes known when the export completes.
This commit addresses these issues by adding a new field `uri` to the `ExportObjectResultMetadata` model, where the actual URI the file has been saved to by the file source is written. Backwards compatibility is ensured via `HistoriesService._get_export_record_data()`, which retrieves the new field when available and otherwise uses `ExportObjectRequestMetadata.payload.target_uri` (given that `ExportObjectRequestMetadata.payload` is of type `WriteStoreToPayload`).
2025-01-14 17:02:01 +01:00
John Davis
9fc0f05935
Merge pull request #19366 from galaxybot/dev_auto_update_dependencies
...
Update Python dependencies
2025-01-13 11:25:46 -05:00
Nicola Soranzo
39bb35bebc
Merge branch 'release_24.2' into dev
2025-01-13 16:10:31 +00:00
Marius van den Beek
2d629d0f44
Merge pull request #19208 from bernt-matthias/OutputsFilterExpression-fixes
...
[24.2] Outputs filter linter fixes
2025-01-13 18:09:06 +02:00
Nicola Soranzo
bb438e1e8d
Merge branch 'release_24.1' into release_24.2
2025-01-13 16:02:22 +00:00
John Davis
c11908ff8b
Merge pull request #19399 from nsoranzo/release_24.2_backport_19396
...
[24.2] Backport fix from #19396
2025-01-13 10:28:41 -05:00
John Davis
93b684e913
Display api help based on config
2025-01-13 10:13:52 -05:00
Nicola Soranzo
e61121acab
Use id entity attribute when setting exampleOfWork property
...
Fix the following error in 3 unit tests when using rocrate 0.13.0 :
```
______________________ test_export_invocation_to_ro_crate ______________________
tmp_path = PosixPath('/tmp/pytest-of-runner/pytest-5/test_export_invocation_to_ro_c0')
def test_export_invocation_to_ro_crate(tmp_path):
app = _mock_app()
workflow_invocation = _setup_invocation(app)
crate_directory = tmp_path / "crate"
with store.ROCrateModelExportStore(crate_directory, app=app) as export_store:
export_store.export_workflow_invocation(workflow_invocation)
> validate_invocation_crate_directory(crate_directory)
tests/data/model/test_model_store.py:627:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
tests/data/model/test_model_store.py:564: in validate_invocation_crate_directory
validate_create_action(crate)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
ro_crate = <rocrate.rocrate.ROCrate object at 0x7fb4673c2520>
def validate_create_action(ro_crate: ROCrate):
workflow = ro_crate.mainEntity
actions = [_ for _ in ro_crate.contextual_entities if "CreateAction" in _.type]
assert len(actions) == 1
wf_action = actions[0]
assert wf_action["instrument"]
assert wf_action["instrument"] is workflow
wf_objects = wf_action["object"]
wf_results = wf_action["result"]
assert len(wf_objects) == 1
assert len(wf_results) == 1
for entity in wf_results:
if entity.id.endswith(".txt"):
assert "File" in entity.type
wf_output_file = entity
assert wf_output_file["encodingFormat"] == "text/plain"
> assert wf_output_file["exampleOfWork"] is workflow["output"][0]
E AssertionError: assert '#d2ed04ef-36f8-49ae-86ce-47cb03a856c0' is <d2ed04ef-36f8-49ae-86ce-47cb03a856c0 FormalParameter>
tests/data/model/test_model_store.py:540: AssertionError
```
Also:
- Remove unused `_add_step_tool_pv` method.
2025-01-13 13:04:45 +00:00
Björn Grüning
5c28aaf10b
Merge pull request #19232 from guerler/update_visualizations_24.2
...
[24.2] Update visualizations package versions
2025-01-13 14:02:00 +01:00
Nicola Soranzo
f799a996e1
Ignore mypy unused-ignore error on Python >=3.10
2025-01-13 12:00:55 +00:00
galaxybot
8dc0cf55cb
Update Python dependencies
...
by running `make update-dependencies`.
2025-01-13 11:58:32 +00:00
Nicola Soranzo
0858e07821
Merge pull request #19396 from nsoranzo/ro_crate
...
Use ``id`` entity attribute when setting ``exampleOfWork`` property
2025-01-13 11:55:43 +00:00
mvdbeek
f28ea20d46
Fix unit test
2025-01-10 23:37:11 +02:00
mvdbeek
7566674baa
Fix type annotation resulting from annotating HDCA.collection
2025-01-10 23:37:10 +02:00
mvdbeek
a0919d1117
Evaulate format_source (again) just before job submission
...
At this point the inputs are ready, so expession.json has been replaced
with the true extension.
2025-01-10 19:19:56 +02:00
mvdbeek
20dc7b7eae
Simplify determine_output_format
2025-01-10 18:55:08 +02:00
mvdbeek
f65b754dd0
Add regression test for https://github.com/galaxyproject/galaxy/issues/19245
2025-01-10 18:55:08 +02:00
Nicola Soranzo
dad7c26a83
Use id entity attribute when setting exampleOfWork property
...
Fix the following error in 3 unit tests when using rocrate 0.13.0 :
```
______________________ test_export_invocation_to_ro_crate ______________________
tmp_path = PosixPath('/tmp/pytest-of-runner/pytest-5/test_export_invocation_to_ro_c0')
def test_export_invocation_to_ro_crate(tmp_path):
app = _mock_app()
workflow_invocation = _setup_invocation(app)
crate_directory = tmp_path / "crate"
with store.ROCrateModelExportStore(crate_directory, app=app) as export_store:
export_store.export_workflow_invocation(workflow_invocation)
> validate_invocation_crate_directory(crate_directory)
tests/data/model/test_model_store.py:627:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
tests/data/model/test_model_store.py:564: in validate_invocation_crate_directory
validate_create_action(crate)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
ro_crate = <rocrate.rocrate.ROCrate object at 0x7fb4673c2520>
def validate_create_action(ro_crate: ROCrate):
workflow = ro_crate.mainEntity
actions = [_ for _ in ro_crate.contextual_entities if "CreateAction" in _.type]
assert len(actions) == 1
wf_action = actions[0]
assert wf_action["instrument"]
assert wf_action["instrument"] is workflow
wf_objects = wf_action["object"]
wf_results = wf_action["result"]
assert len(wf_objects) == 1
assert len(wf_results) == 1
for entity in wf_results:
if entity.id.endswith(".txt"):
assert "File" in entity.type
wf_output_file = entity
assert wf_output_file["encodingFormat"] == "text/plain"
> assert wf_output_file["exampleOfWork"] is workflow["output"][0]
E AssertionError: assert '#d2ed04ef-36f8-49ae-86ce-47cb03a856c0' is <d2ed04ef-36f8-49ae-86ce-47cb03a856c0 FormalParameter>
tests/data/model/test_model_store.py:540: AssertionError
```
Also:
- Remove unused `_add_step_tool_pv` method.
2025-01-10 15:13:14 +00:00
Nicola Soranzo
944450aa38
Uniform use of tmp_path in ro-crate tests
2025-01-10 15:12:17 +00:00