Repository navigation
ci: notify Slack when release jobs fail, are cancelled, or never run - #314
Conversation
posthog-php-fork_curl Compliance ReportDate: 2026-11-10T14:31:48.878840+00:00
|
| Test | Status | Duration |
|---|---|---|
| Format Validation.Event Has Required Fields | ✅ | 37ms |
| Format Validation.Event Has Uuid | ✅ | 529ms |
| Format Validation.Event Has Lib Properties | ✅ | 532ms |
| Format Validation.Distinct Id Is String | ✅ | 532ms |
| Format Validation.Token Is Present | ✅ | 532ms |
| Format Validation.Custom Properties Preserved | ✅ | 531ms |
| Format Validation.Event Has Timestamp | ✅ | 533ms |
| Format Validation.Non Utc Event Timestamp Is Converted To Utc | ✅ | 536ms |
| Retry Behavior.Retries On 503 | ✅ | 5853ms |
| Retry Behavior.Does Not Retry On 400 | ✅ | 2535ms |
| Retry Behavior.Does Not Retry On 401 | ✅ | 2535ms |
| Retry Behavior.Respects Retry After Header | ❌ | 6349ms |
| Retry Behavior.Implements Backoff | ✅ | 16279ms |
| Retry Behavior.Retries On 500 | ✅ | 5650ms |
| Retry Behavior.Retries On 502 | ✅ | 5647ms |
| Retry Behavior.Retries On 504 | ✅ | 5645ms |
| Retry Behavior.Max Retries Respected | ✅ | 16281ms |
| Deduplication.Generates Unique Uuids | ✅ | 541ms |
| Deduplication.Preserves Uuid On Retry | ✅ | 5645ms |
| Deduplication.Preserves Uuid And Timestamp On Retry | ✅ | 10865ms |
| Deduplication.Preserves Uuid And Timestamp On Batch Retry | ✅ | 5649ms |
| Deduplication.No Duplicate Events In Batch | ✅ | 542ms |
| Deduplication.Different Events Have Different Uuids | ✅ | 533ms |
| Compression.Sends Gzip When Enabled | ✅ | 535ms |
| Batch Format.Uses Proper Batch Structure | ✅ | 532ms |
| Batch Format.Flush With No Events Sends Nothing | ✅ | 521ms |
| Batch Format.Multiple Events Batched Together | ✅ | 520ms |
| Error Handling.Does Not Retry On 403 | ✅ | 2533ms |
| Error Handling.Does Not Retry On 413 | ✅ | 2535ms |
| Error Handling.Retries On 408 | ✅ | 5648ms |
Failures
retry_behavior.respects_retry_after_header
Retry delay too short: 811ms < 2500ms
Feature_Flags Tests
✅ 17/17 tests passed
View Details
| Test | Status | Duration |
|---|---|---|
| Request Payload.Request With Person Properties Device Id | ✅ | 538ms |
| Request Payload.Flags Request Uses V2 Query Param | ✅ | 521ms |
| Request Payload.Flags Request Hits Flags Path Not Decide | ✅ | 524ms |
| Request Payload.Flags Request Omits Authorization Header | ✅ | 524ms |
| Request Payload.Token In Flags Body Matches Init | ✅ | 524ms |
| Request Payload.Groups Round Trip | ✅ | 523ms |
| Request Payload.Groups Default To Empty Object | ✅ | 523ms |
| Request Payload.Disable Geoip False Propagates As Geoip Disable False | ✅ | 524ms |
| Request Payload.Disable Geoip Omitted Defaults To False | ✅ | 524ms |
| Request Payload.Flag Keys To Evaluate Contains Only Requested Key | ✅ | 524ms |
| Request Lifecycle.No Flags Request On Init Alone | ✅ | 518ms |
| Request Lifecycle.No Flags Request On Normal Capture | ✅ | 517ms |
| Request Lifecycle.Two Flag Calls Produce Two Remote Requests | ✅ | 527ms |
| Request Lifecycle.Mock Response Value Is Returned To Caller | ✅ | 526ms |
| Retry Behavior.Retries Flags On 502 | ✅ | 625ms |
| Retry Behavior.Retries Flags On 504 | ✅ | 627ms |
| Side Effect Events.Get Feature Flag Captures Feature Flag Called Event | ✅ | 533ms |
posthog-php-lib_curl Compliance ReportDate: 2026-11-10T14:31:40.280794+00:00
|
| Test | Status | Duration |
|---|---|---|
| Format Validation.Event Has Required Fields | ✅ | 25ms |
| Format Validation.Event Has Uuid | ✅ | 520ms |
| Format Validation.Event Has Lib Properties | ✅ | 522ms |
| Format Validation.Distinct Id Is String | ✅ | 522ms |
| Format Validation.Token Is Present | ✅ | 522ms |
| Format Validation.Custom Properties Preserved | ✅ | 522ms |
| Format Validation.Event Has Timestamp | ✅ | 522ms |
| Format Validation.Non Utc Event Timestamp Is Converted To Utc | ✅ | 522ms |
| Retry Behavior.Retries On 503 | ✅ | 5830ms |
| Retry Behavior.Does Not Retry On 400 | ✅ | 2528ms |
| Retry Behavior.Does Not Retry On 401 | ✅ | 2525ms |
| Retry Behavior.Respects Retry After Header | ❌ | 6331ms |
| Retry Behavior.Implements Backoff | ✅ | 16244ms |
| Retry Behavior.Retries On 500 | ✅ | 5630ms |
| Retry Behavior.Retries On 502 | ✅ | 5631ms |
| Retry Behavior.Retries On 504 | ✅ | 5631ms |
| Retry Behavior.Max Retries Respected | ✅ | 17037ms |
| Deduplication.Generates Unique Uuids | ✅ | 236ms |
| Deduplication.Preserves Uuid On Retry | ✅ | 5629ms |
| Deduplication.Preserves Uuid And Timestamp On Retry | ✅ | 10836ms |
| Deduplication.Preserves Uuid And Timestamp On Batch Retry | ✅ | 5634ms |
| Deduplication.No Duplicate Events In Batch | ✅ | 527ms |
| Deduplication.Different Events Have Different Uuids | ✅ | 523ms |
| Compression.Sends Gzip When Enabled | ✅ | 522ms |
| Batch Format.Uses Proper Batch Structure | ✅ | 522ms |
| Batch Format.Flush With No Events Sends Nothing | ✅ | 518ms |
| Batch Format.Multiple Events Batched Together | ✅ | 511ms |
| Error Handling.Does Not Retry On 403 | ✅ | 2523ms |
| Error Handling.Does Not Retry On 413 | ✅ | 2524ms |
| Error Handling.Retries On 408 | ✅ | 5630ms |
Failures
retry_behavior.respects_retry_after_header
Retry delay too short: 803ms < 2500ms
Feature_Flags Tests
✅ 17/17 tests passed
View Details
| Test | Status | Duration |
|---|---|---|
| Request Payload.Request With Person Properties Device Id | ✅ | 522ms |
| Request Payload.Flags Request Uses V2 Query Param | ✅ | 519ms |
| Request Payload.Flags Request Hits Flags Path Not Decide | ✅ | 520ms |
| Request Payload.Flags Request Omits Authorization Header | ✅ | 519ms |
| Request Payload.Token In Flags Body Matches Init | ✅ | 520ms |
| Request Payload.Groups Round Trip | ✅ | 522ms |
| Request Payload.Groups Default To Empty Object | ✅ | 520ms |
| Request Payload.Disable Geoip False Propagates As Geoip Disable False | ✅ | 520ms |
| Request Payload.Disable Geoip Omitted Defaults To False | ✅ | 520ms |
| Request Payload.Flag Keys To Evaluate Contains Only Requested Key | ✅ | 521ms |
| Request Lifecycle.No Flags Request On Init Alone | ✅ | 516ms |
| Request Lifecycle.No Flags Request On Normal Capture | ✅ | 508ms |
| Request Lifecycle.Two Flag Calls Produce Two Remote Requests | ✅ | 523ms |
| Request Lifecycle.Mock Response Value Is Returned To Caller | ✅ | 521ms |
| Retry Behavior.Retries Flags On 502 | ✅ | 623ms |
| Retry Behavior.Retries Flags On 504 | ✅ | 622ms |
| Side Effect Events.Get Feature Flag Captures Feature Flag Called Event | ✅ | 522ms |
posthog-php-socket Compliance ReportDate: 2026-11-10T14:32:12.271589+00:00
|
| Test | Status | Duration |
|---|---|---|
| Format Validation.Event Has Required Fields | ✅ | 28ms |
| Format Validation.Event Has Uuid | ✅ | 521ms |
| Format Validation.Event Has Lib Properties | ✅ | 523ms |
| Format Validation.Distinct Id Is String | ✅ | 524ms |
| Format Validation.Token Is Present | ✅ | 523ms |
| Format Validation.Custom Properties Preserved | ✅ | 524ms |
| Format Validation.Event Has Timestamp | ✅ | 522ms |
| Format Validation.Non Utc Event Timestamp Is Converted To Utc | ✅ | 524ms |
| Retry Behavior.Retries On 503 | ✅ | 5831ms |
| Retry Behavior.Does Not Retry On 400 | ✅ | 2525ms |
| Retry Behavior.Does Not Retry On 401 | ✅ | 2526ms |
| Retry Behavior.Respects Retry After Header | ❌ | 6330ms |
| Retry Behavior.Implements Backoff | ✅ | 16241ms |
| Retry Behavior.Retries On 500 | ✅ | 5138ms |
| Retry Behavior.Retries On 502 | ✅ | 5631ms |
| Retry Behavior.Retries On 504 | ✅ | 5632ms |
| Retry Behavior.Max Retries Respected | ✅ | 16246ms |
| Deduplication.Generates Unique Uuids | ✅ | 528ms |
| Deduplication.Preserves Uuid On Retry | ✅ | 5628ms |
| Deduplication.Preserves Uuid And Timestamp On Retry | ✅ | 10840ms |
| Deduplication.Preserves Uuid And Timestamp On Batch Retry | ✅ | 5633ms |
| Deduplication.No Duplicate Events In Batch | ✅ | 527ms |
| Deduplication.Different Events Have Different Uuids | ✅ | 524ms |
| Compression.Sends Gzip When Enabled | ✅ | 522ms |
| Batch Format.Uses Proper Batch Structure | ✅ | 524ms |
| Batch Format.Flush With No Events Sends Nothing | ✅ | 518ms |
| Batch Format.Multiple Events Batched Together | ✅ | 511ms |
| Error Handling.Does Not Retry On 403 | ✅ | 2524ms |
| Error Handling.Does Not Retry On 413 | ✅ | 2524ms |
| Error Handling.Retries On 408 | ✅ | 5629ms |
Failures
retry_behavior.respects_retry_after_header
Retry delay too short: 802ms < 2500ms
Feature_Flags Tests
✅ 17/17 tests passed
View Details
| Test | Status | Duration |
|---|---|---|
| Request Payload.Request With Person Properties Device Id | ✅ | 522ms |
| Request Payload.Flags Request Uses V2 Query Param | ✅ | 520ms |
| Request Payload.Flags Request Hits Flags Path Not Decide | ✅ | 521ms |
| Request Payload.Flags Request Omits Authorization Header | ✅ | 520ms |
| Request Payload.Token In Flags Body Matches Init | ✅ | 522ms |
| Request Payload.Groups Round Trip | ✅ | 520ms |
| Request Payload.Groups Default To Empty Object | ✅ | 521ms |
| Request Payload.Disable Geoip False Propagates As Geoip Disable False | ✅ | 521ms |
| Request Payload.Disable Geoip Omitted Defaults To False | ✅ | 520ms |
| Request Payload.Flag Keys To Evaluate Contains Only Requested Key | ✅ | 522ms |
| Request Lifecycle.No Flags Request On Init Alone | ✅ | 516ms |
| Request Lifecycle.No Flags Request On Normal Capture | ✅ | 508ms |
| Request Lifecycle.Two Flag Calls Produce Two Remote Requests | ✅ | 526ms |
| Request Lifecycle.Mock Response Value Is Returned To Caller | ✅ | 522ms |
| Retry Behavior.Retries Flags On 502 | ✅ | 623ms |
| Retry Behavior.Retries Flags On 504 | ✅ | 624ms |
| Side Effect Events.Get Feature Flag Captures Feature Flag Called Event | ✅ | 523ms |
There was a problem hiding this comment.
PostHog Review · Standard · reviewed 3588e4d: 1 Should fix.
See this review and its findings in PostHog Review. Comment @posthog review --deep for a Deep review. A Deep review takes longer and looks deeper than a Standard review.
| const attempts = readdirSync(directory) | ||
| .map(name => /^release-slack-thread-(\d+)$/.exec(name)?.[1]) | ||
| .filter(value => value && Number(value) <= attempt) | ||
| .sort((a, b) => Number(b) - Number(a)); | ||
| if (attempts.length === 0) return undefined; |
There was a problem hiding this comment.
P2 · Handle the single-artifact download layout
On a first release attempt, only one thread artifact exists. The pinned download-artifact action extracts a sole match directly into THREAD_DIRECTORY, but readThreadTimestamp() only searches numbered subdirectories. First-attempt failure alerts therefore start new channel messages despite an available approval thread; handle the flat layout or explicitly preserve artifact directories.
turnipdabeets
left a comment
There was a problem hiding this comment.
LGTM. Every job and step name the notifier looks up matches this repo's release workflow, and the privileged workflow only runs code from the default branch.
[nit] This repo has no Notify Slack - Rejected job, so the rejection skip is gone. When a maintainer rejects the Release environment, the release job fails with no steps and we will post a "Release process failed" alert in the approval thread. Fine to leave as is, since it only adds noise when someone has just rejected the release.
💡 Motivation and Context
A release job that gets cancelled never reaches Slack. The failure notification is a step inside the release job gated on
failure(), and GitHub reports a job timeout, a runner it can't schedule, or a manual stop ascancelled, which stops the job before that step runs. That is howposthog-cliwent five versions without publishing before anyone noticed (PostHog/posthog#132516).Ports the release failure notification workflow from posthog-ios. It runs on
workflow_runafter every main-branchReleaserun and replies in the approval thread when a job failed, timed out, was cancelled, or never ran.release.ymlgains apreserve-slack-threadjob that saves the approval thread timestamp as a run artifact so the alert can find the thread. The in-job Slack failure replies are removed, since the notifier covers them; the PostHog failure events stay. CI-only, so no changeset. No feature flag controls this change. RELEASING.md gains a short section on the alert.💚 How did you test it?
actionlintreports nothing new andnode --checkpasses on the script. I haven't triggered a cancelled release to watch it fire.📝 Checklist
If releasing new changes
pnpm changeto generate a change intent file🤖 Agent context
DRI: @ioannisj
Autonomy: Human-driven (agent-assisted)