diff --git a/.copier-answers.yml b/.copier-answers.yml deleted file mode 100644 index 715ad8ad7..000000000 --- a/.copier-answers.yml +++ /dev/null @@ -1,29 +0,0 @@ -_commit: v0.17.8 -_src_path: gh:helmut-hoffer-von-ankershoffen/oe-python-template -attestations_enabled: false -author_email: helmut@aignostics.com -author_github_username: helmut-hoffer-von-ankershoffen -author_name: Helmut Hoffer von Ankershoffen -codeql_enabled: true -docker_io_enabled: false -docker_io_image_name: aignostics-python-sdk -docker_io_owner: helmuthva -github_repository_name: python-sdk -github_repository_owner: aignostics -github_repository_url_https: https://github.com/aignostics/python-sdk -github_repository_url_ssh: git@github.com:aignostics/python-sdk.git -import_package_name: aignostics -org_email: support@aignostics.com -org_name: Aignostics GmbH -project_description: Python SDK providing access to Aignostics AI services. -project_icon: 🔬 -project_name: Aignostics Python SDK -pypi_distribution_name: aignostics -pypi_enabled: true -readthedocs_domain: readthedocs.org -readthedocs_project_key: aignostics -sonarqube_key: aignostics_python-sdk -streamlit_project_key: aignostics -uptime_badge_snippet: '[![Better Stack Badge](https://uptime.betterstack.com/status-badges/v1/monitor/1vtu1.svg)](https://aignostics.betteruptime.com/)' -vercel_badge_snippet: '' -vercel_function_enabled: false diff --git a/.github/CLAUDE.md b/.github/CLAUDE.md index d1d550b5b..18eec701f 100644 --- a/.github/CLAUDE.md +++ b/.github/CLAUDE.md @@ -141,7 +141,7 @@ than copying), `track_progress`, `use_sticky_comment`. Model is `claude-sonnet-4-5-20250929`. **Setup**: installs `uv`, dev tools (`_install_dev_tools.bash`), -`uv sync --all-extras --frozen`, headless display. Only secret available is +`uv sync --all-extras --locked`, headless display. Only secret available is `ANTHROPIC_API_KEY` — Claude Code workflows intentionally have **no** platform or GCP credentials. diff --git a/.github/workflows/_audit.yml b/.github/workflows/_audit.yml index b242c5e8c..b4e950b12 100644 --- a/.github/workflows/_audit.yml +++ b/.github/workflows/_audit.yml @@ -30,7 +30,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Audit shell: bash diff --git a/.github/workflows/_claude-code.yml b/.github/workflows/_claude-code.yml index f6f0edbb2..575dd0ac0 100644 --- a/.github/workflows/_claude-code.yml +++ b/.github/workflows/_claude-code.yml @@ -63,7 +63,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Setup display uses: pyvista/setup-headless-display-action@10e6efb97af3cd1523828f0e22c39f0e4567f3e4 # v5.2 @@ -72,7 +72,7 @@ jobs: if: ${{ !startsWith(github.ref, 'refs/tags/v') }} shell: bash run: | - TOML_VERSION=$(uv run --frozen python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") + TOML_VERSION=$(uv run --locked python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") echo "Development build - Current version in pyproject.toml: $TOML_VERSION" - name: Run Claude Code (Interactive Mode) diff --git a/.github/workflows/_docs.yml b/.github/workflows/_docs.yml index 923c7e296..64a1102f6 100644 --- a/.github/workflows/_docs.yml +++ b/.github/workflows/_docs.yml @@ -30,7 +30,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Docs shell: bash diff --git a/.github/workflows/_lint.yml b/.github/workflows/_lint.yml index e9fee2fc5..12651f2cd 100644 --- a/.github/workflows/_lint.yml +++ b/.github/workflows/_lint.yml @@ -30,7 +30,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Lint shell: bash diff --git a/.github/workflows/_package-publish.yml b/.github/workflows/_package-publish.yml index 15904ee70..184b1447c 100644 --- a/.github/workflows/_package-publish.yml +++ b/.github/workflows/_package-publish.yml @@ -61,12 +61,12 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Validate installation shell: bash run: | - OUTPUT=$(uv run --frozen --all-extras --no-dev aignostics --help) + OUTPUT=$(uv run --locked --all-extras --no-dev aignostics --help) if [[ "$OUTPUT" != *"built with love in Berlin"* ]]; then echo "Output does not contain 'built with love in Berlin'" exit 1 @@ -149,7 +149,7 @@ jobs: - name: Final smoke test shell: bash run: | - uv run --frozen --no-dev aignostics --help + uv run --locked --no-dev aignostics --help - name: Docs shell: bash diff --git a/.github/workflows/_scheduled-audit.yml b/.github/workflows/_scheduled-audit.yml index 4532c13d6..5fa88a901 100644 --- a/.github/workflows/_scheduled-audit.yml +++ b/.github/workflows/_scheduled-audit.yml @@ -31,7 +31,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Audit shell: bash diff --git a/.github/workflows/_scheduled-test-daily.yml b/.github/workflows/_scheduled-test-daily.yml index a3a6a543a..3796d79f6 100644 --- a/.github/workflows/_scheduled-test-daily.yml +++ b/.github/workflows/_scheduled-test-daily.yml @@ -66,7 +66,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy # Need xdisplay for testing QuPath app integration - name: Setup display @@ -76,7 +76,7 @@ jobs: if: ${{ !startsWith(github.ref, 'refs/tags/v') }} shell: bash run: | - TOML_VERSION=$(uv run --frozen python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") + TOML_VERSION=$(uv run --locked python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") echo "Development build - Current version in pyproject.toml: $TOML_VERSION" - name: Create .env file @@ -108,7 +108,7 @@ jobs: continue-on-error: true shell: bash run: | - OUTPUT=$(uv run --frozen --no-dev aignostics --help) + OUTPUT=$(uv run --locked --no-dev aignostics --help) if [[ "$OUTPUT" != *"built with love in Berlin"* ]]; then echo "Output does not contain 'built with love in Berlin'" exit 1 @@ -119,12 +119,12 @@ jobs: continue-on-error: true shell: bash run: | - uv run --frozen --no-dev aignostics --help - uv run --frozen --all-extras aignostics system info - uv run --frozen --all-extras aignostics system health - uv run --frozen --all-extras aignostics user whoami --mask-secrets - uv run --frozen --all-extras aignostics application list - uv run --frozen --all-extras aignostics application run list --verbose --limit 1 + uv run --locked --no-dev aignostics --help + uv run --locked --all-extras aignostics system info + uv run --locked --all-extras aignostics system health + uv run --locked --all-extras aignostics user whoami --mask-secrets + uv run --locked --all-extras aignostics application list + uv run --locked --all-extras aignostics application run list --verbose --limit 1 - name: Test / Unit (multiple Python versions) id: unit diff --git a/.github/workflows/_scheduled-test-hourly.yml b/.github/workflows/_scheduled-test-hourly.yml index c85fd7371..5022b1cab 100644 --- a/.github/workflows/_scheduled-test-hourly.yml +++ b/.github/workflows/_scheduled-test-hourly.yml @@ -64,7 +64,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Create .env file uses: SpicyPizza/create-envfile@ace6d4f5d7802b600276c23ca417e669f1a06f6f # v2.0.3 diff --git a/.github/workflows/_scheduled-test-stress.yml b/.github/workflows/_scheduled-test-stress.yml index f3152d329..61c7b133f 100644 --- a/.github/workflows/_scheduled-test-stress.yml +++ b/.github/workflows/_scheduled-test-stress.yml @@ -60,7 +60,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy - name: Create .env file uses: SpicyPizza/create-envfile@ace6d4f5d7802b600276c23ca417e669f1a06f6f # v2.0.3 diff --git a/.github/workflows/_test.yml b/.github/workflows/_test.yml index 615222146..97dc12dc6 100644 --- a/.github/workflows/_test.yml +++ b/.github/workflows/_test.yml @@ -91,7 +91,7 @@ jobs: - name: Install Python, venv and dependencies shell: bash - run: uv sync --all-extras --frozen --link-mode=copy + run: uv sync --all-extras --locked --link-mode=copy # Need xdisplay for testing QuPath app integration - name: Setup display @@ -102,7 +102,7 @@ jobs: shell: bash run: | TAG_VERSION=${GITHUB_REF#refs/tags/v} - TOML_VERSION=$(uv run --frozen python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") + TOML_VERSION=$(uv run --locked python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") if [ "$TAG_VERSION" != "$TOML_VERSION" ]; then echo "Release version mismatch: Tag $TAG_VERSION != pyproject.toml $TOML_VERSION" exit 1 @@ -112,7 +112,7 @@ jobs: if: ${{ !startsWith(github.ref, 'refs/tags/v') }} shell: bash run: | - TOML_VERSION=$(uv run --frozen python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") + TOML_VERSION=$(uv run --locked python -c "import tomli; print(tomli.load(open('pyproject.toml', 'rb'))['project']['version'])") echo "Development build - Current version in pyproject.toml: $TOML_VERSION" - name: Create .env file @@ -142,7 +142,7 @@ jobs: - name: Validate installation (single Python version) shell: bash run: | - OUTPUT=$(uv run --frozen --no-dev aignostics --help) + OUTPUT=$(uv run --locked --no-dev aignostics --help) if [[ "$OUTPUT" != *"built with love in Berlin"* ]]; then echo "Output does not contain 'built with love in Berlin'" exit 1 @@ -151,12 +151,12 @@ jobs: - name: Test / Smoke (single Python version) shell: bash run: | - uv run --frozen --no-dev aignostics --help - uv run --frozen --all-extras aignostics system info - uv run --frozen --all-extras aignostics system health - uv run --frozen --all-extras aignostics user whoami --mask-secrets - uv run --frozen --all-extras aignostics application list - uv run --frozen --all-extras aignostics application run list --verbose --limit 1 + uv run --locked --no-dev aignostics --help + uv run --locked --all-extras aignostics system info + uv run --locked --all-extras aignostics system health + uv run --locked --all-extras aignostics user whoami --mask-secrets + uv run --locked --all-extras aignostics application list + uv run --locked --all-extras aignostics application run list --verbose --limit 1 # All test steps use continue-on-error: true so that every test suite # always runs regardless of whether earlier suites failed. This ensures diff --git a/.github/workflows/prepare-release.yml b/.github/workflows/prepare-release.yml index f80b01150..76223d484 100644 --- a/.github/workflows/prepare-release.yml +++ b/.github/workflows/prepare-release.yml @@ -81,7 +81,7 @@ jobs: run: git checkout -b "${{ steps.version.outputs.branch_name }}" - name: Bump version - run: uv run --frozen bump-my-version bump --new-version "${{ steps.version.outputs.new_version }}" + run: uv run --locked bump-my-version bump --new-version "${{ steps.version.outputs.new_version }}" - name: Push release branch run: git push -u origin "${{ steps.version.outputs.branch_name }}" diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index 64bd15344..48810b4cb 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -82,7 +82,7 @@ jobs: cache-dependency-glob: uv.lock - name: Install dependencies - run: uv sync --frozen + run: uv sync --locked - name: Read version info id: version @@ -105,9 +105,9 @@ jobs: PREV_TAG="${{ steps.version.outputs.prev_tag }}" TAG_NAME="${{ steps.version.outputs.tag_name }}" if [ -n "$PREV_TAG" ]; then - uv run --frozen git-cliff --tag "$TAG_NAME" --prepend CHANGELOG.md "${PREV_TAG}..HEAD" + uv run --locked git-cliff --tag "$TAG_NAME" --prepend CHANGELOG.md "${PREV_TAG}..HEAD" else - uv run --frozen git-cliff --tag "$TAG_NAME" --output CHANGELOG.md + uv run --locked git-cliff --tag "$TAG_NAME" --output CHANGELOG.md fi - name: Commit changelog diff --git a/.readthedocs.yml b/.readthedocs.yml index bd1e8ebfb..559e2e94b 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -33,6 +33,6 @@ build: - asdf global uv latest - echo $READTHEDOCS_VIRTUALENV_PATH - . ${READTHEDOCS_VIRTUALENV_PATH}/bin/activate - - UV_PROJECT_ENVIRONMENT=$READTHEDOCS_VIRTUALENV_PATH uv sync --frozen --all-extras + - UV_PROJECT_ENVIRONMENT=$READTHEDOCS_VIRTUALENV_PATH uv sync --locked --all-extras post_install: - npm install -g --ignore-scripts @mermaid-js/mermaid-cli diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 667a012fb..6fccf01bb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -214,14 +214,6 @@ Notes: pinact run # See https://dev.to/suzukishunsuke/pin-github-actions-to-a-full-length-commit-sha-for-security-2n7p ``` -## Update from Template - -Update project to latest version of [oe-python-template](https://github.com/helmut-hoffer-von-ankershoffen/oe-python-template) template. - -```shell -make update_from_template -``` - ## Custom Metadata When submitting application runs to the Aignostics Platform, you can attach custom metadata to provide additional context, tracking information, or control flags. The SDK itself automatically attaches structured metadata to every run, which includes: diff --git a/Makefile b/Makefile index 0e8eca42b..c1a0f0e65 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,7 @@ $(error Python version validation failed. See error message above.) endif # Define all PHONY targets -.PHONY: act all audit clean codegen dist dist_native docs gui_watch install lint lint_fix merge-release pre_commit_run_all prepare-release profile publish-release setup test test_coverage_reset test_default test_e2e test_e2e_matrix test_integration test_integration_matrix test_long_running test_scheduled test_stress test_sequential test_unit test_unit_matrix test_very_long_running update_from_template +.PHONY: act all audit clean codegen dist dist_native docs gui_watch install lint lint_fix merge-release pre_commit_run_all prepare-release profile publish-release setup test test_coverage_reset test_default test_e2e test_e2e_matrix test_integration test_integration_matrix test_long_running test_scheduled test_stress test_sequential test_unit test_unit_matrix test_very_long_running # Main target i.e. default sessions defined in noxfile.py @@ -47,7 +47,7 @@ else \ fi ## Individual Nox sessions -act audit dist docs lint lint_fix setup test update_from_template: +act audit dist docs lint lint_fix setup test: $(nox-cmd) # Standalone targets @@ -247,6 +247,5 @@ help: @echo " test_sequential - Run tests marked as sequential (python version defined in .python-version)" @echo " test_scheduled - Run tests marked as scheduled (python version defined in .python-version)" @echo " test_coverage_reset - Reset test coverage data" - @echo " update_from_template - Update from template using copier" @echo "" @echo "Built with love in Berlin 🐻" diff --git a/install.bash b/install.bash index 4c0c9fc84..d82d80d74 100755 --- a/install.bash +++ b/install.bash @@ -68,7 +68,7 @@ LINUX_BREW_TOOLS=( ) UV_TOOLS=( - "copier;copier;https://copier.readthedocs.io/;local" + # uv tools will be added here ) PNPM_TOOLS=( diff --git a/noxfile.py b/noxfile.py index 79ab0e750..77a87918c 100644 --- a/noxfile.py +++ b/noxfile.py @@ -8,7 +8,6 @@ from pathlib import Path import nox -import tomli from nox.command import CommandFailed nox.options.reuse_existing_virtualenvs = True @@ -78,7 +77,7 @@ def _get_test_python_versions() -> list[str]: def _setup_venv(session: nox.Session, all_extras: bool = True, no_dev: bool = False) -> None: """Install dependencies for the given session using uv.""" - args = ["uv", "sync", "--frozen"] + args = ["uv", "sync", "--locked"] if all_extras: args.append("--all-extras") if no_dev: @@ -962,28 +961,6 @@ def setup(session: nox.Session) -> None: session.run("git", "add", ".", external=True) -@nox.session(default=False) -def update_from_template(session: nox.Session) -> None: - """Update from copier template.""" - if Path("copier.yaml").is_file() or Path("copier.yml").is_file(): - # Read the current version from pyproject.toml - with Path("pyproject.toml").open("rb") as f: - pyproject = tomli.load(f) - current_version = pyproject["tool"]["bumpversion"]["current_version"] - # In this case the project itself is the template - session.run("copier", "copy", "-r", "HEAD", ".", ".", "--force", "--trust", "--skip-tasks", external=True) - # Bump the version using the current version from pyproject.toml - session.run("bump-my-version", "replace", "--new-version", current_version, "--allow-dirty", external=True) - else: - # In this case the template has been generated from a template - session.run("copier", "update", "--trust", "--skip-answered", "--skip-tasks", external=True) - - # Schedule the lint session to run after this session completes - session.notify("audit") - session.notify("docs") - session.notify("lint") - - @nox.session(default=False) def act(session: nox.Session) -> None: """Run GitHub Actions workflow locally with act.""" diff --git a/renovate.json b/renovate.json index dbda4ffb4..9d6dd3d4c 100644 --- a/renovate.json +++ b/renovate.json @@ -107,12 +107,6 @@ // ---- Repo rules: they deviate from the org config ---- - // The template source uses the gh: form, which Renovate looks up as git-tags without release - // dates. The SDK takes no template updates, so the copier manager is off. - "copier": { - "enabled": false - }, - "lockFileMaintenance": { "enabled": true, "schedule": ["before 5am on monday"]