News for hackers. Stuff that matters.
Re:Show HN: PHP-fts – Full-text search engine in pure PHP, n... by Oxodao on Thursday May 07, 2026 @03:00AM (#48046312)
1. Just add phpcsfixer and phpstan like any sane project

2. If you use phpunit class in prod code, you deserve to get a fatal error

Re:Show HN: PHP-fts – Full-text search engine in pure PHP, n... by kassner on Thursday May 07, 2026 @03:41AM (#48046573)
1. Both tools will not catch it, you need something like https://github.com/maglnet/ComposerRequireChecker

2. That doesn’t apply to PHPUnit specifically, but if you, for example, import PHP-cs-fixer as dev dependency, it will bring symfony/console, and if you rely on that on your own code without importing it on composer.json as a regular dependency, the class will be missing when you composer install for production.

Re:Show HN: PHP-fts – Full-text search engine in pure PHP, n... by Oxodao on Thursday May 07, 2026 @08:20AM (#48048483)
Ok I get what you're saying now, that's fair. Tbh I mainly do Symfony so most of what dev-dependencies use are already in the dependencies for me so it never happened