Skip to content

🚨 ci(cron-rankings): EMERGENCY add FORM4_FETCH_SKIP=1 to unblock 150m timeout#245

Merged
dackclup merged 1 commit into
mainfrom
claude/eager-bohr-12bQi
May 25, 2026
Merged

🚨 ci(cron-rankings): EMERGENCY add FORM4_FETCH_SKIP=1 to unblock 150m timeout#245
dackclup merged 1 commit into
mainfrom
claude/eager-bohr-12bQi

Conversation

@dackclup
Copy link
Copy Markdown
Owner

🚨 P1 EMERGENCY MITIGATION

compute-rankings.yml manual workflow_dispatch cancelled at the 150m timeout-minutes ceiling on 2026-05-25 00:13 UTC. Production data is now ~44h stale (last successful chore commit 9015748 Sat 2026-05-23 03:38 UTC).

Root cause (incident-commander session-8 verdict)

(δ) Budget exhausted, NOT code regression.

PR #238's filing.xml() cache-hit invariant verified intact against vendored edgartools 5.31.5 source (load-bearing-correct, ~lxml-find cost only). Root cause:

Loop Added in Cost In 150m budget?
Fundamentals × 2 Phase 2 25-50m cold
yfinance prices Phase 2 5-10m cold
Tier-2 (8-K + 10-K) Phase 4g 20-35m cold ✅ (budget set here)
Cross-source yfinance.info Phase 4b 17-67m cold partial
Form-4 fetch PR #205 (12 days ago) 20-30m cold 🚨 NOT bumped

Cache eviction over 44h Fri→Sun gap made all 5 cold simultaneously → > 150m.

Mitigation applied

Added FORM4_FETCH_SKIP: "1" to workflow-level env: block in .github/workflows/compute-rankings.yml. Form-4 fetch is observability-only (form4_enabled=False, _FORM4_FLAGS_ENABLED=False) so skipping has ZERO scoring impact:

