Skip to content

Improve TableErrorFormatter #14232

@staabm

Description

@staabm

Feature request

rendering a huge number of errors with table-error formatter is very inefficient.
formatting ~32000 errors in the wordpress codebase (via mago benchmark) takes 11 seconds on m4 pro.

rendering is dominated by symfony console stuff:

Image

for comparison: running the same result thru others error formatters takes...

  • json 2,5 seconds
  • junit 2,5 seconds
  • github 2,6 seconds
  • teamcity 2,6 seconds
  • gitlab 3 seconds
  • prettyJson 2,5 seconds
  • raw 2,5 seconds
  • checkstyle 2,5 seconds

ondrej's suggestions:

  • Limit the number of errors printed to 1000 max
  • Recommend lower rule level
  • Recommend PHPStan Pro for more comfortable error browsing
  • As a last resort tell them about an env variable they can set to show all errors

Did PHPStan help you today? Did it make you happy in any way?

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions