nette/reflection
Standalone PHP reflection library from Nette that extends PHP’s Reflection API with easier inspection of classes, methods, properties, parameters, and annotations. Useful for frameworks, DI containers, and code analysis tools.
nette/reflection is archived (last release 2017-07-14) with a NOASSERTION license. If it appears in a Laravel project, it is almost always a transitive leftover from a Nette-era component or an old annotation-driven package. The decision it drives is keep, fork, or remove — not adopt.Reflection, PHP 8 attributes, phpdocumentor/reflection-docblock, roave/better-reflection, symfony/property-info). The PM call: do not build or maintain a bespoke parser, and do not standardize on a discontinued one.NOASSERTION means the license was not machine-identifiable; shipping it in a commercial or redistributed product requires a human legal read before it stays in the tree.Consider it only when all of these hold:
@var/@param, annotation objects on class/method/property reflection) preserved bit-for-bit for backward compatibility.Look elsewhere in every other case — which is nearly all of them:
Reflection and PHP 8 attributes. Adding a docblock parser to a Laravel service provider buys nothing.ReflectionClass/ReflectionMethod — zero dependencies, no autoload side effects.phpdocumentor/reflection-docblock is maintained and does exactly that.roave/better-reflection is the maintained answer.spatie/laravel-data, native attribute-based routing/validation) over annotations; doctrine/annotations itself is deprecated, which tells you where the whole pattern is heading.symfony/property-info or phpdocumentor/type-resolver cover it with active maintenance.Two practical red flags to check before any decision: whether the codebase touches internal PHP reflection APIs that shifted in PHP 8 (likely breakage), and whether the package's license text can be resolved to something your legal team accepts.
For executives (30-second version): This is a discontinued PHP library, last shipped in 2017, now archived, with an unclear license. We are not proposing to adopt it. It shows up only as a legacy leftover in older code, and its cost is not licensing — it is the engineering time to remove it before our next PHP upgrade and the legal review needed while it stays. Recommendation: log it as a small, bounded tech-debt item, not a strategic dependency.
For engineering leads: Treat nette/reflection as a migration target, not a component. Inventory where it is actually used (its annotation reads are usually the real coupling point), replace docblock-annotation lookups with PHP 8 attributes or native Reflection, and where raw docblock parsing is genuinely required, swap in phpdocumentor/reflection-docblock or roave/better-reflection behind a thin internal interface so the choice stays reversible. Expect PHP 8 incompatibility given its age and its extension of native reflection internals. If external consumers depend on the annotation semantics, ship a deprecation notice and a codemod before removal.
One-line framing for a steering deck: "Discontinued since 2017, archived, unlicensed — we are scheduling its removal, not evaluating its adoption."
How can I help you explore Laravel packages today?