Skip to content

Commit

Permalink
Merge branch 'galaxyproject:main' into elixir-toolkit-theme
Browse files Browse the repository at this point in the history
  • Loading branch information
supernord authored Nov 8, 2024
2 parents ba1e1eb + dda9c0d commit d0c97be
Show file tree
Hide file tree
Showing 13 changed files with 1,662 additions and 125 deletions.
17 changes: 0 additions & 17 deletions .github/workflows/lint.yaml

This file was deleted.

42 changes: 42 additions & 0 deletions .github/workflows/lint_and_unittest.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Code best practice and unittesting

on:
pull_request:
branches:
- main
paths:
- 'bin/**' # This will trigger the workflow only if files in the 'bin' folder are modified.

concurrency:
group: lint-${{ github.ref }}
cancel-in-progress: true

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install tox
run: python -m pip install 'tox>=1.8.0'
- name: Lint
run: tox -e lint

unittest:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: ['3.11']
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install requirements
run: python -m pip install -r requirements.txt
- name: Run unittests
run: |
PYTHONPATH=bin python -m unittest discover -s bin/tests
29 changes: 24 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,28 @@
Galaxy Codex
============

Galaxy Communities Dock aka Galaxy Codex is a catalog of Galaxy resources (tools, training, workflows) that can be filtered for any community.
Galaxy Communities Dock (Galaxy CoDex) is a catalog of resources for Galaxy communities.

This repository stores the sources to build this catalog and its content. The catalog is automatically updated every week.
Currently, we have two main resources:

Any Galaxy community can be added to this project and benefit from the dedicated resources, including interactive tables that can be embedded into subdomains and website via an iframe. **Learn [how to add your community](https://training.galaxyproject.org/training-material//topics/dev/tutorials/community-tool-table/tutorial.html) in the dedicated GTN tutorial**.
1. **Galaxy Community Catalog**: from tools, training & workflows
2. **Galaxy Labs**: (led by Galaxy Australia!) main and tool panel content for communities to spin up subdomain pages

# Catalog content
This repository stores the sources to build all of this content. The catalog is automatically updated every week.

# Join the CoDex
Any Galaxy Community can be added to this project and benefit from the dedicated resources.
**Learn [how to add your community](https://training.galaxyproject.org/training-material/topics/community/faqs/codex.html)** in the dedicated GTN tutorial.

# Galaxy Community Catalog
To generate interactive tables that can be embedded into Galaxy Labs (subdomains) and websites via an iframe.
**Learn [how to generate the Galaxy Community Catalog](https://training.galaxyproject.org/training-material//topics/dev/tutorials/community-tool-table/tutorial.html)** in the dedicated GTN tutorial.

# Galaxy Lab
To generate GalaxyLab content, you can follow our documentation (to be added!).
To spin up a GalaxyLab on your server, you can follow our documentation (to be added!).

# Galaxy Community Catalog content

## Tool table

Expand Down Expand Up @@ -42,4 +57,8 @@ Suite users on main servers | Number of users of the suite on all UseGalaxy ser
Suite runs (last 5 years) on main servers | Number of runs of the suite tools in the last 5 years on all UseGalaxy servers
Suite runs on main servers | Number of runs of the suite tools on all UseGalaxy servers
Deprecated | Deprecation status after review by a domain expert
To keep | Status to add to a community after review by a domain expert
To keep | Status to add to a community after review by a domain expert

# Vocabulary
**Galaxy Lab**: Formerly known as Subdomains, Galaxy Australia built a new method for generating the main and tool panels for a Galaxy subdomain, known as a Galaxy Lab.
**Galaxy Community**: Galaxy Community of Practice. You can see a full list of Special Interest Groups in the [SIG Directory](https://galaxyproject.org/community/sig).
4 changes: 1 addition & 3 deletions communities/spoc/lab/templates/conclusion.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@ <h4 class="mb-3">Single Cell and Spatial Omics community support</h4>
<h4 class="mb-3">News and Events</h4>

<div class="row justify-content-center">
<div class="col">
<iframe width="400px" height="600px" src="https://training.galaxyproject.org/training-material/feeds/single-cell-month.w.html"></iframe>
</div>
<iframe width="100%" height="600px" src="https://training.galaxyproject.org/training-material/feeds/single-cell-month.w.html"></iframe>
</div>
</section>

Expand Down
7 changes: 7 additions & 0 deletions sources/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,13 @@ When the tests succeed a maintainer will merge the dev branch into main. Feel fr

The reason we are not running the tests directly on the pull request branch is, that this does not allow to access the GitHub secrets, that are required to run the tests.

# Run the unit tests locally

```
cd codex/sources
PYTHONPATH=bin python -m unittest discover -s bin/tests
```

### Tools

To make a test run of the tool to check its functionalities follow [Usage](#Usage) to set-up the environnement and the API key, then run
Expand Down
2 changes: 1 addition & 1 deletion sources/bin/extract_all_tutorials.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ then
python sources/bin/extract_gtn_tutorials.py \
extract \
--all "communities/all/resources/test_tutorials.json" \
--tools "communities/all/resources/tools.json" \
--tools "communities/all/resources/test_tools.json" \
--api $PLAUSIBLE_API_KEY \
--test
else
Expand Down
2 changes: 1 addition & 1 deletion sources/bin/extract_all_workflows.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ if [ ! -z $1 ]
then
python sources/bin/extract_galaxy_workflows.py extract \
--all communities/all/resources/test_workflows.json \
--tools communities/all/resources/tools.json \
--tools communities/all/resources/test_tools.json \
--test
else
python sources/bin/extract_galaxy_workflows.py extract \
Expand Down
10 changes: 5 additions & 5 deletions sources/bin/shared.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,11 @@ def read_suite_per_tool_id(tool_fp: str) -> Dict:
tool_suites = load_json(tool_fp)
tools = {}
for suite in tool_suites:
for tool in suite["Galaxy tool ids"]:
for tool in suite["Suite ID"]:
tools[tool] = {
"Galaxy wrapper id": suite["Galaxy wrapper id"],
"Galaxy wrapper owner": suite["Galaxy wrapper id"],
"EDAM operation": suite["EDAM operation"],
"Suite ID": suite["Suite ID"],
"Suite owner": suite["Suite owner"],
"EDAM operations": suite["EDAM operations"],
}
return tools

Expand Down Expand Up @@ -154,7 +154,7 @@ def get_edam_operation_from_tools(selected_tools: list, all_tools: dict) -> List
edam_operation = set()
for t in selected_tools:
if t in all_tools:
edam_operation.update(set(all_tools[t]["EDAM operation"]))
edam_operation.update(set(all_tools[t]["EDAM operations"]))
else:
print(f"{t} not found in all tools")
return list(edam_operation)
Loading

0 comments on commit d0c97be

Please sign in to comment.