laminas/laminas-file
Laminas File provides file upload and transfer handling for Laminas applications. It includes HTTP upload adapters that manage uploaded files, expose metadata, and integrate with validators and filters for safe, flexible file processing.
(new ReflectionClass($class))->getFileName() or Composer\Autoload\ClassLoader::findFile($class). The only durable differentiator left in this package is tokenizer-based scanning of .phar archives and files that Composer does not autoload. That is a narrow enough gap that "write 30 lines in-house" beats "adopt an archived vendor library" for any greenfield work.laminas-di and laminas-code), and plugin/module discovery by class name. If your roadmap contains any of these, this package is a supporting detail of an existing framework choice, not a feature decision in its own right.Reasonable to keep (not adopt):
laminas-di, laminas-code, or a legacy Zend Framework 2 stack. Rip-out cost exceeds the risk in the near term — pin the version, add it to a dependency watchlist, and move on..phar archives or code that is not registered with Composer's autoloader. This is the one scenario where reimplementation is non-trivial.Look elsewhere:
ReflectionClass::getFileName() or Composer's ClassLoader::findFile(). Standard library, no dependency, no archival risk.nikic/php-parser or roave/better-reflection, which are actively maintained and do far more than path lookup.Adoption verdict: Do not add this as a direct dependency. Accept it only as an inherited transitive one, with the explicit expectation that it will be removed at the next major framework upgrade.
For executives (one paragraph): We have identified a small, permissively licensed PHP utility in our dependency tree that locates the source file for a given class. It is functionally replaceable by built-in PHP and Composer features, it is no longer maintained by its authors, and its community footprint is negligible. There is no feature value in it and no license or cost exposure. The recommendation is to leave it in place where it already exists, pin the version, and schedule removal alongside our next framework upgrade — a low-effort cleanup, not a project. The risk is not technical failure today; it is carrying unowned code past the point where it matters.
For engineering (framing): Treat laminas/laminas-file as frozen infrastructure, not a library. Do not build new code against its API; if you need class-to-file resolution, use ReflectionClass::getFileName() or the Composer ClassLoader. The only retained capability worth preserving is tokenizer-based scanning of .phar archives, and if we depend on that, we should own a small internal implementation rather than an archived one. Pin the current version, add it to the dependency-review list, and flag it in any upgrade ticket that touches laminas-di or laminas-code, since that is our natural window to remove it.
How can I help you explore Laravel packages today?