Skip to content

Adjust logs pertinence#172

Merged
pfongkye merged 3 commits into
ManoManoTech:mainfrom
pfongkye:fix-webhook-error
May 20, 2026
Merged

Adjust logs pertinence#172
pfongkye merged 3 commits into
ManoManoTech:mainfrom
pfongkye:fix-webhook-error

Conversation

@pfongkye
Copy link
Copy Markdown
Contributor

Drop orphan Review rows when Slack channel is archived

When a Slack channel is archived, every chat.update / chat.postMessage from a review-flow webhook returns is_archived and the Review row keeps pointing at the dead channel — re-triggering the failure (and commit 1's webhook slack work failed log) on every subsequent MR update, note or push. Channels do get archived as a routine cleanup; treat it as an expected operational state rather than a hard error.

Demote expired_trigger_id to structured warn

errorMiddleware already replies with EXPIRED_TRIGGER_ID_ERROR_MESSAGE when Slack rejects a views.open with expired_trigger_id, but the underlying error was still logged through logger.error(error) as a bare stack trace.

Demote users_not_found to info and unify email lookup

"Failed to to fetch slack user with emails" was noisy in the logs: it covered the perfectly normal case of a GitLab user who has left the company (or is external, or has no corporate Slack account) and emitted it at error level with no structured context.

@pfongkye pfongkye requested review from cicoub13 and greg0ire May 15, 2026 14:24
@codecov
Copy link
Copy Markdown

codecov Bot commented May 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.29%. Comparing base (9314be3) to head (efa1c4a).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #172      +/-   ##
==========================================
+ Coverage   89.13%   89.29%   +0.16%     
==========================================
  Files         103      104       +1     
  Lines        2254     2269      +15     
  Branches      435      436       +1     
==========================================
+ Hits         2009     2026      +17     
+ Misses        232      230       -2     
  Partials       13       13              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread src/constants.ts Outdated
@pfongkye pfongkye force-pushed the fix-webhook-error branch from bb596a5 to 4a4c353 Compare May 20, 2026 07:19
@pfongkye pfongkye force-pushed the fix-webhook-error branch from 4a4c353 to efa1c4a Compare May 20, 2026 07:19
@pfongkye pfongkye requested a review from greg0ire May 20, 2026 07:21
@pfongkye pfongkye merged commit 9315d06 into ManoManoTech:main May 20, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants