Skip to content

Commit d07c443

Browse files
committed
fix: lower tech-debt "no changes" threshold to 2 lines
The strong/weak split in #28 moved the commit URLs out of `report` and into `reportFooter` (called after `prSummaryReport`), but the `-le 5` threshold was kept. After that refactor the filtered report only carries two boilerplate header lines, so any PR changing three or fewer counters of a given level got silently reported as "no changes" — e.g. leanprover-community/mathlib4#39932 removed one `set_option backward.isDefEq.respectTransparency false in` without the bot noting it. Drop the threshold to 2 so a single non-zero change is reported. 🤖 Prepared with Claude Code
1 parent aafe3df commit d07c443

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

scripts/reporting/technical-debt-metrics.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,11 @@ prSummaryReport () {
191191
level="${1}"
192192
rep="${2}"
193193

194-
if [ "$(wc -l <<<"${rep}")" -le 5 ]
194+
# After the `awk` filter in the caller, `rep` always contains the two boilerplate
195+
# table-header lines (`|Current number|Change|Type|` and `|-:|:-:|:-|`).
196+
# Any further line corresponds to a counter whose value changed, so a report
197+
# with two or fewer lines means "nothing to report".
198+
if [ "$(wc -l <<<"${rep}")" -le 2 ]
195199
then
196200
printf '<details><summary>No changes to %s technical debt.</summary>\n' "${level}"
197201
return 1

0 commit comments

Comments
 (0)