PHPackages                             jdecool/phpstan-report - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. jdecool/phpstan-report

ActiveProject[Testing &amp; Quality](/categories/testing)

jdecool/phpstan-report
======================

Enhance PHPStan analysis by providing report analysis

0.13.0(6mo ago)730.7k↓18.3%[1 PRs](https://github.com/jdecool/phpstan-report/pulls)MITPHPPHP ^8.1CI passing

Since Aug 22Pushed 5mo ago1 watchersCompare

[ Source](https://github.com/jdecool/phpstan-report)[ Packagist](https://packagist.org/packages/jdecool/phpstan-report)[ RSS](/packages/jdecool-phpstan-report/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (13)Versions (24)Used By (0)

PHPStan Report
==============

[](#phpstan-report)

[![Build Status](https://github.com/jdecool/phpstan-report/actions/workflows/ci.yaml/badge.svg)](https://actions-badge.atrox.dev/jdecool/phpstan-report/goto?ref=main)[![License](https://camo.githubusercontent.com/51864739b4e5d62a5dbdcccbdc9595575397c6dcbf4c6752d9dfc4414612c24f/68747470733a2f2f706f7365722e707567782e6f72672f6a6465636f6f6c2f7068707374616e2d7265706f72742f6c6963656e7365)](https://packagist.org/packages/jdecool/phpstan-report)[![Latest Stable Version](https://camo.githubusercontent.com/cd6545e73efd033156092b14434e2284bae42de7240c07b99595e14114056a20/68747470733a2f2f706f7365722e707567782e6f72672f6a6465636f6f6c2f7068707374616e2d7265706f72742f762f737461626c65)](https://packagist.org/packages/jdecool/phpstan-report)[![Latest Unstable Version](https://camo.githubusercontent.com/e5cc90135643b6a5b45b6c725da83d95249e59b6561a1ddc0ed015c541ecaf39/68747470733a2f2f706f7365722e707567782e6f72672f6a6465636f6f6c2f7068707374616e2d7265706f72742f762f756e737461626c65)](https://packagist.org/packages/jdecool/phpstan-report)

A simple wrapper around PHPStan to extends PHPStan's functionality by providing a customizable report generation feature. It allows you to run PHPStan analysis and generate reports on ignored errors in various formats.

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require --dev jdecool/phpstan-report
```

Usage
-----

[](#usage)

This package provides two main commands:

### Analyze Command

[](#analyze-command)

The `analyze` command runs PHPStan analysis and generates reports on ignored errors:

```
php vendor/bin/phpstan-report analyze
```

#### Options

[](#options)

- `--report-output-format`: Specify the output format for the report
- `--report-without-analyze`: Generate a report without running the PHPStan analysis
- `--report-continue-on-error`: Continue report generation even if the analysis fails
- `--report-maximum-allowed-errors`: Set the maximum number of allowed errors
- `--report-sort-by`: Sort the report results (options: identifier, occurrence)
- `--report-exclude-identifier`: Identifier to exclude from the report (accepts multiple values)
- `--report-file-`: Export report in an output file for a particular format
- `--report-http-target-url`: The target URL to send the report to (available only if output format is `http`)
- `--report-http-add-header`: Add a header to the HTTP request (available only if output format is `http`)
- `--report-gitlab-severity-mapping`: JSON string mapping error identifiers to GitLab severity levels (available only if output format is `gitlab`)

Available formats are: `text`, `html`, `http`, `json`, `gitlab` and `heatmap`.

For a full list of options, run:

```
php vendor/bin/phpstan-report analyze --help
```

### View Command

[](#view-command)

The `view` command displays detailed information about specific ignored errors from the PHPStan result cache:

```
php vendor/bin/phpstan-report view  [...]
```

This command allows you to examine specific error identifiers without running a new analysis.

#### Options

[](#options-1)

- `--refresh-cache`: Refresh PHPStan cache by running a new analysis before viewing errors

The `view` command takes error identifiers as arguments and displays detailed information about those errors in a table format showing:

- Error identifier
- Error message
- File path
- Line number

For help with the view command, run:

```
php vendor/bin/phpstan-report view --help
```

Examples
--------

[](#examples)

Run analysis and generate a text report:

```
php vendor/bin/phpstan-report analyze src tests
```

Generate an HTML report without running analysis:

```
php vendor/bin/phpstan-report analyze --report-without-analyze --report-output-format=html
```

Run analysis, continue on error, and save report to a file:

```
php vendor/bin/phpstan-report analyze --report-continue-on-error --report-file-json=report.json src
```

Generate a heatmap report of files with most ignored errors:

```
php vendor/bin/phpstan-report analyze --report-file-heatmap=heatmap.svg src
```

Generate a GitLab report with custom severity mapping:

```
php vendor/bin/phpstan-report analyze --report-output-format=gitlab \
  --report-gitlab-severity-mapping='{"missingType.property":"info","argument.type":"critical"}' src
```

For more details on GitLab severity mapping, see [docs/gitlab-severity-mapping.md](docs/gitlab-severity-mapping.md).

### View Command Examples

[](#view-command-examples)

View details about a specific error identifier:

```
php vendor/bin/phpstan-report view "missingType.iterableValue"
```

View details about multiple error identifiers:

```
php vendor/bin/phpstan-report view "missingType.iterableValue" "nullCoalesce.expr"
```

###  Health Score

43

—

FairBetter than 91% of packages

Maintenance68

Regular maintenance activity

Popularity33

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 99.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~22 days

Recently: every ~51 days

Total

20

Last Release

199d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/a648f4457ad94c2fc48782bded875f3bf051b480fd2fe01eb7654b9fab180e5e?d=identicon)[jdecool](/maintainers/jdecool)

---

Top Contributors

[![jdecool](https://avatars.githubusercontent.com/u/433926?v=4)](https://github.com/jdecool "jdecool (117 commits)")[![google-labs-jules[bot]](https://avatars.githubusercontent.com/in/842251?v=4)](https://github.com/google-labs-jules[bot] "google-labs-jules[bot] (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/jdecool-phpstan-report/health.svg)

```
[![Health](https://phpackages.com/badges/jdecool-phpstan-report/health.svg)](https://phpackages.com/packages/jdecool-phpstan-report)
```

###  Alternatives

[sylius/sylius

E-Commerce platform for PHP, based on Symfony framework.

8.4k5.6M651](/packages/sylius-sylius)[simplesamlphp/simplesamlphp

A PHP implementation of a SAML 2.0 service provider and identity provider.

1.1k12.4M193](/packages/simplesamlphp-simplesamlphp)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[infection/infection

Infection is a Mutation Testing framework for PHP. The mutation adequacy score can be used to measure the effectiveness of a test set in terms of its ability to detect faults.

2.2k26.2M1.8k](/packages/infection-infection)[phpbench/phpbench

PHP Benchmarking Framework

2.0k13.0M627](/packages/phpbench-phpbench)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
