Skip to content

chore: update rhiza to v1.1.3#15

Open
tschm wants to merge 4 commits into
masterfrom
rhiza_v1.1.3
Open

chore: update rhiza to v1.1.3#15
tschm wants to merge 4 commits into
masterfrom
rhiza_v1.1.3

Conversation

@tschm

@tschm tschm commented Jul 11, 2026

Copy link
Copy Markdown
Owner

Summary

  • Bumps the template ref to v1.1.3 in .rhiza/template.yml (was v1.1.1)
  • Platform profile: github-project (unchanged — origin is on github.com, already matched)
  • Runs make sync to apply upstream template changes; sync applied cleanly (no conflicts, no .rej files)
  • .rhiza/.rhiza-version (tool version 0.17.6) left untouched

Quality gates

Gate Result
make fmt (lint/format) ❌ FAIL — 31 ruff errors
make typecheck ❌ FAIL — ty clean; mypy --strict 59 errors in 5 files
make docs-coverage ✅ PASS — 100%
make deptry ✅ PASS
make security (pip-audit + bandit) ✅ PASS
make validate ✅ PASS
make test ❌ FAIL — 1 failed / 142 passed; coverage 99.80% (≥ 90% gate)

Note: make validate ran only .rhiza/tests (32 passed / 2 skipped), not the full pytest suite — no double-run of the test session observed.

Scorecard (locally-owned scope: src/, tests/, demo.py)

Subcategory Score Justification To raise
Docstring / API-doc coverage 10 interrogate 100% over src/tests
Dependency & security hygiene 10 deptry clean; pip-audit + bandit clean
Template fidelity 10 make validate passes; ref valid at v1.1.3
Test coverage & depth 9 99.80% total; 1 uncovered line in interface.py Cover the last branch → 100%
Overall architecture 7 Clean data→core→api layering, but a latent core→api cycle broken by a function-local import (core/server.py:201) Invert the router dependency
Test pass rate 7 142/143; the one failure is order-dependent, not a logic bug Fix global-state leak
Code complexity 6 Avg CC A (3.6), all MI=A, but two E-rank blocks (plot CC 32, validate_input CC 31) Extract helpers, both < CC 11
Test design quality 6 Suite hides a shared-mutable-global (_active_server) with no reset fixture → xdist-order-dependent flakiness Autouse reset fixture
Linting / style 4 31 ruff errors (missing annotations, open shadowing, blind except, unused arg) Clear all ruff errors
Type safety 3 59 mypy --strict errors (untyped defs, bare generics, Any returns, missing pandas stubs) Annotate + parametrize generics

Overall: 6 / 10.

Highest-leverage improvement: most of the 31 lint errors and 59 mypy errors are the same missing type annotations. One annotation pass across the 5 src/ modules (add return/param types, parametrize bare list/dict, add pandas-stubs) clears both the linting and type-safety failures at once — moving two subcategories from 3–4 up toward 10 and flipping two red gates green.

Recommendations (ordered by leverage)

  1. Type safety 3→10 — resolve 59 mypy --strict errors (make typecheck green).
  2. Linting 4→10 — clear 31 ruff errors (make fmt green).
  3. Test pass/design 6→10 — reset _active_server between tests to kill the xdist-order flake.
  4. Code complexity 6→10 — refactor plot (CC 32) and validate_input (CC 31) below CC 11.
  5. Architecture 7→10 — remove the latent core/server.pyapi.routes upward import.
  6. Coverage 9→10 — cover the last line in api/interface.py.

Copilot AI review requested due to automatic review settings July 11, 2026 08:28
@coderabbitai

coderabbitai Bot commented Jul 11, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@tschm, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 41 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 691ea331-6d7a-4a12-bd4f-9f448e9e5223

📥 Commits

Reviewing files that changed from the base of the PR and between 5c69e67 and f10bf53.

