Skip to content

Add JET.jl static analysis tests#13

Merged
ChrisRackauckas merged 1 commit into
SciML:mainfrom
ChrisRackauckas-Claude:static-improvements-20251230-053443
Dec 30, 2025
Merged

Add JET.jl static analysis tests#13
ChrisRackauckas merged 1 commit into
SciML:mainfrom
ChrisRackauckas-Claude:static-improvements-20251230-053443

Conversation

@ChrisRackauckas-Claude
Copy link
Copy Markdown

Summary

  • Add JET.jl as a test dependency
  • Add test/jet.jl with static analysis tests for core functions
  • Test getindex, setindex!, size, and setdiagonal! for runtime errors
  • Test type stability of getindex and size

Analysis Results

JET analysis was run on the package and found:

  • No runtime dispatch errors in the package code
  • Type stability: Core operations (getindex, setindex!, size, setdiagonal!) are type stable
  • The mul! functions show issues related to Julia's @threads macro internal assertions (not package code)

The existing codebase is already well-typed:

  • Type-parameterized SparseBandedMatrix{T} struct
  • Explicit type conversions with convert(T, val)::T patterns
  • Duck typing for val and diagvals parameters is intentional for flexibility

Test plan

  • Ran JET.report_package - no errors
  • Ran JET.report_call on all key functions - no errors
  • Ran JET.report_opt for type stability - core functions are type stable
  • Ran Pkg.test() - all 27 tests pass

cc @ChrisRackauckas

🤖 Generated with Claude Code

Add JET.jl testing for type stability and error-free static analysis:
- Add JET as a test dependency
- Add test/jet.jl with static analysis tests for core functions
- Test getindex, setindex!, size, and setdiagonal! for errors
- Test type stability of getindex and size

This ensures the package maintains type stability and catches potential
type inference issues during CI.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@ChrisRackauckas ChrisRackauckas merged commit cb9ad9a into SciML:main Dec 30, 2025
4 of 7 checks passed
@ChrisRackauckas-Claude
Copy link
Copy Markdown
Author

CI Status Update

All test jobs passed:

  • Tests (1) ✅
  • Tests (lts) ✅
  • Tests (pre) ✅
  • test ✅

The failing jobs are pre-existing issues unrelated to this PR:

  • Spell Check: Flags "BA" in comment # C = Cb + aBA on line 117 (pre-existing, represents mathematical formula aBA)
  • build (format check): CI infrastructure issue with JuliaFormatter/SciMLStyle installation
  • cleanup: Cleanup job failure

The JET.jl tests I added are working correctly on all Julia versions (1, LTS, pre-release).

cc @ChrisRackauckas

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.

3 participants