Skip to content
CAI
Software that uses CAICheck a score

sebastianbergmann/object-reflector

59.9

Adequate · 19 September 2026

455

lines of production code

PHP

primary language

1

measurement over time

CAI band scale
CAI lens gauges

What this system is

This system is a PHP library focused on high-performance object reflection, featuring a custom ObjectReflector that optimizes property access via array casting and caching. It is built on modern PHP 8.4 standards with rigorous static analysis using PHPStan and comprehensive unit testing for complex reflection edge cases. The project also includes automated build tooling for release note generation and CI/CD integration via GitHub Actions.

Behavioural changes

135 commits (0 fixes) modifying tools

A change to existing behaviour in tools — 135 commits, 4 files.

tools · medium confidence · unverified

Automated release note extraction for tagged releases

A new build script, extract-release-notes.php, has been added to the build directory to automate the generation of release notes. When invoked with a specific version tag, this script parses the project's ChangeLog.md file to extract the corresponding section, enabling the CI/CD pipeline to automatically create release artifacts when a tag is pushed.

build · high confidence

Modernized build automation and static analysis configuration

The project has replaced the legacy Travis CI setup with GitHub Actions and switched static analysis from Psalm to PHPStan (configured via phpstan.neon at level 10 with strict rules). Build tooling is now managed through Phive, with Composer and PHP-CS-Fixer installed in the tools directory, and the old .php\_cs file has been removed in favor of .php-cs-fixer.dist.php. Additionally, a Security Policy (SECURITY.md) has been added, and archive exports are now controlled via .gitattributes to exclude development files.

(repo-wide) · high confidence

ObjectReflector now uses array casting and caching for property reflection

The ObjectReflector class has been refactored to replace the Reflection API with a direct cast of the object to an array, significantly improving performance. It now correctly handles mangled property names (private and protected) by parsing null-byte separators and caching unmangled names per class. The method has been renamed from getAttributes to getProperties, and the class is now final with strict types enabled.

src · high confidence

Test coverage

Added test fixtures for advanced PHP reflection scenarios; Added unit tests for ObjectReflector edge cases; Removed legacy ObjectReflector test suite.

Dependencies

Updated PHPStan static analysis tooling to version 2.2.14

The \tools/.phpstan\ directory has been updated to use PHPStan version 2.2.14, along with \phpstan-strict-rules\ 2.0.12 and \ergebnis/phpstan-rules\ 2.13.1. This upgrade brings the latest static analysis capabilities and rule sets to the project's local development environment, ensuring that code quality checks reflect the most recent standards and bug fixes provided by these libraries.

tools/.phpstan · high confidence

Upgrade to PHPUnit 13 and PHP 8.4; add PHPStan tooling

The project now requires PHP 8.4 or higher and upgrades the test framework from PHPUnit 6 to PHPUnit 13.3.4. Additionally, a dedicated PHPStan tooling environment has been introduced under tools/.phpstan, installing PHPStan 2.2.14 along with the extension-installer, strict-rules, and ergebnis/phpstan-rules to enhance static analysis capabilities.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Baseline

  • First survey — no prior run to compare against. CAI 60.

Lenses

  • Code Health 100
  • Architecture 69
  • Maturity 41
  • Readiness 78
  • Security 88

Changes since last survey

  • 300 commits — 294 feature/other, 6 fixes

By area

  • .phive/phars.xml — 91 commits
  • (root) — 76 commits
  • .github/workflows — 55 commits
  • tools/.phpstan — 40 commits
  • (repo) — 19 commits
  • tests/_fixture — 8 commits
  • .github/FUNDING.yml — 2 commits
  • .psalm/config.xml — 2 commits
  • tests/ObjectReflectorTest.php — 2 commits
  • tests/unit — 2 commits
  • .github/CODE_OF_CONDUCT.md — 1 commit
  • .github/CONTRIBUTING.md — 1 commit
  • .psalm/baseline.xml — 1 commit

Notable commits

  • fix: Fix CS/WS issues
  • fix: Fix CS/WS issues
  • fix: Fix package name
  • fix: Fix reflection of properties of objects of anonymous classes
  • fix: Fix reflection of property whose name contains a null byte
  • fix: Fix/Tweak
  • change: * Install PHPStan using Composer in order to be able to use phpstan/phpstan-strict-rules and tomasvotruba/type-coverage * Configure phpstan/phpstan-strict-rules, tomasvotruba/type-coverage, and ergebnis/phpstan-rules * Update PHPStan configuration * Put Phive binary under version control and manage it through "ant update-tools"
  • change: Add Liberapay and Tidelift
  • change: Add Security Policy
  • change: Add documentation on how to contribute
  • change: Add link to security policy
  • change: Add missing tests
  • change: Add test for reflection of private property that is redeclared in child class
  • change: Add test for reflection of protected and public properties
  • change: Add tests for properties that are not reflected
  • change: Add tests for reflection of hooked properties
  • change: Add tests for reflection of lazy objects
  • change: Add thanks.dev
  • change: Allow write operations
  • change: Also automerge minor updates
  • …and 280 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

sebastianbergmann/object-reflector was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 19 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit e9d0c21673a91e5e77a2d6af94a442bcb3f1355e — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-13a154b7f5d1.