Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
d495627
feat: add github annotations reporter
OrenMe Feb 14, 2025
2ca9816
add docs
OrenMe Feb 15, 2025
9c66cb1
lint fix
OrenMe Feb 15, 2025
841c587
Merge branch 'main' into feat/githubAnnotations
OrenMe Feb 15, 2025
890c71e
Merge remote-tracking branch 'refs/remotes/origin/feat/githubAnnotati…
OrenMe Feb 15, 2025
239a7f2
Merge branch 'main' into feat/githubAnnotations
OrenMe Feb 15, 2025
fc9962b
lint fix
OrenMe Feb 15, 2025
6188552
Merge branch 'main' into feat/githubAnnotations
OrenMe Feb 15, 2025
a16f978
Update cli.py
OrenMe Feb 17, 2025
4ca19af
Update python/deptry/cli.py
OrenMe Feb 19, 2025
132d1f7
CR comments
OrenMe Feb 19, 2025
77bbe53
Merge remote-tracking branch 'refs/remotes/origin/feat/githubAnnotati…
OrenMe Feb 19, 2025
a33bae1
Update docs/usage.md
OrenMe Feb 19, 2025
a7f6f89
more CR fixes
OrenMe Feb 19, 2025
8950f31
Merge remote-tracking branch 'refs/remotes/origin/feat/githubAnnotati…
OrenMe Feb 19, 2025
b483f72
Merge branch 'main' into feat/githubAnnotations
OrenMe Feb 21, 2025
36bca11
Merge branch 'main' into feat/githubAnnotations
OrenMe Feb 23, 2025
54c6f05
Merge branch 'main' into feat/githubAnnotations
OrenMe Mar 16, 2025
4b457a1
Merge branch 'main' of github.com:fpgmaas/deptry into feat/githubAnno…
mkniewallner Nov 7, 2025
261aa89
feat(reporters): handle violations without line/column
mkniewallner Nov 7, 2025
c7fa470
test: add functional tests for GitHub reporter
mkniewallner Nov 7, 2025
a26e41c
docs(usage): tweak documentation
mkniewallner Nov 7, 2025
4324cff
test: use tuple for `github_warning_errors` arg
mkniewallner Nov 7, 2025
1c4bbbd
fix(cli): use tuple for `github_warning_errors` arg
mkniewallner Nov 7, 2025
e6f76d8
refactor(reporters): code/message are never `None`
mkniewallner Nov 7, 2025
7fe1324
test: windows, as usual
mkniewallner Nov 8, 2025
23031df
test: more windows
mkniewallner Nov 8, 2025
9517654
Merge branch 'main' into feat/githubAnnotations
mkniewallner Nov 8, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add docs
  • Loading branch information
OrenMe committed Feb 15, 2025
commit 2ca9816bda5e63ace3c9c5db96e7061ac7714517
30 changes: 30 additions & 0 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,36 @@ json_output = "deptry_report.txt"
deptry . --json-output deptry_report.txt
```

#### GitHub Reporter
When enabled with the `--github-output` flag, deptry prints GitHub Actions annotations for detected dependency issues.

Annotations follow this format:
```shell
::error file=<file>,line=<line>,col=<column>,title=<error_code>::<error message>
```
By default, violations are annotated as errors. To report specific violation codes as warnings instead, use the `--github-warning-errors` option. For example, to treat violations with code `DEP001` as warnings:
```shell
deptry . --github-output --github-warning-errors DEP001
```
When a violation's error code is included in the warning list, the annotation uses the `warning` severity.

- Type: `bool` (for `github_output`), `list[str]` (for `github_warning_errors`)
- Default: `False` (for `github_output`), `[]` (for `github_warning_errors`)
- `pyproject.toml` option names: `github_output`, `github_warning_errors`
- CLI option names: `--github-output`, `--github-warning-errors`

- `pyproject.toml` example:
```toml
[tool.deptry]
github_output = true
github_warning_errors = ["DEP001"]
```

- CLI example:
```shell
deptry . --github-output --github-warning-errors DEP001
```

#### Package module name map

Deptry will automatically detect top level modules names that belong to a
Expand Down