Skip to content

Commit c8392df

Browse files
committed
Merge branch 'dev' into job_files_fastapi_migration
2 parents 62d3499 + 8a8112e commit c8392df

File tree

1,327 files changed

+30813
-15298
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,327 files changed

+30813
-15298
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@ client/webpack-stats.json
165165
packages/*/build
166166
packages/*/dist
167167
packages/*/*.egg-info
168+
packages/meta/requirements.txt
168169

169170
# Standalone script + main, or build into dist
170171
config/plugins/**/static/dist

.pre-commit-config.yaml.sample

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,14 @@ repos:
88
hooks:
99
- id: flake8
1010
- repo: https://github.com/pre-commit/mirrors-prettier
11-
rev: v2.7.1 # Use the sha or tag you want to point at
11+
rev: v3.1.0
1212
hooks:
13-
- id: prettier
14-
types: [file]
15-
types_or: [javascript, jsx, ts, tsx, vue]
16-
additional_dependencies:
17-
- [email protected] # Workaround. See https://github.com/pre-commit/mirrors-prettier/issues/29
13+
- id: prettier
14+
additional_dependencies:
15+
- [email protected] # SEE: https://github.com/pre-commit/pre-commit/issues/3133
16+
exclude_types: # .prettierignore ignored apparently ...
17+
- yaml
18+
- json
1819
- repo: https://github.com/pre-commit/pre-commit-hooks
1920
rev: v4.5.0 # Use the ref you want to point at
2021
hooks:

Makefile

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ SPACE := $() $()
3030
NEVER_PYUPGRADE_PATHS := .venv/ .tox/ lib/galaxy/schema/bco/ \
3131
lib/galaxy/schema/drs/ lib/tool_shed_client/schema/trs \
3232
scripts/check_python.py tools/ test/functional/tools/cwl_tools/
33-
PY37_PYUPGRADE_PATHS := lib/galaxy/exceptions/ lib/galaxy/job_metrics/ \
34-
lib/galaxy/objectstore/ lib/galaxy/tool_util/ lib/galaxy/util/ \
35-
test/unit/job_metrics/ test/unit/objectstore/ test/unit/tool_util/ \
36-
test/unit/util/
33+
PY38_PYUPGRADE_PATHS := lib/galaxy/exceptions/ lib/galaxy/job_metrics/ \
34+
lib/galaxy/objectstore/ lib/galaxy/tool_util/ lib/galaxy/tool_util_models/ \
35+
lib/galaxy/util/ test/unit/job_metrics/ test/unit/objectstore/ \
36+
test/unit/tool_util/ test/unit/tool_util_models/ test/unit/util/
3737

3838
all: help
3939
@echo "This makefile is used for building Galaxy's JS client, documentation, and drive the release process. A sensible all target is not implemented."
@@ -62,10 +62,10 @@ format: ## Format Python code base
6262
remove-unused-imports: ## Remove unused imports in Python code base
6363
$(IN_VENV) autoflake --in-place --remove-all-unused-imports --recursive --verbose lib/ test/
6464

65-
pyupgrade: ## Convert older code patterns to Python 3.7/3.9 idiomatic ones
66-
ack --type=python -f | grep -v '^$(subst $(SPACE),\|^,$(NEVER_PYUPGRADE_PATHS) $(PY37_PYUPGRADE_PATHS))' | xargs pyupgrade --py39-plus
67-
ack --type=python -f | grep -v '^$(subst $(SPACE),\|^,$(NEVER_PYUPGRADE_PATHS) $(PY37_PYUPGRADE_PATHS))' | xargs auto-walrus
68-
ack --type=python -f $(PY37_PYUPGRADE_PATHS) | xargs pyupgrade --py37-plus
65+
pyupgrade: ## Convert older code patterns to Python 3.8/3.9 idiomatic ones
66+
ack --type=python -f | grep -v '^$(subst $(SPACE),\|^,$(NEVER_PYUPGRADE_PATHS) $(PY38_PYUPGRADE_PATHS))' | xargs pyupgrade --py39-plus
67+
ack --type=python -f | grep -v '^$(subst $(SPACE),\|^,$(NEVER_PYUPGRADE_PATHS) $(PY38_PYUPGRADE_PATHS))' | xargs auto-walrus
68+
ack --type=python -f $(PY38_PYUPGRADE_PATHS) | xargs pyupgrade --py38-plus
6969

7070
docs-slides-ready:
7171
test -f plantuml.jar || wget http://jaist.dl.sourceforge.net/project/plantuml/plantuml.jar
@@ -262,6 +262,12 @@ client-test-watch: client ## Watch and run all client unit tests on changes
262262
serve-selenium-notebooks: ## Serve testing notebooks for Jupyter
263263
cd lib && export PYTHONPATH=`pwd`; jupyter notebook --notebook-dir=galaxy_test/selenium/jupyter
264264