⛔ Files ignored due to path filters (1)
  • .rhiza/template.lock is excluded by !**/*.lock
📒 Files selected for processing (75)
  • .github/CONFIG.md
  • .github/DISCUSSION_TEMPLATE/help-wanted.yml
  • .github/DISCUSSION_TEMPLATE/ideas.yml
  • .github/dependabot.yml
  • .github/pull_request_template.md
  • .github/rulesets/main-branch-protection.json
  • .github/workflows/rhiza_benchmark.yml
  • .github/workflows/rhiza_book.yml
  • .github/workflows/rhiza_ci.yml
  • .github/workflows/rhiza_codeql.yml
  • .github/workflows/rhiza_fuzzing.yml
  • .github/workflows/rhiza_marimo.yml
  • .github/workflows/rhiza_mutation.yml
  • .github/workflows/rhiza_release.yml
  • .github/workflows/rhiza_scorecard.yml
  • .github/workflows/rhiza_sync.yml
  • .github/workflows/rhiza_weekly.yml
  • .pre-commit-config.yaml
  • .rhiza/.cfg.toml
  • .rhiza/.env
  • .rhiza/.rhiza-version
  • .rhiza/completions/README.md
  • .rhiza/completions/rhiza-completion.bash
  • .rhiza/completions/rhiza-completion.zsh
  • .rhiza/make.d/book.mk
  • .rhiza/make.d/bootstrap.mk
  • .rhiza/make.d/completions.mk
  • .rhiza/make.d/github.mk
  • .rhiza/make.d/marimo.mk
  • .rhiza/make.d/quality.mk
  • .rhiza/make.d/releasing.mk
  • .rhiza/make.d/test.mk
  • .rhiza/requirements/README.md
  • .rhiza/requirements/docs.txt
  • .rhiza/requirements/marimo.txt
  • .rhiza/requirements/tests.txt
  • .rhiza/requirements/tools.txt
  • .rhiza/rhiza.mk
  • .rhiza/template.yml
  • .rhiza/tests/README.md
  • .rhiza/tests/api/conftest.py
  • .rhiza/tests/api/test_github_targets.py
  • .rhiza/tests/api/test_make_variable_overrides.py
  • .rhiza/tests/api/test_makefile_api.py
  • .rhiza/tests/api/test_makefile_targets.py
  • .rhiza/tests/conftest.py
  • .rhiza/tests/integration/test_book_targets.py
  • .rhiza/tests/integration/test_docs_targets.py
  • .rhiza/tests/integration/test_test_mk.py
  • .rhiza/tests/integration/test_virtual_env_unexport.py
  • .rhiza/tests/shell/test_scripts.sh
  • .rhiza/tests/stress/README.md
  • .rhiza/tests/stress/__init__.py
  • .rhiza/tests/stress/conftest.py
  • .rhiza/tests/structure/test_project_layout.py
  • .rhiza/tests/structure/test_requirements.py
  • .rhiza/tests/sync/conftest.py
  • .rhiza/tests/test_docstrings.py
  • .rhiza/tests/test_pyproject.py
  • .rhiza/tests/test_readme_validation.py
  • .rhiza/tests/test_utils.py
  • .rhiza/tests/utils/test_git_repo_fixture.py
  • .rhiza/utils/pip_audit_policy.py
  • .rhiza/utils/suppression_audit.py
  • Makefile
  • cliff.toml
  • demo.py
  • docs/development/TESTS.md
  • docs/index.md
  • pytest.ini
  • ruff.toml
  • src/pycharting/api/interface.py
  • src/pycharting/core/lifecycle.py
  • src/pycharting/core/server.py
  • src/pycharting/data/ingestion.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch rhiza_v1.1.3

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates this repository’s Rhiza template pin to v1.1.3 and syncs the upstream template changes across repo tooling (Make targets, CI workflows, lint/typecheck rules, pytest defaults, and the synced .rhiza/tests suite).

Changes:

  • Bump .rhiza/template.yml / .rhiza/template.lock to Rhiza v1.1.3 and apply the synced bundle updates.
  • Tighten/adjust developer tooling defaults (ruff rule selection, pytest logging defaults, Make targets provisioning tooling via uv run --with …).
  • Add/refresh GitHub automation (new Scorecard/Fuzzing/Mutation stubs, ruleset JSON, discussion templates, and workflow permission scoping).

Reviewed changes

Copilot reviewed 72 out of 76 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
src/pycharting/data/ingestion.py Minor cleanup + add explicit __init__ return type.
src/pycharting/core/server.py Add return type annotation for the root endpoint.
src/pycharting/core/lifecycle.py Add return type annotations on several methods.
src/pycharting/api/interface.py Add return type annotations for public helpers / notebook repr.
ruff.toml Enables additional lint families and updates per-file ignores.
pytest.ini Adjust pytest defaults (pythonpath for .rhiza/tests, live logging off by default, warning filter).
Makefile Update repo-owned overrides; sets MKDOCS_EXTRA_PACKAGES.
docs/index.md Remove trailing blank line.
docs/development/TESTS.md Document how to opt into live DEBUG logs and update test-deps guidance.
demo.py Add return type annotations for entrypoints.
cliff.toml Add git-cliff config for changelog generation.
.rhiza/utils/suppression_audit.py Remove legacy utility script (now handled by rhiza-tools).
.rhiza/utils/pip_audit_policy.py Remove legacy utility script (now handled by rhiza-tools).
.rhiza/tests/utils/test_git_repo_fixture.py Remove older synced test (suite reshaped upstream).
.rhiza/tests/test_utils.py Remove older shared helper module (suite reshaped upstream).
.rhiza/tests/test_readme_validation.py Add new README code-block validation tests.
.rhiza/tests/test_pyproject.py Adjust fixtures (remove class scope) and keep pyproject checks.
.rhiza/tests/test_docstrings.py Add doctest-based docstring validation.
.rhiza/tests/sync/conftest.py Remove older sync-test scaffolding.
.rhiza/tests/structure/test_requirements.py Remove older structure test file.
.rhiza/tests/structure/test_project_layout.py Remove older structure test file.
.rhiza/tests/stress/README.md Remove older stress-test docs from synced suite.
.rhiza/tests/stress/conftest.py Remove older stress-test fixtures from synced suite.
.rhiza/tests/stress/init.py Remove older stress-test module marker.
.rhiza/tests/shell/test_scripts.sh Remove shell-script test harness from synced suite.
.rhiza/tests/README.md Rewrite synced test-suite README to match new layout and usage.
.rhiza/tests/integration/test_virtual_env_unexport.py Remove older integration test file.
.rhiza/tests/integration/test_test_mk.py Remove older integration test file.
.rhiza/tests/integration/test_docs_targets.py Remove older integration test file.
.rhiza/tests/integration/test_book_targets.py Remove older integration test file.
.rhiza/tests/conftest.py Simplify synced fixtures to root and logger.
.rhiza/tests/api/test_makefile_targets.py Remove older Makefile API test file.
.rhiza/tests/api/test_makefile_api.py Remove older Makefile API test file.
.rhiza/tests/api/test_make_variable_overrides.py Remove older Makefile variable override tests.
.rhiza/tests/api/test_github_targets.py Remove older GitHub targets tests.
.rhiza/tests/api/conftest.py Remove older API test fixtures.
.rhiza/template.yml Update pinned Rhiza template ref to v1.1.3.
.rhiza/template.lock Update lock metadata and expanded synced file list.
.rhiza/rhiza.mk Add Windows POSIX-shell guard, default env vars, and adjust targets.
.rhiza/requirements/tools.txt Remove legacy requirements file (tooling now provisioned on demand).
.rhiza/requirements/tests.txt Remove legacy requirements file (tooling now provisioned on demand).
.rhiza/requirements/README.md Remove requirements-folder README (folder removed).
.rhiza/requirements/marimo.txt Remove legacy requirements file (folder removed).
.rhiza/requirements/docs.txt Remove legacy requirements file (folder removed).
.rhiza/make.d/test.mk Overhaul test/typecheck/security/docs-coverage targets and provisioning approach.
.rhiza/make.d/releasing.mk Update release/bump flags and add changelog target.
.rhiza/make.d/quality.mk Refactor deptry inputs; switch suppression-audit to rhiza-tools.
.rhiza/make.d/marimo.mk Contribute marimo folder into shared deptry scan.
.rhiza/make.d/github.mk Add GitHub CLI helper targets.
.rhiza/make.d/completions.mk Add install-completions target for bash/zsh.
.rhiza/make.d/bootstrap.mk Adjust uv sync behavior and make pre-commit hook install conditional.
.rhiza/make.d/book.mk Provision marimo via uv run --with and keep book build wiring.
.rhiza/completions/rhiza-completion.zsh Add caching for completion target extraction.
.rhiza/completions/rhiza-completion.bash Add caching for completion target extraction.
.rhiza/completions/README.md Document quick install and caching behavior.
.rhiza/.rhiza-version Update rhiza tool version marker.
.rhiza/.env Add template-synced .env header and defaults documentation.
.rhiza/.cfg.toml Add bump-my-version rules (includes workflow-stub pin rewrite).
.pre-commit-config.yaml Update hook versions, pin node runtime, and add betterleaks.
.github/workflows/rhiza_weekly.yml Bump reusable workflow pin to v1.1.3.
.github/workflows/rhiza_sync.yml Bump reusable workflow pin and scope permissions.
.github/workflows/rhiza_scorecard.yml Add Scorecard workflow stub.
.github/workflows/rhiza_release.yml Major release-workflow updates (permissions, concurrency, attestations, publishing behavior).
.github/workflows/rhiza_mutation.yml Add mutation-testing workflow stub (opt-in).
.github/workflows/rhiza_marimo.yml Bump reusable workflow pin to v1.1.3.
.github/workflows/rhiza_fuzzing.yml Add fuzzing workflow stub.
.github/workflows/rhiza_codeql.yml Bump reusable workflow pin and scope permissions.
.github/workflows/rhiza_ci.yml Bump reusable workflow pin to v1.1.3 and document matrix source-of-truth.
.github/workflows/rhiza_book.yml Bump reusable workflow pin and adjust triggers/permissions.
.github/workflows/rhiza_benchmark.yml Bump reusable workflow pin to v1.1.3.
.github/rulesets/main-branch-protection.json Add branch protection ruleset configuration.
.github/pull_request_template.md Add changelog checkbox to PR checklist.
.github/DISCUSSION_TEMPLATE/ideas.yml Add discussion template for ideas.
.github/DISCUSSION_TEMPLATE/help-wanted.yml Add discussion template for help-wanted posts.
.github/dependabot.yml Whitespace normalization in config.
.github/CONFIG.md Document required/optional secrets for Rhiza workflows.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .rhiza/.env
Comment on lines +1 to +20
# .rhiza/.env — project-local environment overrides (optional)
#
# This file is optional. If absent, rhiza.mk falls back to built-in defaults:
# SOURCE_FOLDER = src
# MARIMO_FOLDER = docs/notebooks
# RHIZA_CI_OS_MATRIX = ["ubuntu-latest"]
#
# Add or uncomment only the variables you want to override.
# Variables defined here are exported to all Make recipes.

# .rhiza/.env — project-local environment overrides (optional)
#
# This file is optional. If absent, rhiza.mk falls back to built-in defaults:
# SOURCE_FOLDER = src
# MARIMO_FOLDER = docs/notebooks
# RHIZA_CI_OS_MATRIX = ["ubuntu-latest"]
#
# Add or uncomment only the variables you want to override.
# Variables defined here are exported to all Make recipes.

Comment thread .rhiza/.cfg.toml
Comment on lines +52 to +66
# Keep the reusable-workflow stubs in the bundles pinned to the current release.
# These stubs are synced into downstream repos and must reference an existing tag.
# The search is a regex anchored to the `jebel-quant/rhiza/...` path so it rewrites
# the pin from ANY prior version (not just {current_version}) — this prevents silent
# drift if a stub was left behind — while leaving third-party action pins
# (actions/checkout@vX, astral-sh/setup-uv@vX, ...) in the same files untouched.
# This block ships verbatim in the synced downstream .cfg.toml; there it is a
# harmless no-op because a downstream repo has no bundles/ tree (the glob matches
# nothing and bump-my-version skips it).
[[tool.bumpversion.files]]
glob = "bundles/**/.github/workflows/*.yml"
regex = true
search = "(jebel-quant/rhiza/[^@\\s]+)@v\\d+\\.\\d+\\.\\d+"
replace = "\\1@v{new_version}"
ignore_missing_version = true
Comment thread ruff.toml
Comment on lines 67 to +71
extend-select = [
"D105", # pydocstyle - Require docstrings for magic methods
"D107", # pydocstyle - Require docstrings for __init__
"A", # flake8-builtins - Don't shadow Python builtins
"ANN001", # flake8-annotations - Require function argument annotations
Comment thread ruff.toml
# SLF: private-member access is needed in tests; too coarse to enable repo-wide
# TCH/TID: no typing-only import cycles or import-tidiness issues at this size
# RSE: raise micro-style; TRY covers the error-prone patterns
# NPY/PD: no NumPy/pandas runtime code in this repository
Comment thread .rhiza/template.yml
Comment on lines 1 to +2
repository: "jebel-quant/rhiza"
ref: "v0.18.8"
ref: "v1.1.3"
Comment thread .rhiza/.rhiza-version
@@ -1 +1 @@
0.16.1
0.17.6
Comment thread Makefile
Comment on lines +6 to +7
# Override template default: include mkdocstrings plugin for API docs
MKDOCS_EXTRA_PACKAGES = --with 'mkdocstrings[python]'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants