guni/php-var-dump-check
A lightweight static analysis tool that scans PHP codebases for leftover debug calls such as var_dump(), print_r(), dd(), and dump(), helping catch them before they reach production. Easy to wire into CI for automated checks.
var_dump, print_r, dd, dump, etc.) survive into a commit — a cheap, deterministic guardrail against a class of defects that is otherwise caught only by manual review or, worse, by users in production.grep/regex step in CI or an existing PHP_CodeSniffer/PHPStan rule. Given near-zero adoption signals (0 stars, 0 dependents, GitLab-hosted, unmaintained risk), this is a "borrow the idea, not the package" decision unless the code is small and audited.dd()/dump() semantics and existing linter ecosystems — versus introducing a single-purpose external package into the dependency tree.Reasonable fit when:
composer lint:dump entry point with minimal wiring.Look elsewhere when:
SlevomatCodingStandard debug sniffs via PHP_CodeSniffer, PHPStan custom rules, or Rector rule sets cover this and dozens of adjacent problems with one tool and one upgrade path.dd(), dump(), ray(), and Blade-level artifacts need rules tuned to that ecosystem; a generic dumper scanner will under-detect.Recommended posture: treat it as reference implementation, not a dependency. The detection logic is small; porting it into an existing linter or a CI regex step removes the third-party risk entirely at roughly the same cost.
For executives (one paragraph): Debug statements left in shipped code are a small but recurring defect class with outsized consequences — they can leak internal data structures to end users, corrupt API responses, and slow down requests. This package is a lightweight automated check that fails the build before such code reaches production. The concept is worth adopting; the specific dependency is not. Because it has effectively no community adoption or maintenance backing, we recommend implementing the same check inside tooling we already run — a few lines of CI configuration or an existing linter rule — capturing the benefit with zero new supply-chain risk and no ongoing ownership burden.
For engineering leads: The value is a deterministic, zero-tolerance CI gate on debug artifacts, wired into the existing pipeline as a lint step. Don't take the dependency as-is: review the source, confirm it covers your actual dumper surface (var_dump, print_r, dd, dump, ray, Blade templates), and check that it supports a baseline or ignore mechanism so legacy hits can be burned down incrementally rather than blocking all work on day one. Preferred path is to fold the rule into PHP_CodeSniffer, PHPStan, or GrumPHP so the team has one lint story instead of five.
For security/compliance: This is a preventive control against inadvertent information disclosure via debug output. It addresses a real but low-severity risk with a very low implementation cost, and can be delivered without adding an unmaintained third-party package to the build chain.
Ask: Approve the control (a CI gate for debug artifacts), one engineer-day to implement it against existing tooling, and a policy that new services ship with the gate enabled by default.
How can I help you explore Laravel packages today?