265+
files-sources-lint: ## Validate file sources configuration
266+
$(IN_VENV) cd lib && PYTHONPATH=`pwd` python galaxy/files/validate/script.py
267+
268+
files-sources-lint-verbose: ## Validate file sources configuration (verbose)
269+
$(IN_VENV) cd lib && PYTHONPATH=`pwd` python galaxy/files/validate/script.py --verbose
270+
265271
# Release Targets
266272
release-create-rc: ## Create a release-candidate branch or new release-candidate version
267273
$(IN_VENV) ./scripts/release.sh -c

client-api/tsconfig.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"compilerOptions": {
3-
"target": "es2020",
4-
"module": "es2020",
3+
"target": "es2022",
4+
"module": "es2022",
55
"moduleResolution": "node",
66

77
"verbatimModuleSyntax": true,

client-api/tsup.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export default defineConfig({
88
clean: true,
99
treeshake: true,
1010
minify: false,
11-
target: 'es2020',
11+
target: 'es2022',
1212
esbuildOptions(options) {
1313
options.external = [
1414
...options.external || [],

client/docs/avoid-using-global-Galaxy.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ There are definitely use-cases where the Backbone models update over time and we
1414
value inside Vue. Instead of importing backbone models directly into Vue components, try building a
1515
backbone event listener that updates some relevant Vuex store.
1616

17-
- [Keeping Vuex in Sync with
18-
Galaxy](https://github.com/galaxyproject/galaxy/blob/dev/client/src/store/syncVuexToGalaxy.js)
17+
- [Keeping Vuex in Sync with
18+
Galaxy](https://github.com/galaxyproject/galaxy/blob/dev/client/src/store/syncVuexToGalaxy.js)
1919

2020
These issues should disappear over time as the all of the old client is rebuilt in the new
2121
ecosystem.

client/docs/composables.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ Using them effectively can make your code more reusable, decoupled, and easier t
66

77
**More about Composables:**
88

9-
- [Composables Overview](https://vuejs.org/guide/reusability/composables.html)
10-
- [Composition API](https://vuejs.org/api/composition-api-setup.html)
11-
- [\<script setup\>](https://vuejs.org/api/sfc-script-setup.html)
9+
- [Composables Overview](https://vuejs.org/guide/reusability/composables.html)
10+
- [Composition API](https://vuejs.org/api/composition-api-setup.html)
11+
- [\<script setup\>](https://vuejs.org/api/sfc-script-setup.html)
1212

1313
## Using Composables in the Composition API
1414

client/docs/headings.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,23 +6,23 @@ Heading Levels are used by screen readers, and other software, to get a rough id
66

77
## Heading Level best practices
88

9-
- Make sure every route has exactly one `<h1>` element, which best describes the content of the current page.
9+
- Make sure every route has exactly one `<h1>` element, which best describes the content of the current page.
1010

11-
- When increasing a heading level, do not skip Levels.
11+
- When increasing a heading level, do not skip Levels.
1212

13-
- Do not use a headings level to determine it's size. Use one of the heading utility classes (e.g. `h-lg`) instead.
13+
- Do not use a headings level to determine it's size. Use one of the heading utility classes (e.g. `h-lg`) instead.
1414

15-
- Do not use a heading tag to make a non-heading text large. Use a heading utility class on a `<span>` instead.
15+
- Do not use a heading tag to make a non-heading text large. Use a heading utility class on a `<span>` instead.
1616

1717
## Sizing Headings
1818

1919
There are several utility classes which size headings:
2020

21-
- `h-xl` - Extra large headings
22-
- `h-lg` - Large headings (most main headings should have this size)
23-
- `h-md` - Medium headings
24-
- `h-sm` - Small headings (many sub-headings have this size)
25-
- `h-text` - Text sized headings
21+
- `h-xl` - Extra large headings
22+
- `h-lg` - Large headings (most main headings should have this size)
23+
- `h-md` - Medium headings
24+
- `h-sm` - Small headings (many sub-headings have this size)
25+
- `h-text` - Text sized headings
2626

2727
Galaxy uses `h-lg` for most top-level (`<h1>`) headings.
2828

@@ -45,8 +45,8 @@ Set the headings level, by setting aa `h1 ... h6` prop:
4545

4646
Following properties allow for further styling the component:
4747

48-
- `size=["xl", "lg", "md", "sm", "text"]` - sets the headings size class
49-
- `bold` - makes a heading bold
50-
- `inline` - displays the heading inline
51-
- `separator` - draws a separating line, to better distinguish sections
52-
- `icon="..."` - adds a font-awesome icon decoration to the left of the heading. Make sure to also load the icon with `library.add(...)`.
48+
- `size=["xl", "lg", "md", "sm", "text"]` - sets the headings size class
49+
- `bold` - makes a heading bold
50+
- `inline` - displays the heading inline
51+
- `separator` - draws a separating line, to better distinguish sections
52+
- `icon="..."` - adds a font-awesome icon decoration to the left of the heading. Make sure to also load the icon with `library.add(...)`.

client/docs/never-use-jquery.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@ from our source, along with all its invasive plugins.
1515

1616
### References
1717

18-
- [You Don't Need jQuery](https://github.com/nefe/You-Dont-Need-jQuery)
19-
- [document.querySelector](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelector)
18+
- [You Don't Need jQuery](https://github.com/nefe/You-Dont-Need-jQuery)
19+
- [document.querySelector](https://developer.mozilla.org/en-US/docs/Web/API/Document/querySelector)

client/docs/querying-the-api.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,25 +10,25 @@ When querying APIs in Vue components, consider the following approaches and thei
1010

1111
### Composables
1212

13-
- **What Are Composables?**: please read the official Vue documentation on composables [here](https://vuejs.org/guide/reusability/composables.html).
13+
- **What Are Composables?**: please read the official Vue documentation on composables [here](https://vuejs.org/guide/reusability/composables.html).
1414

1515
If there is already a composable that takes care of the logic you need for accessing a particular resource in the API please use it or consider writing a new one. They provide a type-safe interface and a higher level of abstraction than the related Store or the API itself. They might rely on one or more Stores for caching and reactivity.
1616

1717
### Stores
1818

19-
- **Stores Explained**: Please read the official Vue documentation on State Management [here](https://vuejs.org/guide/scaling-up/state-management.html).
19+
- **Stores Explained**: Please read the official Vue documentation on State Management [here](https://vuejs.org/guide/scaling-up/state-management.html).
2020

2121
If there is no Composable for the API endpoint you are using, try using a (Pinia) Store instead. Stores are type-safe and provide a reactive interface to the API. They can also be used to cache data, ensuring a single source of truth.
2222

23-
- **Use Pinia Stores**: If you need to create a new Store, make sure to create a Pinia Store, and not a Vuex Store as Pinia will be the replacement for Vuex. Also, use [Composition API syntax over the Options API](https://vuejs.org/guide/extras/composition-api-faq.html) for increased readability, code organization, type inference, etc.
23+
- **Use Pinia Stores**: If you need to create a new Store, make sure to create a Pinia Store, and not a Vuex Store as Pinia will be the replacement for Vuex. Also, use [Composition API syntax over the Options API](https://vuejs.org/guide/extras/composition-api-faq.html) for increased readability, code organization, type inference, etc.
2424

2525
### Direct API Calls
2626

27-
- If the type of data you are querying should not be cached, or you just need to update or create new data, you can use the API directly. Make sure to use the **GalaxyApi client** (see below) instead of Axios, as it provides a type-safe interface to the API along with some extra benefits.
27+
- If the type of data you are querying should not be cached, or you just need to update or create new data, you can use the API directly. Make sure to use the **GalaxyApi client** (see below) instead of Axios, as it provides a type-safe interface to the API along with some extra benefits.
2828

2929
## 2. Prefer **GalaxyApi client** over Axios (when possible)
3030

31-
- **Use **GalaxyApi client** with OpenAPI Specs**: If there is an OpenAPI spec for the API endpoint you are using (in other words, there is a FastAPI route defined in Galaxy), always use the GalaxyApi client. It will provide you with a type-safe interface to the API.
31+
- **Use **GalaxyApi client** with OpenAPI Specs**: If there is an OpenAPI spec for the API endpoint you are using (in other words, there is a FastAPI route defined in Galaxy), always use the GalaxyApi client. It will provide you with a type-safe interface to the API.
3232

3333
**Do**
3434

@@ -142,6 +142,6 @@ If so, you should consider putting it under src/api/<resource>.ts and exporting
142142

143143
### Should I use the `GalaxyApi client` directly or should I write a wrapper function?
144144

145-
- If you **don't need to do any additional processing** of the data, you **should** use the `GalaxyApi client` directly.
146-
- If you **need to do some additional processing**, then consider writing a wrapper function. Additional processing can be anything from transforming the data to adding extra parameters to the query, providing useful defaults, handling conditional types in response data, etc.
147-
- In any case, please try to avoid modeling your own types if you can use the ones defined in the OpenAPI spec (client/src/api/schema/schema.ts). This will help to keep the codebase consistent and avoid duplication of types or API specification drifting.
145+
- If you **don't need to do any additional processing** of the data, you **should** use the `GalaxyApi client` directly.
146+
- If you **need to do some additional processing**, then consider writing a wrapper function. Additional processing can be anything from transforming the data to adding extra parameters to the query, providing useful defaults, handling conditional types in response data, etc.
147+
- In any case, please try to avoid modeling your own types if you can use the ones defined in the OpenAPI spec (client/src/api/schema/schema.ts). This will help to keep the codebase consistent and avoid duplication of types or API specification drifting.

0 commit comments

Comments
 (0)