phpstan-drupal Playground Adds Agent Support for Bug Reproductions
The phpstan-drupal playground now supports agent-driven bug reproduction workflows that previously depended on its browser interface. phpstan-drupal maintainer Matt Glaman described the changes in a blog post published on 3 September 2026 after addressing several gaps that prevented an agent from independently creating or investigating a shared reproduction. The playground runs PHPStan with phpstan-drupal against a Drupal core installation and produces results that developers can link from bug reports.
The updated service publishes an llms.txt file describing its API base URL, request body, response structure, and reproduction workflow. The analysis endpoint now returns the complete share URL instead of only an identifier that previously required knowledge of frontend routing. Saved results can also be retrieved as Markdown, with reported errors paired with their source lines and the original analysis compared with a fresh run against the playground's current PHPStan, phpstan-drupal, and Drupal versions.
The update also changes malformed requests and missing results to return 400 and 404 responses instead of generic 500 errors. While correcting the missing-result behaviour, Glaman found that mocked tests had not reproduced an Amazon S3 permission condition encountered in production: without permission to list the bucket, S3 returned 403 rather than the expected NoSuchKey response. The changes let an issue reporter ask an agent to create a reproduction and return a share link, while a maintainer can give an agent an existing link to investigate. Matt Glaman's original post includes further implementation details.


