caddforge 0.23.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,9 @@
1
+ __pycache__/
2
+ *.py[cod]
3
+ .venv/
4
+ dist/
5
+ build/
6
+ wheelhouse/
7
+ .pytest_cache/
8
+ .ruff_cache/
9
+ *.egg-info/
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2026 The CADDForge Authors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,219 @@
1
+ Metadata-Version: 2.5
2
+ Name: caddforge
3
+ Version: 0.23.1
4
+ Summary: The complete public CADDForge toolbox: core, scientific plugins, GUI, and documentation.
5
+ Author-email: Manuel Sellner <manuel.sellner@idorsia.com>, Christoph Sager <christoph.sager@idorsia.com>
6
+ License: MIT
7
+ License-File: LICENSE
8
+ Requires-Python: >=3.10
9
+ Requires-Dist: caddforge-core==0.22.0
10
+ Requires-Dist: caddforge-datascience==0.5.0
11
+ Requires-Dist: caddforge-descriptors==0.11.0
12
+ Requires-Dist: caddforge-docking[gui]==0.7.0
13
+ Requires-Dist: caddforge-docs==0.3.0
14
+ Requires-Dist: caddforge-fep[gui]==0.7.0
15
+ Requires-Dist: caddforge-gui==0.6.0
16
+ Requires-Dist: caddforge-md[gui,minimize]==0.13.0
17
+ Requires-Dist: caddforge-ml[ui]==0.4.0
18
+ Requires-Dist: caddforge-qm==0.3.0
19
+ Description-Content-Type: text/markdown
20
+
21
+ # CADDForge Toolbox
22
+
23
+ `caddforge` is a metadata-only distribution that installs the complete public CADDForge
24
+ toolbox. It contains no Python modules or commands: `caddforge-core` owns the
25
+ `caddforge` Python package and command line interface.
26
+
27
+ The first public-repository bundle release is `0.23.0`, continuing the version
28
+ sequence after the inherited `0.22.1` development baseline. The `0.x` series
29
+ remains initial development: the public API and supported component set may change. Version `1.0.0` is reserved for a future
30
+ stable API commitment. Bundle and component versions evolve independently.
31
+ The bundle includes the installed documentation viewer. These public sources
32
+ start fresh Git histories; earlier development tags are not included.
33
+
34
+ ## Installation
35
+
36
+ Once the reviewed public releases are published, install the public toolbox with:
37
+
38
+ ```bash
39
+ python -m pip install caddforge
40
+ python -m pip check
41
+ caddforge list-tools
42
+ caddforge docs
43
+ ```
44
+
45
+ This includes the core, data science, descriptors, docking, FEP, GUI, MD, ML, QM, and docs
46
+ distributions. GUI integrations, MD's `minimize` extra, and ML's `ui` extra are enabled
47
+ by default. The docs package ships the built site and enables `caddforge docs` without
48
+ documentation build tools or internet access. Test and documentation authoring extras
49
+ are not installed. The private
50
+ `caddforge-idorsia` plugin is excluded and remains a separate private installation.
51
+
52
+ For a smaller installation, install `caddforge-core` or an individual plugin:
53
+
54
+ ```bash
55
+ python -m pip install caddforge-core
56
+ python -m pip install caddforge-qm
57
+ ```
58
+
59
+ For documentation in a selective installation, add `caddforge-docs` separately.
60
+ Run `caddforge docs` to open the installed site; use `--host`, `--port`, or
61
+ `--no-browser` to configure the viewer.
62
+
63
+ All public plugin dependencies and user-facing extras are installed automatically.
64
+ Existing external scientific runtimes, licensed programs, GPU drivers, and Slurm
65
+ infrastructure remain separate prerequisites; this package does not install a
66
+ complete OpenFE/OpenFF/AmberTools environment. Install recommended conda-managed
67
+ runtimes before pip packages. Initial full-bundle validation targets Linux on Python
68
+ 3.10 and 3.12; other environments are not yet advertised as fully supported.
69
+
70
+ ## Migration from the old core distribution
71
+
72
+ Previously, `caddforge` installed only the core. Use a fresh environment whenever
73
+ possible. To migrate an existing environment, first remove that old distribution:
74
+
75
+ ```bash
76
+ python -m pip uninstall caddforge
77
+ python -m pip install --upgrade caddforge
78
+ python -m pip check
79
+ caddforge list-tools
80
+ ```
81
+
82
+ For a minimal installation, replace the install command with
83
+ `python -m pip install --upgrade caddforge-core` and upgrade each retained plugin to
84
+ its migrated release. Old plugin releases depend on the former `caddforge` core;
85
+ keep them in their original environments. Do not install renamed core alongside the
86
+ old core distribution: both own the same Python files. If that already happened,
87
+ uninstall the old distribution and reinstall `caddforge-core` with `--force-reinstall`.
88
+ Upgrade the private plugin separately if it is installed.
89
+
90
+ Python imports, commands, configuration files, job registries, results, and plugin
91
+ entry-point groups retain their existing names. Query the runtime version with
92
+ `importlib.metadata.version("caddforge-core")`; `version("caddforge")` now reports
93
+ the optional bundle version. MD provenance records both separately and historical
94
+ records remain readable. Uninstalling the new metadata-only bundle leaves core and
95
+ plugins installed; pip does not recursively remove dependencies.
96
+
97
+ ## Release set and local validation
98
+
99
+ The single source of truth for the component set is `project.dependencies` in
100
+ `pyproject.toml`. Bundle `0.23.1` pins these tagged public releases:
101
+
102
+ | Component | Version | Enabled extras |
103
+ | --- | --- | --- |
104
+ | Core | `0.22.0` | None |
105
+ | Data science | `0.5.0` | None |
106
+ | Descriptors | `0.11.0` | None |
107
+ | Docs | `0.3.0` | None |
108
+ | Docking | `0.7.0` | `gui` |
109
+ | FEP | `0.7.0` | `gui` |
110
+ | GUI | `0.6.0` | None |
111
+ | MD | `0.13.0` | `gui`, `minimize` |
112
+ | ML | `0.4.0` | `ui` |
113
+ | QM | `0.3.0` | None |
114
+
115
+ All ten component versions are published on public PyPI, checked on 2026-10-15.
116
+ Source tag `v0.23.1` identifies this bundle release; package-index publication
117
+ remains pending. Release publication requires metadata, ownership-migration,
118
+ and complete-installation checks. The documentation's version matrix records
119
+ source tags and package-index publication separately.
120
+
121
+ Patch `0.23.1` keeps the `0.23.0` component pins and addresses runner disk
122
+ exhaustion during the Python 3.10 full-install job, which prevented publication
123
+ of `0.23.0`. Full-install CI removes unused Android and .NET SDKs, disables pip
124
+ caching with explicit `--no-cache-dir` flags, and reports disk usage even when
125
+ installation fails. Dependencies and release validation gates remain unchanged.
126
+
127
+ Local `0.23.1` validation on 2026-10-15 passed all 32 installed-wheel packaging,
128
+ release-metadata, and ownership-migration tests on Python 3.10 and 3.12. The
129
+ unchanged component set previously passed clean public-PyPI installation checks
130
+ as bundle `0.23.0` on both Python versions: `pip check` and discovery of all 26
131
+ tools and three GUI extensions. Configuration templates, GUI assets, the installed documentation
132
+ viewer, and local workflow execution and result persistence passed. These checks
133
+ do not run external scientific engines or download model weights. The runner
134
+ storage fix must still pass the required full-install jobs on GitHub.
135
+
136
+ For sibling source checkouts, use a separate build environment:
137
+
138
+ ```bash
139
+ python -m pip install --upgrade build hatchling hatch-vcs packaging pytest twine 'tomli; python_version < "3.11"'
140
+ python -m pip install -r ../caddforge-docs/requirements.txt
141
+ python scripts/build_workspace.py --outdir /tmp/caddforge-candidates
142
+ python scripts/check_wheels.py /tmp/caddforge-candidates --complete
143
+ python -m twine check /tmp/caddforge-candidates/*
144
+ python scripts/run_ci_tests.py
145
+ ```
146
+
147
+ `build_workspace.py` overrides VCS versions only in its build subprocesses to
148
+ produce local candidates at the declared pins. It does not create release tags or
149
+ publish packages. Do not publish those local builds: release component artifacts
150
+ must be built from their corresponding new public tags, reviewed, and tested.
151
+ The public component tags now exist; use their published wheels when testing
152
+ public-index installation. The migration test builds a small synthetic legacy
153
+ distribution and the candidate bundle locally, then downloads the exact core
154
+ wheel pinned in `pyproject.toml` from public PyPI. It checks pip file ownership,
155
+ bundle uninstallation, CLI availability, and historical result loading without
156
+ requiring another repository, Git history, or version overrides. The test runner
157
+ installs that published core and its runtime dependencies before running the tests;
158
+ the migration check fails rather than skipping if its wheel cannot be downloaded.
159
+
160
+ After installing the bundle into a clean environment, run:
161
+
162
+ ```bash
163
+ python -m pip --isolated install --index-url https://pypi.org/simple --find-links /tmp/caddforge-candidates 'caddforge==0.23.1'
164
+ python -m pip check
165
+ python scripts/check_install.py
166
+ ```
167
+
168
+ For the bundle-only candidate, build with `python -m build` and install its wheel
169
+ without `--find-links` so all components resolve from public PyPI. Do not use
170
+ `--no-deps` to claim a complete installation passed.
171
+
172
+ ## Public release gates
173
+
174
+ The pinned QM and docking releases use the published maintained dependencies
175
+ `caddforge-opencosmors==0.0.1` and `caddforge-unidock-tools==1.1.3`, respectively,
176
+ replacing the previous Git URL requirements. The bundle pins the public component
177
+ releases containing these changes.
178
+ Scientific dependency availability and compatibility must pass a clean installation
179
+ without private indexes. PyOCL is now available publicly as `pyocl-idor`; the
180
+ pinned QM, descriptors, and docking releases require `pyocl-idor>=0.8.3`, while
181
+ Python imports remain `pyocl`. Its runtime requires Java 21 or newer; the affected
182
+ GitHub workflows provision Java 21. Install Java 21 or newer before running tool
183
+ discovery or scientific workflows; Python packages do not install the JVM.
184
+ Package metadata declares MIT and each package includes
185
+ the project license text. Review bundled third-party files under their own terms before release.
186
+
187
+ ```bash
188
+ python scripts/check_wheels.py /tmp/caddforge-candidates --complete --public
189
+ ```
190
+
191
+ This command checks the candidate wheels for public metadata and index-installable dependencies.
192
+ The complete installation smoke test also rejects private packages
193
+ and references to them in the installed dependency metadata.
194
+
195
+ GitHub Actions builds one wheel/source archive pair, tests its packaging on Python
196
+ 3.10 and 3.12, and runs the ownership migration against the pinned core wheel
197
+ from public PyPI. No cross-repository checkout or additional GitHub credentials
198
+ are required. Publish the pinned core version before running this job.
199
+ Manually dispatch `release.yml` with `full_install: true` for clean Linux resolution,
200
+ tool discovery, configuration templates, GUI assets, and installed documentation
201
+ checks. Pushed `v*` release tags always require that full installation job.
202
+
203
+ A pushed `v*` tag publishes the tested artifacts through PyPI Trusted Publishing.
204
+ Branch pushes, pull requests, and manual runs never publish. Before pushing
205
+ release tags, verify distribution ownership, choose a bundle version above
206
+ existing `caddforge` releases, complete the release checks, and configure the
207
+ Trusted Publisher for the repository, `release.yml` workflow, and `pypi`
208
+ GitHub environment. No `PYPI_PUBLISH_ENABLED` variable is required. Release
209
+ core first, then independent plugins and GUI, then docking/descriptors before
210
+ MD, and data-science before docs. Publish the bundle after all pinned components.
211
+ The bundle version is explicit in `pyproject.toml`; update it and its pins
212
+ before creating the matching annotated tag. No credentials are embedded.
213
+
214
+ ## Packaging references
215
+
216
+ - [Distribution names and Python import names](https://packaging.python.org/en/latest/discussions/distribution-package-vs-import-package/)
217
+ - [Hatch metadata-only wheel support](https://hatch.pypa.io/latest/plugins/builder/wheel/)
218
+ - [PyPI dependency restrictions](https://setuptools.pypa.io/en/stable/userguide/dependency_management.html)
219
+ - [PyPI Trusted Publishing](https://docs.pypi.org/trusted-publishers/using-a-publisher/)
@@ -0,0 +1,199 @@
1
+ # CADDForge Toolbox
2
+
3
+ `caddforge` is a metadata-only distribution that installs the complete public CADDForge
4
+ toolbox. It contains no Python modules or commands: `caddforge-core` owns the
5
+ `caddforge` Python package and command line interface.
6
+
7
+ The first public-repository bundle release is `0.23.0`, continuing the version
8
+ sequence after the inherited `0.22.1` development baseline. The `0.x` series
9
+ remains initial development: the public API and supported component set may change. Version `1.0.0` is reserved for a future
10
+ stable API commitment. Bundle and component versions evolve independently.
11
+ The bundle includes the installed documentation viewer. These public sources
12
+ start fresh Git histories; earlier development tags are not included.
13
+
14
+ ## Installation
15
+
16
+ Once the reviewed public releases are published, install the public toolbox with:
17
+
18
+ ```bash
19
+ python -m pip install caddforge
20
+ python -m pip check
21
+ caddforge list-tools
22
+ caddforge docs
23
+ ```
24
+
25
+ This includes the core, data science, descriptors, docking, FEP, GUI, MD, ML, QM, and docs
26
+ distributions. GUI integrations, MD's `minimize` extra, and ML's `ui` extra are enabled
27
+ by default. The docs package ships the built site and enables `caddforge docs` without
28
+ documentation build tools or internet access. Test and documentation authoring extras
29
+ are not installed. The private
30
+ `caddforge-idorsia` plugin is excluded and remains a separate private installation.
31
+
32
+ For a smaller installation, install `caddforge-core` or an individual plugin:
33
+
34
+ ```bash
35
+ python -m pip install caddforge-core
36
+ python -m pip install caddforge-qm
37
+ ```
38
+
39
+ For documentation in a selective installation, add `caddforge-docs` separately.
40
+ Run `caddforge docs` to open the installed site; use `--host`, `--port`, or
41
+ `--no-browser` to configure the viewer.
42
+
43
+ All public plugin dependencies and user-facing extras are installed automatically.
44
+ Existing external scientific runtimes, licensed programs, GPU drivers, and Slurm
45
+ infrastructure remain separate prerequisites; this package does not install a
46
+ complete OpenFE/OpenFF/AmberTools environment. Install recommended conda-managed
47
+ runtimes before pip packages. Initial full-bundle validation targets Linux on Python
48
+ 3.10 and 3.12; other environments are not yet advertised as fully supported.
49
+
50
+ ## Migration from the old core distribution
51
+
52
+ Previously, `caddforge` installed only the core. Use a fresh environment whenever
53
+ possible. To migrate an existing environment, first remove that old distribution:
54
+
55
+ ```bash
56
+ python -m pip uninstall caddforge
57
+ python -m pip install --upgrade caddforge
58
+ python -m pip check
59
+ caddforge list-tools
60
+ ```
61
+
62
+ For a minimal installation, replace the install command with
63
+ `python -m pip install --upgrade caddforge-core` and upgrade each retained plugin to
64
+ its migrated release. Old plugin releases depend on the former `caddforge` core;
65
+ keep them in their original environments. Do not install renamed core alongside the
66
+ old core distribution: both own the same Python files. If that already happened,
67
+ uninstall the old distribution and reinstall `caddforge-core` with `--force-reinstall`.
68
+ Upgrade the private plugin separately if it is installed.
69
+
70
+ Python imports, commands, configuration files, job registries, results, and plugin
71
+ entry-point groups retain their existing names. Query the runtime version with
72
+ `importlib.metadata.version("caddforge-core")`; `version("caddforge")` now reports
73
+ the optional bundle version. MD provenance records both separately and historical
74
+ records remain readable. Uninstalling the new metadata-only bundle leaves core and
75
+ plugins installed; pip does not recursively remove dependencies.
76
+
77
+ ## Release set and local validation
78
+
79
+ The single source of truth for the component set is `project.dependencies` in
80
+ `pyproject.toml`. Bundle `0.23.1` pins these tagged public releases:
81
+
82
+ | Component | Version | Enabled extras |
83
+ | --- | --- | --- |
84
+ | Core | `0.22.0` | None |
85
+ | Data science | `0.5.0` | None |
86
+ | Descriptors | `0.11.0` | None |
87
+ | Docs | `0.3.0` | None |
88
+ | Docking | `0.7.0` | `gui` |
89
+ | FEP | `0.7.0` | `gui` |
90
+ | GUI | `0.6.0` | None |
91
+ | MD | `0.13.0` | `gui`, `minimize` |
92
+ | ML | `0.4.0` | `ui` |
93
+ | QM | `0.3.0` | None |
94
+
95
+ All ten component versions are published on public PyPI, checked on 2026-10-15.
96
+ Source tag `v0.23.1` identifies this bundle release; package-index publication
97
+ remains pending. Release publication requires metadata, ownership-migration,
98
+ and complete-installation checks. The documentation's version matrix records
99
+ source tags and package-index publication separately.
100
+
101
+ Patch `0.23.1` keeps the `0.23.0` component pins and addresses runner disk
102
+ exhaustion during the Python 3.10 full-install job, which prevented publication
103
+ of `0.23.0`. Full-install CI removes unused Android and .NET SDKs, disables pip
104
+ caching with explicit `--no-cache-dir` flags, and reports disk usage even when
105
+ installation fails. Dependencies and release validation gates remain unchanged.
106
+
107
+ Local `0.23.1` validation on 2026-10-15 passed all 32 installed-wheel packaging,
108
+ release-metadata, and ownership-migration tests on Python 3.10 and 3.12. The
109
+ unchanged component set previously passed clean public-PyPI installation checks
110
+ as bundle `0.23.0` on both Python versions: `pip check` and discovery of all 26
111
+ tools and three GUI extensions. Configuration templates, GUI assets, the installed documentation
112
+ viewer, and local workflow execution and result persistence passed. These checks
113
+ do not run external scientific engines or download model weights. The runner
114
+ storage fix must still pass the required full-install jobs on GitHub.
115
+
116
+ For sibling source checkouts, use a separate build environment:
117
+
118
+ ```bash
119
+ python -m pip install --upgrade build hatchling hatch-vcs packaging pytest twine 'tomli; python_version < "3.11"'
120
+ python -m pip install -r ../caddforge-docs/requirements.txt
121
+ python scripts/build_workspace.py --outdir /tmp/caddforge-candidates
122
+ python scripts/check_wheels.py /tmp/caddforge-candidates --complete
123
+ python -m twine check /tmp/caddforge-candidates/*
124
+ python scripts/run_ci_tests.py
125
+ ```
126
+
127
+ `build_workspace.py` overrides VCS versions only in its build subprocesses to
128
+ produce local candidates at the declared pins. It does not create release tags or
129
+ publish packages. Do not publish those local builds: release component artifacts
130
+ must be built from their corresponding new public tags, reviewed, and tested.
131
+ The public component tags now exist; use their published wheels when testing
132
+ public-index installation. The migration test builds a small synthetic legacy
133
+ distribution and the candidate bundle locally, then downloads the exact core
134
+ wheel pinned in `pyproject.toml` from public PyPI. It checks pip file ownership,
135
+ bundle uninstallation, CLI availability, and historical result loading without
136
+ requiring another repository, Git history, or version overrides. The test runner
137
+ installs that published core and its runtime dependencies before running the tests;
138
+ the migration check fails rather than skipping if its wheel cannot be downloaded.
139
+
140
+ After installing the bundle into a clean environment, run:
141
+
142
+ ```bash
143
+ python -m pip --isolated install --index-url https://pypi.org/simple --find-links /tmp/caddforge-candidates 'caddforge==0.23.1'
144
+ python -m pip check
145
+ python scripts/check_install.py
146
+ ```
147
+
148
+ For the bundle-only candidate, build with `python -m build` and install its wheel
149
+ without `--find-links` so all components resolve from public PyPI. Do not use
150
+ `--no-deps` to claim a complete installation passed.
151
+
152
+ ## Public release gates
153
+
154
+ The pinned QM and docking releases use the published maintained dependencies
155
+ `caddforge-opencosmors==0.0.1` and `caddforge-unidock-tools==1.1.3`, respectively,
156
+ replacing the previous Git URL requirements. The bundle pins the public component
157
+ releases containing these changes.
158
+ Scientific dependency availability and compatibility must pass a clean installation
159
+ without private indexes. PyOCL is now available publicly as `pyocl-idor`; the
160
+ pinned QM, descriptors, and docking releases require `pyocl-idor>=0.8.3`, while
161
+ Python imports remain `pyocl`. Its runtime requires Java 21 or newer; the affected
162
+ GitHub workflows provision Java 21. Install Java 21 or newer before running tool
163
+ discovery or scientific workflows; Python packages do not install the JVM.
164
+ Package metadata declares MIT and each package includes
165
+ the project license text. Review bundled third-party files under their own terms before release.
166
+
167
+ ```bash
168
+ python scripts/check_wheels.py /tmp/caddforge-candidates --complete --public
169
+ ```
170
+
171
+ This command checks the candidate wheels for public metadata and index-installable dependencies.
172
+ The complete installation smoke test also rejects private packages
173
+ and references to them in the installed dependency metadata.
174
+
175
+ GitHub Actions builds one wheel/source archive pair, tests its packaging on Python
176
+ 3.10 and 3.12, and runs the ownership migration against the pinned core wheel
177
+ from public PyPI. No cross-repository checkout or additional GitHub credentials
178
+ are required. Publish the pinned core version before running this job.
179
+ Manually dispatch `release.yml` with `full_install: true` for clean Linux resolution,
180
+ tool discovery, configuration templates, GUI assets, and installed documentation
181
+ checks. Pushed `v*` release tags always require that full installation job.
182
+
183
+ A pushed `v*` tag publishes the tested artifacts through PyPI Trusted Publishing.
184
+ Branch pushes, pull requests, and manual runs never publish. Before pushing
185
+ release tags, verify distribution ownership, choose a bundle version above
186
+ existing `caddforge` releases, complete the release checks, and configure the
187
+ Trusted Publisher for the repository, `release.yml` workflow, and `pypi`
188
+ GitHub environment. No `PYPI_PUBLISH_ENABLED` variable is required. Release
189
+ core first, then independent plugins and GUI, then docking/descriptors before
190
+ MD, and data-science before docs. Publish the bundle after all pinned components.
191
+ The bundle version is explicit in `pyproject.toml`; update it and its pins
192
+ before creating the matching annotated tag. No credentials are embedded.
193
+
194
+ ## Packaging references
195
+
196
+ - [Distribution names and Python import names](https://packaging.python.org/en/latest/discussions/distribution-package-vs-import-package/)
197
+ - [Hatch metadata-only wheel support](https://hatch.pypa.io/latest/plugins/builder/wheel/)
198
+ - [PyPI dependency restrictions](https://setuptools.pypa.io/en/stable/userguide/dependency_management.html)
199
+ - [PyPI Trusted Publishing](https://docs.pypi.org/trusted-publishers/using-a-publisher/)
@@ -0,0 +1,45 @@
1
+ [build-system]
2
+ requires = ["hatchling>=1.26"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "caddforge"
7
+ version = "0.23.1"
8
+ description = "The complete public CADDForge toolbox: core, scientific plugins, GUI, and documentation."
9
+ readme = "README.md"
10
+ requires-python = ">=3.10"
11
+ authors = [
12
+ { name = "Manuel Sellner", email = "manuel.sellner@idorsia.com" },
13
+ { name = "Christoph Sager", email = "christoph.sager@idorsia.com" },
14
+ ]
15
+ license = { text = "MIT" }
16
+ dependencies = [
17
+ "caddforge-core==0.22.0",
18
+ "caddforge-datascience==0.5.0",
19
+ "caddforge-descriptors==0.11.0",
20
+ "caddforge-docs==0.3.0",
21
+ "caddforge-docking[gui]==0.7.0",
22
+ "caddforge-fep[gui]==0.7.0",
23
+ "caddforge-gui==0.6.0",
24
+ "caddforge-md[gui,minimize]==0.13.0",
25
+ "caddforge-ml[ui]==0.4.0",
26
+ "caddforge-qm==0.3.0",
27
+ ]
28
+
29
+ [dependency-groups]
30
+ dev = [
31
+ "build>=1.2",
32
+ "hatchling>=1.26",
33
+ "hatch-vcs>=0.5",
34
+ "packaging>=24",
35
+ "pytest>=8",
36
+ "twine>=7",
37
+ "tomli>=2; python_version < '3.11'",
38
+ ]
39
+
40
+ [tool.hatch.build.targets.wheel]
41
+ bypass-selection = true
42
+ exclude = ["**/*"]
43
+
44
+ [tool.hatch.build.targets.sdist]
45
+ include = ["/pyproject.toml", "/README.md", "/scripts", "/tests"]
@@ -0,0 +1,53 @@
1
+ """Build local migration candidates at the bundle's pinned component versions.
2
+
3
+ These version overrides are for local validation, not publication. Release builds
4
+ must obtain their versions from the corresponding repositories' release tags.
5
+ """
6
+
7
+ from __future__ import annotations
8
+
9
+ import argparse
10
+ import os
11
+ from pathlib import Path
12
+ import subprocess
13
+ import sys
14
+ try:
15
+ import tomllib
16
+ except ModuleNotFoundError: # Python 3.10
17
+ import tomli as tomllib
18
+
19
+ from packaging.requirements import Requirement
20
+
21
+
22
+ def main() -> None:
23
+ """Build public component wheels and sdists without installing them."""
24
+ parser = argparse.ArgumentParser(description=__doc__)
25
+ parser.add_argument("--workspace", type=Path, default=Path(__file__).resolve().parents[2])
26
+ parser.add_argument("--outdir", type=Path, required=True)
27
+ args = parser.parse_args()
28
+ bundle = Path(__file__).resolve().parents[1]
29
+ with (bundle / "pyproject.toml").open("rb") as stream:
30
+ project = tomllib.load(stream)["project"]
31
+ output = args.outdir.resolve()
32
+ if output.exists() and any(output.iterdir()):
33
+ parser.error("Use an empty output directory to avoid mixing release candidates.")
34
+ for dependency in project["dependencies"]:
35
+ requirement = Requirement(dependency)
36
+ version = next(iter(requirement.specifier)).version
37
+ source = args.workspace.resolve() / requirement.name
38
+ if not (source / "pyproject.toml").is_file():
39
+ parser.error(f"Missing component source: {source}")
40
+ env = os.environ.copy()
41
+ env["SETUPTOOLS_SCM_PRETEND_VERSION"] = version
42
+ subprocess.run(
43
+ [sys.executable, "-m", "build", "--no-isolation", "--outdir", str(output), str(source)],
44
+ env=env, check=True,
45
+ )
46
+ subprocess.run(
47
+ [sys.executable, "-m", "build", "--no-isolation", "--outdir", str(output), str(bundle)],
48
+ check=True,
49
+ )
50
+
51
+
52
+ if __name__ == "__main__":
53
+ main()
@@ -0,0 +1,118 @@
1
+ """Smoke-test the complete installed bundle without running external engines."""
2
+
3
+ from __future__ import annotations
4
+
5
+ from importlib import metadata, resources
6
+ from pathlib import Path
7
+ import subprocess
8
+ import sys
9
+ from tempfile import TemporaryDirectory
10
+ try:
11
+ import tomllib
12
+ except ModuleNotFoundError: # Python 3.10
13
+ import tomli as tomllib
14
+
15
+ from packaging.requirements import Requirement
16
+ from packaging.utils import canonicalize_name
17
+
18
+
19
+ def main() -> None:
20
+ """Check installed versions, tools, templates, GUI assets, and documentation."""
21
+ from caddforge.gui import discover_gui_extensions
22
+ from caddforge.plugins import discover_tools
23
+ import caddforge_gui.app # noqa: F401
24
+
25
+ with (Path(__file__).resolve().parents[1] / "pyproject.toml").open("rb") as stream:
26
+ project = tomllib.load(stream)["project"]
27
+ if metadata.version("caddforge") != project["version"]:
28
+ raise RuntimeError("Installed bundle differs from the release specification")
29
+ expected = set()
30
+ expected_gui = set()
31
+ for item in project["dependencies"]:
32
+ requirement = Requirement(item)
33
+ distribution = metadata.distribution(requirement.name)
34
+ if distribution.version not in requirement.specifier:
35
+ raise RuntimeError(f"Installed component does not match {requirement}")
36
+ for entry in distribution.entry_points:
37
+ if entry.group == "caddforge.tools":
38
+ plugin = entry.load()()
39
+ expected.add((plugin.section, plugin.name))
40
+ if entry.group == "caddforge.gui_extensions":
41
+ expected_gui.add(entry.load()().plugin_id)
42
+ for distribution in metadata.distributions():
43
+ name = canonicalize_name(distribution.metadata["Name"])
44
+ if name == "caddforge-idorsia":
45
+ raise RuntimeError("Private plugin found in the public installation environment")
46
+ for item in distribution.requires or []:
47
+ if canonicalize_name(Requirement(item).name) == "caddforge-idorsia":
48
+ raise RuntimeError(f"Private dependency found in installed {name}")
49
+ tools = discover_tools()
50
+ actual = {(section, name) for section, entries in tools.items() for name in entries}
51
+ if actual != expected:
52
+ raise RuntimeError(f"Tool discovery mismatch: expected {expected}, found {actual}")
53
+ subprocess.run(["caddforge", "--help"], check=True, stdout=subprocess.DEVNULL)
54
+ subprocess.run(["caddforge", "list-tools"], check=True)
55
+ for section, name in sorted(expected):
56
+ subprocess.run(["caddforge", "show-config", section, name], check=True, stdout=subprocess.DEVNULL)
57
+ actual_gui = {entry.plugin_id for entry in discover_gui_extensions()}
58
+ if actual_gui != expected_gui:
59
+ raise RuntimeError(f"GUI discovery mismatch: expected {expected_gui}, found {actual_gui}")
60
+ static = resources.files("caddforge_gui").joinpath("static")
61
+ if not static.joinpath("index.html").is_file():
62
+ raise RuntimeError("Installed GUI is missing its built frontend")
63
+ check_documentation()
64
+ check_local_workflow()
65
+ print(f"Validated {len(expected)} public tools, {len(expected_gui)} GUI extensions, and installed docs on {sys.version.split()[0]}.")
66
+
67
+
68
+ def check_documentation() -> None:
69
+ """Verify the installed viewer's command registration and packaged assets."""
70
+ entries = metadata.distribution("caddforge-docs").entry_points
71
+ if not any(
72
+ entry.group == "caddforge.cli_commands"
73
+ and entry.name == "docs"
74
+ and entry.value == "caddforge_docs.cli:docs"
75
+ for entry in entries
76
+ ):
77
+ raise RuntimeError("Installed docs do not register the caddforge docs command")
78
+ site = resources.files("caddforge_docs").joinpath("site")
79
+ if not site.joinpath("index.html").is_file() or not site.joinpath("search/search_index.json").is_file():
80
+ raise RuntimeError("Installed docs are missing the built site or search index")
81
+ subprocess.run(["caddforge", "docs", "--help"], check=True, stdout=subprocess.DEVNULL)
82
+
83
+
84
+ def check_local_workflow() -> None:
85
+ """Verify backend execution, registry persistence, and historical result loading."""
86
+ from datetime import datetime
87
+ from caddforge.config import BaseConfig
88
+ from caddforge.core import Job, JobStatus, Result, Workflow
89
+ from caddforge.core.execution import load_result_for_job, submit_workflow
90
+ from caddforge.core.job_registry import get_job
91
+ from caddforge.core.runtime_context import RuntimeContext
92
+
93
+ with TemporaryDirectory(prefix="caddforge-install-smoke-") as directory:
94
+ root = Path(directory)
95
+ config = BaseConfig(backend="local", run_directory=root / "runs", registry_path=root / "registry.sqlite")
96
+
97
+ class SmokeWorkflow(Workflow):
98
+ tool_name = "packaging-smoke"
99
+
100
+ def prepare_job(self) -> Job:
101
+ return Job(
102
+ id="packaging-smoke", tool_name=self.tool_name, backend="local",
103
+ run_directory=root / "runs", created_at=datetime.now().astimezone(),
104
+ )
105
+
106
+ def run(self, job: Job, context: RuntimeContext | None = None) -> Result:
107
+ return Result(job.id, self.tool_name, JobStatus.COMPLETED, metrics={"ran": 1})
108
+
109
+ job = submit_workflow(SmokeWorkflow(), config, backend_name="local")
110
+ result = load_result_for_job(job)
111
+ if result is None or result.status != JobStatus.COMPLETED or result.metrics.get("ran") != 1:
112
+ raise RuntimeError("Local smoke workflow failed to persist a completed result")
113
+ if get_job(job.id, registry_path=config.registry_path) is None:
114
+ raise RuntimeError("Local smoke workflow is missing from the job registry")
115
+
116
+
117
+ if __name__ == "__main__":
118
+ main()