Skip to content

Update the git hooks and the CI workflow to ResearchHarness 4e4b534 - #40

Merged
michakraus merged 3 commits into
mainfrom
ci/hooks-and-downgrade
Nov 3, 2026
Merged

michakraus merged 3 commits into
mainfrom
ci/hooks-and-downgrade

Conversation

@michakraus

@michakraus michakraus commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

This PR installs the current generated git hooks and CI workflow of the ResearchHarness, commit 4e4b534. Two changes reach this repository.

The downgrade job resolves the root and test projects together

.github/workflows/CI.yml (ResearchHarness #157): the Downgrade job runs julia-downgrade-compat with projects: ., test. It resolves Project.toml and test/Project.toml into one manifest, at their lower bounds, and forcedeps checks the lower bounds of both.

Before, it resolved the root project alone, so each indirect dependency came in at its newest version, and the test run, which keeps that manifest, could not add a test-only dependency that caps it. Two forms of this failure appear across these packages: DocStringExtensions 0.10.2 against Documenter 1.19, and CEnum 1.0.0 against CairoMakie or Metal.

The job stays advisory, and the required checks do not change. A lower bound in test/Project.toml that cannot be reached now turns the job red, with forcedeps check failed: Some test dependencies did not resolve to their lower bounds. Such a bound is fixed on this branch before the merge.

The git hooks take the fixes of the hook review

.githooks/pre-commit.jl and .githooks/pre-push.jl (ResearchHarness #156):

  • A package name that is not a Julia identifier is refused with one line, before any code is built from it.
  • A Project.toml is a package only with both a name and a uuid; otherwise pre-commit runs no load test, and pre-push runs test/runtests.jl.
  • An interrupted push waits until the suite's process group is gone, and kills it at the grace time.
  • A failed load report starts at its first ERROR: line, and the error refusals print the location line.
  • The staged paths reach fatou lint after --, and a fatou failure with no finding line is reported as a failure of fatou; the lint stage stays advisory.

Files

The six files are byte-identical to the ResearchHarness at 4e4b534, as harness githooks --apply and harness workflows --apply install them: CI.yml, .githooks/pre-commit, pre-commit.jl, pre-push, pre-push.jl and test-layout.jl. Only pre-commit and pre-push are executable. Files that already match do not appear in the diff. No package source changes.

Lower bounds for the merged downgrade check

Three test-only floors in test/Project.toml rise. The root [compat] does not change. With them, the merged resolve passes forcedeps, and the test suite passes at the floors on Julia 1.12.

  • GeometricIntegrators "0.18" → "0.18.6": 0.18.0–0.18.5 require GeometricBase 0.14, and the package requires 0.15, so the resolve gave 0.18.6 and forcedeps failed.
  • GeometricProblems "0.8, 0.9" → "0.9.1": 0.6.19–0.9.0 require GeometricBase 0.14, so the resolve gave 0.9.1.
  • Aqua "0.8" → "0.8.14": at 0.8.0, Aqua.test_piracies fails on Julia 1.12 with FieldError: type Core.TypeName has no field mt. Releases 0.8.0–0.8.13 read Core.TypeName.mt on Julia 1.12.x, and 0.8.14 is the first release that reads Core.methodtable there.

CHANGELOG.md records the three floors under [Unreleased].

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Bug Fixes
    • Pre-commit and pre-push checks provide clearer error messages and improve timeout and interrupt handling.
    • Package checks require project metadata to include a name and UUID, and validate that names are Julia identifiers.
    • Pre-commit lint checks use staged paths and distinguish findings from other failures. Load-test output focuses on errors when available.
  • Chores
    • CI downgrade checks account for dependencies in both the main and test projects.
    • Minimum test dependency versions have been raised for Aqua, GeometricIntegrators, and GeometricProblems.

The downgrade job resolves the root and test projects together (projects: ., test), and the hooks take the fixes of the hook review.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: f5bed1c1-b957-4fa2-b013-30b57a609286
Commits

Reviewing files that changed from the base of the PR and between 5f7b910 and 582b5c0.

Files selected for processing: 2
  • .githooks/pre-commit.jl
  • .githooks/pre-push.jl

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 5 remain after this review.

Walkthrough

The hooks update package validation, error and test output, and subprocess shutdown. The downgrade CI job includes both the root and test projects, whose test dependency floors are also updated.

Changes: Julia hook behavior

Layer / File(s) Summary
Package identity and error reporting
.githooks/pre-commit.jl, .githooks/pre-push.jl
Both hooks require name and uuid in Project.toml to return a package name and validate that the name is a Julia identifier. Error reporting includes additional parse-error details.
Pre-commit lint and load reporting
.githooks/pre-commit.jl
Fatou receives staged paths after --. The hook distinguishes diagnostic findings from Fatou failures. Load-failure output starts at the first ERROR: line when present and includes at most 20 lines.
Subprocess timeout and interrupt handling
.githooks/pre-commit.jl, .githooks/pre-push.jl
The pre-commit hook measures its timeout with a monotonic clock and closes its SIGKILL timer. The pre-push hook signals the process group after interruption, schedules SIGKILL after the grace period, and waits for the process and group to stop or the timeout to expire.

CI dependency downgrade resolution

Layer / File(s) Summary
Resolve root and test projects
.github/workflows/CI.yml, test/Project.toml, CHANGELOG.md
The downgrade action resolves . and test. The test dependency floors for Aqua, GeometricIntegrators, and GeometricProblems are raised, and the changelog records the stated compatibility constraints.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Bug fix

Sequence Diagram(s)

sequenceDiagram
  participant PrePushHook
  participant SuiteProcess
  participant ProcessGroup
  participant KillTimer
  PrePushHook->>SuiteProcess: Start suite and record process-group ID
  PrePushHook->>ProcessGroup: Send SIGINT after interruption
  PrePushHook->>KillTimer: Schedule SIGKILL after grace period
  KillTimer->>ProcessGroup: Send SIGKILL
  PrePushHook->>ProcessGroup: Wait for group to stop or timeout
Loading

Possibly related PRs

Merge Risk: Minimal · up to 582b5

No known issue remains that should block merging after normal checks.

Architecture risk: Low · up to 582b5

The change affects 2 systems.

Changed systems: CHANGELOG.md, test

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — CHANGELOG.md (service) was modified; 1 changed file maps to changed impact.
  • observed — test (service) was modified; 1 changed file maps to changed impact.

Before / after behavior

  • observed — Modified behavior in CHANGELOG.md: Added a changelog entry documenting the test-only dependency floor updates: GeometricIntegrators to "0.18.6", GeometricProblems to "0.9.1", and Aqua to "0.8.14", including the stated resolution and Julia 1.12 compatibility constraints.
  • observed — Modified behavior in test/Project.toml: The compatibility entries now specify Aqua 0.8.14, GeometricIntegrators 0.18.6, and GeometricProblems 0.9.1 instead of their broader previous bounds; Documenter remains unchanged at 1.19.0.
  • observed — Modified behavior in .github/workflows/CI.yml: The downgrade job’s documented scope now includes direct dependencies from both the root and test projects, replacing the root-only description. It also documents the shared-manifest resolution and the action’s behavior when test/Project.toml is missing.
  • observed — Modified behavior in .github/workflows/CI.yml: The downgrade action now sets projects to ., test instead of leaving it at the default root project, so both projects are included in resolution.
Pre-merge checks: Passed 5
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title clearly identifies the main changes: updating the git hooks and CI workflow to the specified ResearchHarness commit. It is concise and related to the changeset.
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 0 files. (2 skipped: 2 unsupported.)

Finishing Touches
Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@coderabbitai coderabbitai Bot 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.

  • Fix comments: Fix CodeRabbit comments on this PR

Comment thread .githooks/pre-push.jl Resolved
@codecov

codecov Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.91%. Comparing base (c4e257c) to head (582b5c0).

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #40   +/-   ##
=======================================
  Coverage   89.91%   89.91%           
=======================================
  Files          10       10           
  Lines         357      357           
=======================================
  Hits          321      321           
  Misses         36       36           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

michakraus and others added 2 commits November 2, 2026 18:32
The Downgrade job resolves Project.toml and test/Project.toml together
at their lower bounds. GeometricIntegrators 0.18.0-0.18.5 and
GeometricProblems 0.6.19-0.9.0 require GeometricBase 0.14, so their
floors rise to 0.18.6 and 0.9.1. Aqua 0.8.0-0.8.13 reads
Core.TypeName.mt in test_piracies, which Julia 1.12 removes; the floor
rises to 0.8.14, the first release that reads Core.methodtable.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
After an interrupt, pre-push waits at most 10 s past its SIGKILL for the suite's process group, and further interrupts are deferred until it exits. The time box of pre-commit measures its grace on the monotonic clock. A parse error's refusal names the parser's reason, and a Project.toml with a name and no uuid says that no load test runs. These are the fixes of the review of this pull request.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@michakraus
michakraus merged commit 9a5d9c3 into main Nov 3, 2026
13 of 14 checks passed
@michakraus
michakraus deleted the ci/hooks-and-downgrade branch November 3, 2026 13:17
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.

1 participant