rhiza 0.9.0__tar.gz → 0.10.0__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.
- rhiza-0.10.0/.github/actions/configure-git-auth/README.md +74 -0
- rhiza-0.10.0/.github/actions/configure-git-auth/action.yml +20 -0
- rhiza-0.10.0/.github/workflows/rhiza_benchmarks.yml +87 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_book.yml +15 -7
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_ci.yml +46 -7
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_codeql.yml +7 -3
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_deptry.yml +8 -3
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_marimo.yml +12 -4
- rhiza-0.10.0/.github/workflows/rhiza_mypy.yml +39 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_pre-commit.yml +7 -2
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_release.yml +41 -37
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_security.yml +15 -2
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_sync.yml +15 -6
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/workflows/rhiza_validate.yml +11 -6
- {rhiza-0.9.0 → rhiza-0.10.0}/.gitignore +1 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.pre-commit-config.yaml +19 -20
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/.cfg.toml +1 -5
- rhiza-0.10.0/.rhiza/.rhiza-version +1 -0
- rhiza-0.10.0/.rhiza/assets/rhiza-logo.svg +81 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/docs/CONFIG.md +1 -0
- rhiza-0.10.0/.rhiza/docs/PRIVATE_PACKAGES.md +222 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/history +19 -14
- rhiza-0.9.0/tests/tests.mk → rhiza-0.10.0/.rhiza/make.d/01-test.mk +22 -13
- rhiza-0.9.0/book/book.mk → rhiza-0.10.0/.rhiza/make.d/02-book.mk +41 -44
- rhiza-0.9.0/book/marimo/marimo.mk → rhiza-0.10.0/.rhiza/make.d/03-marimo.mk +1 -1
- rhiza-0.9.0/.github/agents/agentic.mk → rhiza-0.10.0/.rhiza/make.d/06-agentic.mk +30 -1
- rhiza-0.10.0/.rhiza/make.d/07-docker.mk +31 -0
- rhiza-0.10.0/.rhiza/make.d/08-docs.mk +56 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/requirements/tests.txt +1 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/rhiza.mk +41 -16
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/scripts/release.sh +61 -20
- rhiza-0.10.0/.rhiza/template.yml +6 -0
- {rhiza-0.9.0/book/minibook-templates → rhiza-0.10.0/.rhiza/templates/minibook}/custom.html.jinja2 +2 -2
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/utils/version_matrix.py +41 -6
- {rhiza-0.9.0 → rhiza-0.10.0}/Makefile +4 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/PKG-INFO +2 -2
- {rhiza-0.9.0 → rhiza-0.10.0}/README.md +1 -1
- rhiza-0.10.0/pr-description.md +83 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/pyproject.toml +28 -1
- {rhiza-0.9.0 → rhiza-0.10.0}/renovate.json +1 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/ruff.toml +2 -1
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/__main__.py +1 -1
- rhiza-0.10.0/src/rhiza/bundle_resolver.py +78 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/cli.py +10 -10
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/__init__.py +5 -3
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/init.py +37 -10
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/materialize.py +110 -26
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/summarise.py +1 -1
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/validate.py +94 -9
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/welcome.py +1 -1
- rhiza-0.10.0/src/rhiza/models.py +312 -0
- rhiza-0.10.0/tests/test_bundle_resolver.py +364 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_commands/test_init.py +18 -19
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_commands/test_materialize.py +34 -7
- rhiza-0.10.0/tests/test_commands/test_materialize_bundles.py +207 -0
- rhiza-0.10.0/tests/test_commands/test_summarise.py +477 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_models.py +111 -0
- rhiza-0.10.0/tests/test_rhiza/__init__.py +5 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/conftest.py +60 -3
- rhiza-0.10.0/tests/test_rhiza/test_book.py +146 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_docstrings.py +34 -16
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_makefile.py +124 -36
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_makefile_api.py +6 -14
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_makefile_gh.py +9 -11
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_marimushka_target.py +14 -13
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_notebooks.py +3 -3
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_release_script.py +100 -0
- rhiza-0.10.0/tests/test_rhiza/test_rhiza_workflows.py +227 -0
- rhiza-0.10.0/tests/test_rhiza/test_version_matrix.py +264 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/uv.lock +188 -187
- rhiza-0.9.0/.github/workflows/rhiza_benchmarks.yml +0 -51
- rhiza-0.9.0/.rhiza/scripts/check_workflow_names.py +0 -73
- rhiza-0.9.0/.rhiza/template.yml +0 -23
- rhiza-0.9.0/book/README.md +0 -45
- rhiza-0.9.0/book/marimo/.gitkeep +0 -0
- rhiza-0.9.0/book/marimo/README.md +0 -142
- rhiza-0.9.0/book/pdoc-templates/module.html.jinja2 +0 -19
- rhiza-0.9.0/presentation/README.md +0 -325
- rhiza-0.9.0/src/rhiza/models.py +0 -119
- rhiza-0.9.0/tests/test_commands/test_summarise.py +0 -101
- rhiza-0.9.0/tests/test_rhiza/test_check_workflow_names.py +0 -115
- rhiza-0.9.0/tests/test_rhiza/test_version_matrix.py +0 -137
- {rhiza-0.9.0 → rhiza-0.10.0}/.editorconfig +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/ISSUE_TEMPLATE/assign_ui_implementation.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/agents/analyser.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/agents/summarise.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.github/copilot-instructions.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.python-version +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/.gitignore +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/docs/TOKEN_SETUP.md +0 -0
- /rhiza-0.9.0/.rhiza/make.d/01-custom-env.mk → /rhiza-0.10.0/.rhiza/make.d/00-custom-env.mk +0 -0
- /rhiza-0.9.0/presentation/presentation.mk → /rhiza-0.10.0/.rhiza/make.d/04-presentation.mk +0 -0
- /rhiza-0.9.0/.github/github.mk → /rhiza-0.10.0/.rhiza/make.d/05-github.mk +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/make.d/10-custom-task.mk +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/make.d/README.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/requirements/README.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/requirements/docs.txt +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/requirements/marimo.txt +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/.rhiza/requirements/tools.txt +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/CLI.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/CODE_OF_CONDUCT.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/CONTRIBUTING.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/GETTING_STARTED.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/LICENSE +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/USAGE.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/book/marimo/notebooks/rhiza.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/pytest.ini +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/__init__.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/_templates/basic/__init__.py.jinja2 +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/_templates/basic/main.py.jinja2 +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/_templates/basic/pyproject.toml.jinja2 +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/migrate.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/commands/uninstall.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/src/rhiza/subprocess_utils.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_cli_commands.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_commands/test_migrate.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_commands/test_uninstall.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_commands/test_validate.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_package.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/README.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/benchmarks/.gitignore +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/benchmarks/README.md +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/benchmarks/analyze_benchmarks.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_git_repo_fixture.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_readme.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_requirements_folder.py +0 -0
- {rhiza-0.9.0 → rhiza-0.10.0}/tests/test_rhiza/test_structure.py +0 -0
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# Configure Git Auth for Private Packages
|
|
2
|
+
|
|
3
|
+
This composite action configures git to use token authentication for private GitHub packages.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
Add this step before installing dependencies that include private GitHub packages:
|
|
8
|
+
|
|
9
|
+
```yaml
|
|
10
|
+
- name: Configure git auth for private packages
|
|
11
|
+
uses: ./.github/actions/configure-git-auth
|
|
12
|
+
with:
|
|
13
|
+
token: ${{ secrets.GH_PAT }}
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
The `GH_PAT` secret should be a Personal Access Token with `repo` scope.
|
|
17
|
+
|
|
18
|
+
## What It Does
|
|
19
|
+
|
|
20
|
+
This action runs:
|
|
21
|
+
|
|
22
|
+
```bash
|
|
23
|
+
git config --global url."https://<token>@github.com/".insteadOf "https://github.com/"
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
This tells git to automatically inject the token into all HTTPS GitHub URLs, enabling access to private repositories.
|
|
27
|
+
|
|
28
|
+
## When to Use
|
|
29
|
+
|
|
30
|
+
Use this action when your project has dependencies defined in `pyproject.toml` like:
|
|
31
|
+
|
|
32
|
+
```toml
|
|
33
|
+
[tool.uv.sources]
|
|
34
|
+
private-package = { git = "https://github.com/your-org/private-package.git", rev = "v1.0.0" }
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Token Requirements
|
|
38
|
+
|
|
39
|
+
The default `GITHUB_TOKEN` does **not** have access to other private repositories, even within the same organization. You must use a Personal Access Token (PAT) with `repo` scope stored as `secrets.GH_PAT`.
|
|
40
|
+
|
|
41
|
+
If `secrets.GH_PAT` is not defined, GitHub Actions passes an empty string. The action will still run successfully, but any subsequent step that tries to access private repositories will fail with an authentication error.
|
|
42
|
+
|
|
43
|
+
## Example Workflow
|
|
44
|
+
|
|
45
|
+
```yaml
|
|
46
|
+
name: CI
|
|
47
|
+
|
|
48
|
+
on: [push, pull_request]
|
|
49
|
+
|
|
50
|
+
jobs:
|
|
51
|
+
test:
|
|
52
|
+
runs-on: ubuntu-latest
|
|
53
|
+
steps:
|
|
54
|
+
- uses: actions/checkout@v6
|
|
55
|
+
|
|
56
|
+
- name: Install uv
|
|
57
|
+
uses: astral-sh/setup-uv@v7
|
|
58
|
+
|
|
59
|
+
- name: Configure git auth for private packages
|
|
60
|
+
uses: ./.github/actions/configure-git-auth
|
|
61
|
+
with:
|
|
62
|
+
token: ${{ secrets.GH_PAT }}
|
|
63
|
+
|
|
64
|
+
- name: Install dependencies
|
|
65
|
+
run: uv sync --frozen
|
|
66
|
+
|
|
67
|
+
- name: Run tests
|
|
68
|
+
run: uv run pytest
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
## See Also
|
|
72
|
+
|
|
73
|
+
- [PRIVATE_PACKAGES.md](../../../.rhiza/docs/PRIVATE_PACKAGES.md) - Complete guide to using private packages
|
|
74
|
+
- [TOKEN_SETUP.md](../../../.rhiza/docs/TOKEN_SETUP.md) - Setting up Personal Access Tokens
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
name: 'Configure Git Auth for Private Packages'
|
|
2
|
+
description: 'Configure git to use token authentication for private GitHub packages'
|
|
3
|
+
|
|
4
|
+
inputs:
|
|
5
|
+
token:
|
|
6
|
+
description: 'GitHub token to use for authentication (use github.token)'
|
|
7
|
+
required: false
|
|
8
|
+
default: ${{ github.token }}
|
|
9
|
+
|
|
10
|
+
runs:
|
|
11
|
+
using: composite
|
|
12
|
+
steps:
|
|
13
|
+
- name: Configure git authentication
|
|
14
|
+
shell: bash
|
|
15
|
+
run: |
|
|
16
|
+
# Configure git to use token authentication for GitHub URLs
|
|
17
|
+
# This allows uv/pip to install private packages from GitHub
|
|
18
|
+
git config --global url."https://${{ inputs.token }}@github.com/".insteadOf "https://github.com/"
|
|
19
|
+
|
|
20
|
+
echo "✓ Git configured to use token authentication for GitHub"
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# This file is part of the jebel-quant/rhiza repository
|
|
2
|
+
# (https://github.com/jebel-quant/rhiza).
|
|
3
|
+
#
|
|
4
|
+
# Workflow: Performance Benchmarks
|
|
5
|
+
#
|
|
6
|
+
# Purpose: Run performance benchmarks and detect regressions.
|
|
7
|
+
#
|
|
8
|
+
# Trigger: On push to main/master branches, PRs, and manual trigger.
|
|
9
|
+
#
|
|
10
|
+
# Regression Detection:
|
|
11
|
+
# - Compares against previous benchmark results stored in gh-pages branch
|
|
12
|
+
# - Alerts if performance degrades by more than 150% (configurable)
|
|
13
|
+
# - PRs will show a warning comment but not fail
|
|
14
|
+
# - Main branch updates the baseline for future comparisons
|
|
15
|
+
|
|
16
|
+
name: "(RHIZA) BENCHMARKS"
|
|
17
|
+
|
|
18
|
+
permissions:
|
|
19
|
+
contents: write
|
|
20
|
+
pull-requests: write
|
|
21
|
+
|
|
22
|
+
on:
|
|
23
|
+
push:
|
|
24
|
+
branches: [ main, master ]
|
|
25
|
+
pull_request:
|
|
26
|
+
branches: [ main, master ]
|
|
27
|
+
workflow_dispatch:
|
|
28
|
+
|
|
29
|
+
jobs:
|
|
30
|
+
benchmark:
|
|
31
|
+
runs-on: ubuntu-latest
|
|
32
|
+
|
|
33
|
+
steps:
|
|
34
|
+
- name: Checkout repository
|
|
35
|
+
uses: actions/checkout@v6.0.2
|
|
36
|
+
with:
|
|
37
|
+
lfs: true
|
|
38
|
+
|
|
39
|
+
- name: Install uv
|
|
40
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
41
|
+
with:
|
|
42
|
+
version: "0.9.30"
|
|
43
|
+
|
|
44
|
+
- name: Configure git auth for private packages
|
|
45
|
+
uses: ./.github/actions/configure-git-auth
|
|
46
|
+
with:
|
|
47
|
+
token: ${{ secrets.GH_PAT }}
|
|
48
|
+
|
|
49
|
+
- name: Run benchmarks
|
|
50
|
+
env:
|
|
51
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
52
|
+
run: |
|
|
53
|
+
make benchmark
|
|
54
|
+
|
|
55
|
+
- name: Upload benchmark results
|
|
56
|
+
uses: actions/upload-artifact@v6.0.0
|
|
57
|
+
if: always()
|
|
58
|
+
with:
|
|
59
|
+
name: benchmark-results
|
|
60
|
+
path: |
|
|
61
|
+
_benchmarks/benchmarks.json
|
|
62
|
+
_benchmarks/benchmarks.svg
|
|
63
|
+
_benchmarks/benchmarks.html
|
|
64
|
+
|
|
65
|
+
# Regression detection using github-action-benchmark
|
|
66
|
+
# Stores benchmark history in gh-pages branch under /benchmarks
|
|
67
|
+
# Alerts if performance degrades by more than 150% of baseline
|
|
68
|
+
- name: Store benchmark result and check for regression
|
|
69
|
+
uses: benchmark-action/github-action-benchmark@v1
|
|
70
|
+
# run this only if _benchmarks/benchmarks.json exists
|
|
71
|
+
if: hashFiles('_benchmarks/benchmarks.json') != ''
|
|
72
|
+
with:
|
|
73
|
+
tool: 'pytest'
|
|
74
|
+
output-file-path: _benchmarks/benchmarks.json
|
|
75
|
+
# Store benchmark data in gh-pages branch
|
|
76
|
+
gh-pages-branch: gh-pages
|
|
77
|
+
benchmark-data-dir-path: benchmarks
|
|
78
|
+
# Only update baseline on main branch push (not PRs)
|
|
79
|
+
auto-push: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
|
|
80
|
+
# Alert if performance degrades by more than 150%
|
|
81
|
+
alert-threshold: '150%'
|
|
82
|
+
# Post comment on PR if regression detected
|
|
83
|
+
comment-on-alert: ${{ github.event_name == 'pull_request' }}
|
|
84
|
+
# Fail workflow if regression detected (disabled for PRs to allow investigation)
|
|
85
|
+
fail-on-alert: ${{ github.event_name == 'push' }}
|
|
86
|
+
# GitHub token for pushing to gh-pages and commenting
|
|
87
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
@@ -36,30 +36,38 @@ jobs:
|
|
|
36
36
|
|
|
37
37
|
steps:
|
|
38
38
|
# Check out the repository code
|
|
39
|
-
- uses: actions/checkout@v6
|
|
39
|
+
- uses: actions/checkout@v6.0.2
|
|
40
40
|
with:
|
|
41
41
|
lfs: true
|
|
42
42
|
|
|
43
43
|
- name: Install uv
|
|
44
|
-
uses: astral-sh/setup-uv@v7
|
|
44
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
45
45
|
with:
|
|
46
|
-
version: "0.9.
|
|
46
|
+
version: "0.9.30"
|
|
47
|
+
|
|
48
|
+
- name: Configure git auth for private packages
|
|
49
|
+
uses: ./.github/actions/configure-git-auth
|
|
50
|
+
with:
|
|
51
|
+
token: ${{ secrets.GH_PAT }}
|
|
47
52
|
|
|
48
53
|
- name: "Sync the virtual environment for ${{ github.repository }}"
|
|
49
54
|
shell: bash
|
|
55
|
+
env:
|
|
56
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
50
57
|
run: |
|
|
51
|
-
export UV_EXTRA_INDEX_URL="${{ secrets.uv-extra-index-url }}"
|
|
52
58
|
# will just use .python-version?
|
|
53
59
|
uv sync --all-extras --all-groups --frozen
|
|
54
60
|
|
|
55
61
|
- name: "Make the book"
|
|
62
|
+
env:
|
|
63
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
56
64
|
run: |
|
|
57
|
-
make
|
|
65
|
+
make book
|
|
58
66
|
|
|
59
67
|
# Step 5: Package all artifacts for GitHub Pages deployment
|
|
60
68
|
# This prepares the combined outputs for deployment by creating a single artifact
|
|
61
69
|
- name: Upload static files as artifact
|
|
62
|
-
uses: actions/upload-pages-artifact@v4 # Official GitHub Pages artifact upload action
|
|
70
|
+
uses: actions/upload-pages-artifact@v4.0.0 # Official GitHub Pages artifact upload action
|
|
63
71
|
with:
|
|
64
72
|
path: _book/ # Path to the directory containing all artifacts to deploy
|
|
65
73
|
|
|
@@ -70,5 +78,5 @@ jobs:
|
|
|
70
78
|
# If PUBLISH_COMPANION_BOOK is not set, it defaults to allowing deployment
|
|
71
79
|
- name: Deploy to GitHub Pages
|
|
72
80
|
if: ${{ !github.event.repository.fork && (vars.PUBLISH_COMPANION_BOOK == 'true' || vars.PUBLISH_COMPANION_BOOK == '') }}
|
|
73
|
-
uses: actions/deploy-pages@v4 # Official GitHub Pages deployment action
|
|
81
|
+
uses: actions/deploy-pages@v4.0.5 # Official GitHub Pages deployment action
|
|
74
82
|
continue-on-error: true
|
|
@@ -24,14 +24,23 @@ jobs:
|
|
|
24
24
|
outputs:
|
|
25
25
|
matrix: ${{ steps.versions.outputs.list }}
|
|
26
26
|
steps:
|
|
27
|
-
- uses: actions/checkout@v6
|
|
27
|
+
- uses: actions/checkout@v6.0.2
|
|
28
|
+
with:
|
|
29
|
+
lfs: true
|
|
28
30
|
|
|
29
31
|
- name: Install uv
|
|
30
|
-
uses: astral-sh/setup-uv@v7
|
|
32
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
31
33
|
with:
|
|
32
|
-
version: "0.9.
|
|
34
|
+
version: "0.9.30"
|
|
33
35
|
|
|
36
|
+
- name: Configure git auth for private packages
|
|
37
|
+
uses: ./.github/actions/configure-git-auth
|
|
38
|
+
with:
|
|
39
|
+
token: ${{ secrets.GH_PAT }}
|
|
40
|
+
|
|
34
41
|
- id: versions
|
|
42
|
+
env:
|
|
43
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
35
44
|
run: |
|
|
36
45
|
# Generate Python versions JSON from the script
|
|
37
46
|
JSON=$(make -f .rhiza/rhiza.mk -s version-matrix)
|
|
@@ -51,16 +60,46 @@ jobs:
|
|
|
51
60
|
|
|
52
61
|
steps:
|
|
53
62
|
- name: Checkout repository
|
|
54
|
-
uses: actions/checkout@v6
|
|
63
|
+
uses: actions/checkout@v6.0.2
|
|
55
64
|
with:
|
|
56
65
|
lfs: true
|
|
57
66
|
|
|
58
67
|
- name: Install uv
|
|
59
|
-
uses: astral-sh/setup-uv@v7
|
|
68
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
60
69
|
with:
|
|
61
|
-
version: "0.9.
|
|
70
|
+
version: "0.9.30"
|
|
62
71
|
python-version: ${{ matrix.python-version }}
|
|
63
72
|
|
|
73
|
+
- name: Configure git auth for private packages
|
|
74
|
+
uses: ./.github/actions/configure-git-auth
|
|
75
|
+
with:
|
|
76
|
+
token: ${{ secrets.GH_PAT }}
|
|
77
|
+
|
|
64
78
|
- name: Run tests
|
|
79
|
+
env:
|
|
80
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
81
|
+
run: |
|
|
82
|
+
make test
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
docs-coverage:
|
|
86
|
+
runs-on: ubuntu-latest
|
|
87
|
+
steps:
|
|
88
|
+
- name: Checkout repository
|
|
89
|
+
uses: actions/checkout@v6.0.2
|
|
90
|
+
|
|
91
|
+
- name: Install uv
|
|
92
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
93
|
+
with:
|
|
94
|
+
version: "0.9.30"
|
|
95
|
+
|
|
96
|
+
- name: Configure git auth for private packages
|
|
97
|
+
uses: ./.github/actions/configure-git-auth
|
|
98
|
+
with:
|
|
99
|
+
token: ${{ secrets.GH_PAT }}
|
|
100
|
+
|
|
101
|
+
- name: Check docs coverage
|
|
102
|
+
env:
|
|
103
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
65
104
|
run: |
|
|
66
|
-
make -
|
|
105
|
+
make docs-coverage
|
|
@@ -81,8 +81,12 @@ jobs:
|
|
|
81
81
|
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
|
|
82
82
|
steps:
|
|
83
83
|
- name: Checkout repository
|
|
84
|
-
uses: actions/checkout@v6
|
|
84
|
+
uses: actions/checkout@v6.0.2
|
|
85
85
|
|
|
86
|
+
- name: Configure git auth for private packages
|
|
87
|
+
uses: ./.github/actions/configure-git-auth
|
|
88
|
+
with:
|
|
89
|
+
token: ${{ secrets.GH_PAT }}
|
|
86
90
|
# Add any setup steps before running the `github/codeql-action/init` action.
|
|
87
91
|
# This includes steps like installing compilers or runtimes (`actions/setup-node`
|
|
88
92
|
# or others). This is typically only required for manual builds.
|
|
@@ -91,7 +95,7 @@ jobs:
|
|
|
91
95
|
|
|
92
96
|
# Initializes the CodeQL tools for scanning.
|
|
93
97
|
- name: Initialize CodeQL
|
|
94
|
-
uses: github/codeql-action/init@v4
|
|
98
|
+
uses: github/codeql-action/init@v4.32.1
|
|
95
99
|
with:
|
|
96
100
|
languages: ${{ matrix.language }}
|
|
97
101
|
build-mode: ${{ matrix.build-mode }}
|
|
@@ -120,6 +124,6 @@ jobs:
|
|
|
120
124
|
exit 1
|
|
121
125
|
|
|
122
126
|
- name: Perform CodeQL Analysis
|
|
123
|
-
uses: github/codeql-action/analyze@v4
|
|
127
|
+
uses: github/codeql-action/analyze@v4.32.1
|
|
124
128
|
with:
|
|
125
129
|
category: "/language:${{matrix.language}}"
|
|
@@ -27,13 +27,18 @@ jobs:
|
|
|
27
27
|
name: Check dependencies with deptry
|
|
28
28
|
runs-on: ubuntu-latest
|
|
29
29
|
container:
|
|
30
|
-
image: ghcr.io/astral-sh/uv:0.9.
|
|
30
|
+
image: ghcr.io/astral-sh/uv:0.9.30-bookworm
|
|
31
31
|
|
|
32
32
|
steps:
|
|
33
|
-
- uses: actions/checkout@v6
|
|
33
|
+
- uses: actions/checkout@v6.0.2
|
|
34
|
+
|
|
35
|
+
- name: Configure git auth for private packages
|
|
36
|
+
uses: ./.github/actions/configure-git-auth
|
|
37
|
+
with:
|
|
38
|
+
token: ${{ secrets.GH_PAT }}
|
|
34
39
|
|
|
35
40
|
- name: Run deptry
|
|
36
|
-
run: make
|
|
41
|
+
run: make deptry
|
|
37
42
|
# NOTE: make deptry is good style because it encapsulates the folders to check
|
|
38
43
|
# (e.g. src and book/marimo) and keeps CI in sync with local development.
|
|
39
44
|
# Since we use a 'uv' container, the Makefile is optimised to use the
|
|
@@ -34,13 +34,14 @@ jobs:
|
|
|
34
34
|
notebook-list: ${{ steps.notebooks.outputs.matrix }}
|
|
35
35
|
steps:
|
|
36
36
|
# Check out the repository code
|
|
37
|
-
- uses: actions/checkout@v6
|
|
37
|
+
- uses: actions/checkout@v6.0.2
|
|
38
38
|
|
|
39
39
|
# Find all Python files in the marimo folder and create a matrix for parallel execution
|
|
40
40
|
- name: Find notebooks and build matrix
|
|
41
41
|
id: notebooks
|
|
42
42
|
run: |
|
|
43
43
|
# Extract MARIMO_FOLDER from the project configuration (via Makefile)
|
|
44
|
+
# shellcheck disable=SC2016 # Single quotes intentional - Make syntax, not shell expansion
|
|
44
45
|
NOTEBOOK_DIR=$(make -s -f Makefile -f - <<< 'print: ; @echo $(or $(MARIMO_FOLDER),marimo)' print)
|
|
45
46
|
|
|
46
47
|
echo "Searching notebooks in: $NOTEBOOK_DIR"
|
|
@@ -74,18 +75,25 @@ jobs:
|
|
|
74
75
|
name: Run notebook ${{ matrix.notebook }}
|
|
75
76
|
steps:
|
|
76
77
|
# Check out the repository code
|
|
77
|
-
- uses: actions/checkout@v6
|
|
78
|
+
- uses: actions/checkout@v6.0.2
|
|
78
79
|
with:
|
|
79
80
|
lfs: true
|
|
80
81
|
|
|
81
82
|
# Install uv/uvx
|
|
82
83
|
- name: Install uv
|
|
83
|
-
uses: astral-sh/setup-uv@v7
|
|
84
|
+
uses: astral-sh/setup-uv@v7.2.1
|
|
84
85
|
with:
|
|
85
|
-
version: "0.9.
|
|
86
|
+
version: "0.9.30"
|
|
87
|
+
|
|
88
|
+
- name: Configure git auth for private packages
|
|
89
|
+
uses: ./.github/actions/configure-git-auth
|
|
90
|
+
with:
|
|
91
|
+
token: ${{ secrets.GH_PAT }}
|
|
86
92
|
|
|
87
93
|
# Execute the notebook with the appropriate runner based on its content
|
|
88
94
|
- name: Run notebook
|
|
95
|
+
env:
|
|
96
|
+
UV_EXTRA_INDEX_URL: ${{ secrets.UV_EXTRA_INDEX_URL }}
|
|
89
97
|
run: |
|
|
90
98
|
uvx uv run "${{ matrix.notebook }}"
|
|
91
99
|
# uvx → creates a fresh ephemeral environment
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# This file is part of the jebel-quant/rhiza repository
|
|
2
|
+
# (https://github.com/jebel-quant/rhiza).
|
|
3
|
+
#
|
|
4
|
+
# Workflow: Mypy
|
|
5
|
+
#
|
|
6
|
+
# Purpose: Run static type checking with mypy in strict mode to ensure
|
|
7
|
+
# type safety across the codebase.
|
|
8
|
+
#
|
|
9
|
+
# Trigger: On push and pull requests to main/master branches.
|
|
10
|
+
|
|
11
|
+
name: "(RHIZA) MYPY"
|
|
12
|
+
|
|
13
|
+
permissions:
|
|
14
|
+
contents: read
|
|
15
|
+
|
|
16
|
+
on:
|
|
17
|
+
push:
|
|
18
|
+
branches: [ main, master ]
|
|
19
|
+
pull_request:
|
|
20
|
+
branches: [ main, master ]
|
|
21
|
+
|
|
22
|
+
jobs:
|
|
23
|
+
mypy:
|
|
24
|
+
name: Static type checking with mypy
|
|
25
|
+
runs-on: ubuntu-latest
|
|
26
|
+
container:
|
|
27
|
+
image: ghcr.io/astral-sh/uv:0.9.30-bookworm
|
|
28
|
+
|
|
29
|
+
steps:
|
|
30
|
+
- uses: actions/checkout@v6
|
|
31
|
+
|
|
32
|
+
- name: Configure git auth for private packages
|
|
33
|
+
uses: ./.github/actions/configure-git-auth
|
|
34
|
+
with:
|
|
35
|
+
token: ${{ secrets.GH_PAT }}
|
|
36
|
+
|
|
37
|
+
# to brutal for now
|
|
38
|
+
# - name: Run mypy
|
|
39
|
+
# run: make -f .rhiza/rhiza.mk mypy
|
|
@@ -29,9 +29,14 @@ jobs:
|
|
|
29
29
|
runs-on: ubuntu-latest
|
|
30
30
|
|
|
31
31
|
steps:
|
|
32
|
-
- uses: actions/checkout@v6
|
|
32
|
+
- uses: actions/checkout@v6.0.2
|
|
33
|
+
|
|
34
|
+
- name: Configure git auth for private packages
|
|
35
|
+
uses: ./.github/actions/configure-git-auth
|
|
36
|
+
with:
|
|
37
|
+
token: ${{ secrets.GH_PAT }}
|
|
33
38
|
|
|
34
39
|
# Run pre-commit
|
|
35
40
|
- name: Run pre-commit
|
|
36
41
|
run: |
|
|
37
|
-
make
|
|
42
|
+
make fmt
|