github-community-projects / github-community-projects/pr-conflict-detector

feat: distinguish new vs. previously reported conflicts in step summary

Open
#45 1 comment 0 reactions 0 assignees View on GitHub
keep
Dominant language
Python
Stars
4
Forks
1
Avg merge
1h 13m
Merged PRs (30d)
12

Description

## Problem

The GitHub Actions step summary reports the total conflict count (e.g., "Found **37** potential conflicts across **2** repositories") but does not indicate which conflicts are new since the last run. Users scanning the summary have no way to tell what changed without comparing to the previous run manually.

For example, a recent run on `github/new-user-experience` showed:

```
Total: 37 potential conflict(s) across 2 repo(s)
Deduplication: 6 new, 0 changed, 31 unchanged, 1 resolved
```

The deduplication data is in the logs but not surfaced in the step summary. Only 6 of the 37 conflicts were new, yet the summary treats them all equally.

## Proposed Solution

Add a section to the step summary that highlights what changed since the last run:

- **New conflicts** (6) - listed prominently at the top
- **Changed conflicts** (0) - conflicts where the overlapping files/lines changed
- **Unchanged conflicts** (31) - collapsed or in a separate section
- **Resolved conflicts** (1) - conflicts that are no longer detected

This would let users quickly see "6 new conflicts to review" instead of having to mentally diff 37 total conflicts against the last run.

### Example summary structure

```
## PR Conflict Report

### 🆕 6 New Conflict(s)
[table of new conflicts]

### 🔄 0 Changed Conflict(s)

### ✅ 1 Resolved Conflict(s)
[table of resolved conflicts]

31 Unchanged Conflict(s)
[table of unchanged conflicts]

```

## Additional Context

- The deduplication module already categorizes conflicts as new/changed/unchanged/resolved
- This data is passed through as `DeduplicationResult` but the markdown writer does not use it
- The step summary and output report currently just list all conflicts without differentiation

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.