delivery-friction-analyzer 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/release-log.md +8 -0
- package/src/normalize/github-fixture.js +11 -2
package/package.json
CHANGED
package/release-log.md
CHANGED
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
### 2026-06-15 — Review Decision Author Detection
|
|
6
|
+
|
|
7
|
+
- What changed: Review decision evidence now recognizes human approvals from live `gh pr view` review events that include only an author login.
|
|
8
|
+
- Why it matters: Maintainers can trust `review_decision`, `human_approved`, and `human_reviewer_count` for zero-thread PRs instead of seeing approved PRs reported as having no human review.
|
|
9
|
+
- Who is affected: Maintainers and contributors running or inspecting live GitHub analysis outputs.
|
|
10
|
+
- Action needed: Re-run affected reports to refresh the corrected review decision evidence.
|
|
11
|
+
- PR: https://github.com/hannasdev/delivery-friction-analyzer/pull/32
|
|
12
|
+
|
|
5
13
|
### 2026-06-15 — Optional Narrative Drafting Guidance
|
|
6
14
|
|
|
7
15
|
- What changed: The README and friction report contract now document how to use `friction-report.json` with curated CSV evidence as sufficient context for optional downstream narrative drafting, without adding a separate model-ready artifact.
|
|
@@ -22,6 +22,15 @@ function flattenThreadComments(reviewThreads = {}) {
|
|
|
22
22
|
));
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
+
function classifyReviewEventSource(author, { pullRequestAuthorLogin } = {}) {
|
|
26
|
+
const source = classifyCommentSource(author, { pullRequestAuthorLogin });
|
|
27
|
+
const login = String(author?.login ?? "").trim();
|
|
28
|
+
if (source !== "unknown" || !login) {
|
|
29
|
+
return source;
|
|
30
|
+
}
|
|
31
|
+
return "human_reviewer";
|
|
32
|
+
}
|
|
33
|
+
|
|
25
34
|
function normalizeReview(review, { pullRequestAuthorLogin } = {}) {
|
|
26
35
|
const author = review.author ?? {};
|
|
27
36
|
return {
|
|
@@ -29,7 +38,7 @@ function normalizeReview(review, { pullRequestAuthorLogin } = {}) {
|
|
|
29
38
|
submittedAt: review.submittedAt,
|
|
30
39
|
state: review.state,
|
|
31
40
|
commitOid: review.commitOid ?? review.commit?.oid ?? null,
|
|
32
|
-
source:
|
|
41
|
+
source: classifyReviewEventSource(author, { pullRequestAuthorLogin }),
|
|
33
42
|
generatedCommentCount: review.generatedCommentCount ?? null,
|
|
34
43
|
failedAttempt: Boolean(review.failedAttempt),
|
|
35
44
|
};
|
|
@@ -77,7 +86,7 @@ function summarizeReviewDecision(pr) {
|
|
|
77
86
|
}
|
|
78
87
|
|
|
79
88
|
const humanReviews = pr.reviews.filter(review => (
|
|
80
|
-
|
|
89
|
+
classifyReviewEventSource(review.author, { pullRequestAuthorLogin: pr.author?.login }) === "human_reviewer"
|
|
81
90
|
));
|
|
82
91
|
const humanReviewerKeys = new Set(humanReviews.map(reviewAuthorKey).filter(Boolean));
|
|
83
92
|
const states = new Set(humanReviews.map(reviewState));
|