PHPStan (@phpstan) profile picture

Find bugs in your code without writing tests! Created by @OndrejMirtes

Joined July 2016
Photo by PHPStan (@phpstan)Photo by PHPStan (@phpstan)Photo by PHPStan (@phpstan)Photo by PHPStan (@phpstan)Photo by PHPStan (@phpstan)Photo by PHPStan (@phpstan)
I just sent out the first PHPStan newsletter of 2026. You can read it here: phpstan.kit.com/posts/you-re… If you don’t wanna miss out on the next ones, feel free to subscribe 😉
3
15
973
PHPStan 2.3.6 is out:
1
15
95
3,197
Tally does not measure, it counts. A new PHP framework for catching performance regressions in CI. Tally doesn’t care how fast the current CI runner is, it always reports stable numbers. I tagged 1.0 last night: phpstan/tally
2
5
26
2,051
👀 PHPStan will soon be able to remove unmatched ignoreErrors automatically by running with --fix
2
13
1
108
3,502
PHPStan retweeted
Good news, looks like @OndrejMirtes is going to maintain TwigStan! Future is bright certanly 🤩
3
11
575
Příští čtvrtek 5. 11. se potkáme v Apify na dalším srazu Péhápkařů! 🎤 Jan Tůma – Serverless all the way down 🎤 Patrik Votoček – Od npm install k přístupu do AWS: Anatomie moderního útoku 🎤 Ondřej Mirtes – PHPStan Turbo Díky @cookielab za podporu! meetup.com/pra%C5%BEske-sraz…
2
1
4
965
Since #phpstan 2.3.0 a single rule can subscribe to multiple node types. Using MultipleNodeTypesRule interface some rules can be implemented more efficiently.
3
4
15
1,186
PHPStan retweeted
The rumors are true.... Today we've released @rector 2.8, that is 30 % faster than 2.7 out of the box. And even 3x faster on PHP 8.3+ thanks to PHPStan Turbo. Huge thanks to @sander_scode who landed this feature in past 2 weeks 🎉🎉🎉
PHPStan Turbo now also makes Rector faster! Rector 2.8 ships with Turbo enabled, taking 50% less time to finish.
3
19
2
88
4,823
PHPStan Turbo now also makes Rector faster! Rector 2.8 ships with Turbo enabled, taking 50% less time to finish.
11
1
77
7,553
If all the govs shutting down servers for a PHP update, all the hosters & enterprises terrified by the vuln, gave $100k, or just $50k a year to the PHP Foundation, things could look very differently. Go, make your employer sponsor *today* thephp.foundation/sponsor/ #php #phpc @ThePHPF
4
130
12
273
19,887
Caching Composer dependencies in GitHub Actions is easy thanks to the lock file. But what about a tool like PHPStan that has no lock file to hash? masteringlaravel.io/daily/20…
1
2
3
570
Before: oh, the Symfony DIC changed slightly, let’s nuke the whole result cache Now: we changed parameter X in Symfony config, the result cache will reanalyse only the files asking about it
#phpstan 2.3.x added new dependency tracking APIs which allow custom extensions/rules to declare values/files they depend on. todays #phpstandba 0.5 release uses the new APIs, which allows us to re-analyze only code depending on the database schema when it changes.
3
13
1,449
I wanted to stop controllers calling external services, however deep in the call graph. So I built a PHPStan extension: mark external calls as 'slow', forbid 'slow' in controllers, and let it flag violations. Probably has many other uses too. github.com/DaveLiddament/php…
3
6
26
1,217
Same performance, smaller package PHPStan 2.3.0 was chonky! It weighed 104 MB when downloaded and 268 MB after being unzipped in your vendor/. I just released PHPStan 2.3.1 that weighs just under 28 MB when downloaded and 87 MB unzipped. While preserving all the Turbo binaries.
10
10
162
6,293
PHPStan analysing the WordPress codebase took 60.51 seconds back in december. With PHPStan 2.3 + Turbo: 7.93 seconds. That’s the kind of dev improvement I get excited about💪
3
3
21
849
PHPStan retweeted
Tried PHPStan 2.3.0 on our Laravel 13 project: cold analysis dropped from 40.86s to 17.88s with Turbo enabled — 2.29× faster! Same code/config, up to 6 workers. Thanks for the release! ** switched PHP 8.4 ZTS → NTS to enable Turbo. Warm cache: ~1.6s in both.
PHPStan 2.3.0 is out with massive leap in performance, generics improvements, detecting unused variables, improved closure type inference, inferring static variable types from assignments, and engine rewrite!
2
4
1
11
867
PHPStan retweeted
Replying to @OndrejMirtes
@OndrejMirtes wasn't kidding with the speed improvement 🤯 it also uses less memory
PHPStan is now way faster so we can all PHPFaster 🚀
1
4
5
362
Ran PHPStan 2.3.0 on my work codebase, a large funeral services ERP (5,600+ files, 550k lines of Laravel), and asked the AI to chart the difference. Full cold analysis: 52.7s → 14.8s. 3.6× faster That's impressive work. It also caught 5 new real errors.
4
3
301
No-brainer upgrade, the testsuite for getsnapkin.app/ just got cut in half with zero effort 🥳 The PHPStan blogpost is also a marvel to read 👏
PHPStan 2.3.0 is out with massive leap in performance, generics improvements, detecting unused variables, improved closure type inference, inferring static variable types from assignments, and engine rewrite!
4
10
1,117