Field With skip Without skip
Composite score identical identical
risk_flags identical identical
rankings.json identical identical
stocks/*.json identical identical
Metadata.form4_* None for this run populated

Q3 cohort-audit gate (2026-08-19) has plenty of subsequent crons to repopulate Form-4 observability.

Expected wall-clock: 12-25m on warm partial cache; up to ~90m worst-case if fundamentals/Tier-2 caches also cold (still under 150m).

After this merges

  1. User triggers workflow_dispatch again — gh workflow run compute-rankings.yml --ref main OR Actions UI button
  2. Cron commits fresh JSON to main as chore: update rankings 2026-05-25
  3. I'll auto-spawn defense-layer-auditor + stock-detail-auditor per CLAUDE.md auto-routing
  4. REVERT this PR (separate housekeeping) once Form-4 weight promotion (Phase 4.5e PR 5) needs the observability surface again

Durable follow-ups (NOT this PR — separate sessions)

  • performance-engineer issue: rebaseline timeout-minutes against 5-loop cold-cache reality (target: 300m OR off-cycle pre-cache workflow per issue Fundamentals fetch resilience to SEC API throttling #15)
  • Cache-restore canary step (size + age per cache dir, emit before fetch — surfaces eviction in 30s instead of 150m)
  • Per-loop wall-clock budget in Metadata (parity with existing fundamentals_latency_p95_seconds — add for tier2 / form4 / OSAP)
  • workflow_dispatch.inputs.*_skip UI controls so operator can mitigate without YAML edit

Files touched

File Δ Reason
.github/workflows/compute-rankings.yml +17 / −0 FORM4_FETCH_SKIP: "1" env var + extensive inline rationale
PHASE_STATUS_INFLIGHT.md +47 EMERGENCY in-flight entry with full incident timeline + durable follow-ups

CI workflow YAML change ONLY. No compute / schema / scoring / valuation / Python / TypeScript code change. CLAUDE.md + AGENTS.md substance unchanged.

Test plan

  • python3 -c "import yaml; yaml.safe_load(...)" — YAML parse OK
  • incident-commander (opus) verdict + recommendation reviewed
  • Frontend (build) CI green (doc-only)
  • Python (lint + test) CI green (doc-only)
  • Flip Draft → Ready + merge ASAP to unblock production cron
  • User triggers workflow_dispatch post-merge → verify completes < 90m
  • Post-completion: chore: update rankings 2026-05-25 commit appears on main
  • Auto-spawn defense-layer-auditor + stock-detail-auditor

https://claude.ai/code/session_01JwntEE4PNAXSMkZxRA9BB4


Generated by Claude Code

…imeout

`compute-rankings.yml` manual workflow_dispatch cancelled at the
150m timeout-minutes ceiling on 2026-05-25 00:13 UTC. Production
data ~44h stale (last successful chore commit 9015748 Sat
2026-05-23 03:38 UTC).

incident-commander session-8 verdict: (δ) BUDGET EXHAUSTED, NOT
code regression. PR #238's filing.xml() cache-hit invariant
verified intact against vendored edgartools 5.31.5 source
(~lxml-find cost only). Root cause: 150m timeout set in Phase 4g
for 4-loop reality; PR #205 added Form-4 (5th SEC EDGAR loop,
+20-30m cold) 12 days ago without bumping the budget. Cache
eviction over 44h Fri→Sun gap made all 5 cold simultaneously
→ > 150m.

Path B mitigation (user-authorized): add FORM4_FETCH_SKIP=1 to
workflow-level env block in .github/workflows/compute-rankings.yml.
Form-4 fetch is observability-only (form4_enabled=False,
_FORM4_FLAGS_ENABLED=False) so skipping has ZERO scoring impact —
composite + risk_flags + rankings + per-stock JSON all identical.
Metadata.form4_* fields coerce to None for this run; Q3
cohort-audit gate (2026-08-19) has plenty of subsequent crons.

Expected: cron completes in 12-25m on warm partial cache; up to
~90m worst-case if fundamentals/Tier-2 caches are ALSO cold
(still under 150m).

Inline YAML comment (extensive) documents the rationale +
revert-after timing. PHASE_STATUS_INFLIGHT.md in-flight entry
documents the full incident-commander timeline + durable
follow-ups (performance-engineer rebaseline + cache-restore
canary + per-loop wall-clock budget + workflow_dispatch.inputs
UI controls + post-fresh-data REVERT of this env-var).

CI workflow YAML change ONLY. No compute / schema / scoring /
valuation / Python / TypeScript code change.

https://claude.ai/code/session_01JwntEE4PNAXSMkZxRA9BB4
@vercel
Copy link
Copy Markdown

vercel Bot commented May 25, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
quantrank Ready Ready Preview, Comment May 25, 2026 12:27am

@dackclup dackclup merged commit fbbaeee into main May 25, 2026
4 checks passed
@dackclup dackclup deleted the claude/eager-bohr-12bQi branch May 25, 2026 00:32
dackclup added a commit that referenced this pull request May 26, 2026
…stale INFLIGHT markers (#267)

Phase B (post-tag housekeeping) per the v1.3.0 release plan. Pure
doc-pointer maintenance; no code touched.

Scope (3 files):
- CLAUDE.md §Phase status — Latest release tag pointer bumped
  v1.2.0-phase4.5 (6d414a9) → v1.3.0-phase4.5e (5db3b97);
  prior tag preserved as historical reference
- PHASE_STATUS.md §Current state — same pointer bump + one-line
  description of what the release closes
- PHASE_STATUS_INFLIGHT.md — 11 stale (in flight) header markers
  updated to (merged YYYY-MM-DD, SHA) with PR number prefix; PRs
  drained: #244 / #245 / #246 / #250 / #251 / #252 / #256 / #257 /
  #258 / #263 / #266. Bodies stay in place (full historical record
  preserved); future weekly housekeeping commit moves them between
  sections per PR #237 convention.

Note on tag: v1.3.0-phase4.5e was created locally during the
release session but `git push origin <tag>` failed HTTP 403 from
sandbox (proxy permits branch pushes, not tag-ref pushes). User
runs the tag commit + push from their own machine on the squash-
merge SHA 5db3b97. This PR's pointer bumps reference the tag AS
IF live per release-tag SKILL.md §7 (anchors to commit SHA, not
tag-availability state).

Markdown-only diff; ruff / schema_check / pytest N/A.

PHASE_STATUS_INFLIGHT.md side-file satisfies §Conventions "ship
with every PR" lockstep per PR #237 convention.

https://claude.ai/code/session_01JwntEE4PNAXSMkZxRA9BB4

Co-authored-by: Claude <noreply@anthropic.com>
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