04_galaxy_integration

04 - Galaxy Integration: Migration Design

TL;DR

Current Galaxy doc infra (facts, origin/dev @ 8cecbebdf98)

ThingWhere / what
Sphinx configdoc/source/conf.py: extensions = ["myst_parser", "sphinx.ext.intersphinx", "sphinx.ext.mathjax"] (+autodoc/viewcode unless skipped); myst_enable_extensions = [dollarmath, attrs_block, deflist, substitution, colon_fence]; myst_heading_anchors = 5; source_suffix = [".rst", ".md"]; exclude_patterns = ["**/_*.*"]; html_theme = "sphinx_rtd_theme". No plantuml/mermaid extensions.
Build entryroot Makefile docs: -> make -C doc clean html; docs-develop sets GALAXY_DOCS_SKIP_VIEW_CODE=1.
Generated-page hookdoc/Makefile: GENERATED_RST = source/dev/schema.md source/dev/user_defined_tools_authoring.md source/admin/config_logging_default_yaml.rst; every builder target depends on it (html: $(GENERATED_RST)); outputs gitignored in root .gitignore (lines ~157-162, also doc/source/dev/plantuml.jar).
CI.github/workflows/docs.yaml: runs on all push/PR except client/**, lib/galaxy_test/selenium/**, packages/**; Python 3.10; uv pip install -r requirements.txt -r lib/galaxy/dependencies/dev-requirements.txt sphinxcontrib-simpleversioning; make docs; deploys to S3 s3://galaxy-docs/en/{latest,release_XX.YY} (docs.galaxyproject.org). Not ReadTheDocs. Versioned per release branch.
Lint.github/workflows/lint.yaml -> tox -e lint,lint_docstring_include_list,mypy,format. No markdown linter anywhere.
Diagramsdoc/source/dev/image.Makefile (wildcards *.mindmap.yml + *.plantuml.txt, same lineage as our images/Makefile), plantuml_options.txt, plantuml_style.txt. Rendered SVGs committed.
Dev docs indexdoc/source/dev/index.rst - flat toctree of ~22 pages; intro paragraph points to GTN “Code Architecture” slides + bit.ly/gx-arch-vids.
CODEOWNERSNone in Galaxy.
Agent context.claude/commands/{triage-issue,triage-bug,triage-feature,weekly-triage}.md (dannon, 2026); subdir CLAUDE.md in packages/tool_shed/, lib/tool_shed/webapp/frontend/, test/functional/tools/ (jmchilton). No root CLAUDE.md/AGENTS.md, no .claude/skills/. No PR/issue discussion of AGENTS.md or an AI policy found; CONTRIBUTING.md silent on AI.
Stale linksCONTRIBUTING.md:8, doc/source/dev/index.rst, doc/source/dev/writing_tests.md link training.../topics/dev/tutorials/architecture/slides.html - after the GTN split (training-material #6602) that URL only redirects to architecture-ecosystem. Cheap win to fix in the migration.

Our repo, for scale: 16 topics, 162 tracked files under topics/ (89 md, 44 yaml, 29 diff), blocks = 394 slide / 116 prose / 4 agent-context; ~300 Remark-isms (class:, .footnote[], etc.) that outputs/sphinx-docs/build.py strips; committed images 3.4 MB (largest galaxy_schema.png 820K, element_galaxyproject.png 508K); 47 hand-written *.plantuml.txt, 16 *.mindmap.yml, 3 *.mermaid.txt; ~4.3k lines Python across scripts/ + outputs/. 107 commits, 100% jmchilton.

Overlap with existing Galaxy docs

TopicExisting Galaxy docAction
testsdev/writing_tests.md, dev/debugging_tests.md, dev/run_tests_help.txtBiggest overlap. Topic = overview + link into these; don’t duplicate how-to.
application-components, frameworksdev/api_guidelines.rstCross-link; architecture = “why/layers”, guidelines = rules.
pluginsdev/build_a_job_runner.rst, dev/data_types.md, dev/interactive_environments.rst, dev/data_managers.rstTopic becomes hub linking these.
dependenciesadmin/dependency_resolvers.rst, admin/container_resolvers.rstCheck topic scope (Python/JS deps vs tool deps) - likely little real overlap.
file-sourcesadmin/file_source_* pages (admin config)Complementary (dev internals vs admin config).
productionlarge swaths of admin/Highest drift risk; consider trimming to pointers.
dependency-injection, tasks, startup, files, markdown, client, principlesnone (DI adjacent to dev/database_session_management.md)Pure gain; best first-PR candidates.
ecosystem, project-managementdoc/source/project/*, CONTRIBUTING.md, galaxyproject.orgLeast code-bound; maybe leave on GTN/Hub only.

Existing dev docs are actively maintained by a broad set (mvdbeek 41, jmchilton 28, selten 26, nsoranzo 21, …; 50 commits in last year) - good sign that dev docs are a living place, but the flat index needs a new “Architecture” section rather than 16 more siblings.

Layout options

A. Convert to plain MyST pages (drop YAML model)

doc/source/dev/architecture/<topic>.md, hand-edited, images next to them.

doc/architecture/
  topics/<id>/{metadata.yaml,content.yaml,fragments/*.md}
  images/  (*.plantuml.txt + committed *.svg/png, image.Makefile)
  models.py            # pydantic, from scripts/models.py
doc/gen_architecture_docs.py   # from outputs/sphinx-docs/build.py
doc/source/dev/architecture/   # generated *.md + index, gitignored

doc/Makefile: add source/dev/architecture/index.md (or a stamp) to GENERATED_RST; clean already removes GENERATED_RST. dev/index.rst gets an architecture/index toctree entry.

C. Generator elsewhere, generated MyST committed

Output committed into doc/source/dev/architecture/; CI --check for drift (galaxy-brain already does this pattern).

Images / diagrams

Superseded 2026-09-29: all diagrams moved to Mermaid (.mmd) in galaxy-architecture PR #33, and Galaxy is dropping PlantUML for sphinxcontrib-mermaid (#23801). See MIGRATION_PLAN § Key decision: diagrams. Bullets below are the pre-Mermaid analysis.

Maintenance model

Migration mechanics

Agent context / agentic operations in Galaxy

Downstream consumers plan

Pitch

Pros

Cons maintainers will raise -> preemption

Open questions

  1. doc/architecture/ vs doc/source/dev/architecture/_src/ (underscore excluded by exclude_patterns)? Prefer former.
  2. Generated at build (B) vs committed (C) - ask mvdbeek/nsoranzo which they’d accept?
  3. Slides builder in Galaxy at all, or keep export tooling in galaxy-architecture pointed at Galaxy source?
  4. GTN maintainers OK with generated slides + banner? Who to ask?
  5. Path check: hard fail or warning? In tox lint or docs.yaml?
  6. Root AGENTS.md vs CLAUDE.md - float separately?
  7. Which topics stay GTN/Hub-only (ecosystem, project-management, production)?
  8. Preserve history via filter-repo or fresh import?
  9. Delete vestigial slideshow targets/scripts/slideshow/ in PR1 or separate?
  10. galaxy-brain: GALAXY_ROOT local clone vs sparse checkout?
  11. Mermaid: convert 3 diagrams to PlantUML or keep committed renders only?
  12. Pre-pitch: open a Galaxy discussion/issue first, or lead with PR1 as the proposal?