Skip to content

Fix and expand conflict map alerts - #11

Merged
svg8bit merged 2 commits into
mainfrom
codex/activity-card-layout
Aug 11, 2026
Merged

Fix and expand conflict map alerts#11
svg8bit merged 2 commits into
mainfrom
codex/activity-card-layout

Conversation

@svg8bit

@svg8bit svg8bit commented Aug 11, 2026

Copy link
Copy Markdown
Owner

Summary:

  • replace pp labels with percent signs and keep YES/NO probability on one line
  • move alert metadata and actions into a stable two-row layout across desktop, landscape, and mobile
  • stop rolling signals from extending their lifetime after each feed refresh
  • cover every Polymarket conflict event with at least USD 400K total volume instead of truncating to the top 60 IDs
  • use a 10-minute rolling/snapshot lifetime, a 30-minute large-trade window, and a fresher five-minute event feed

Verification:

  • npm run check
  • npm run test:e2e: 27 passed
  • npm audit --omit=dev: 0 vulnerabilities
  • live Polymarket Data API probe: 72 eligible event IDs, HTTP 200

Summary by CodeRabbit

  • New Features

    • Activity cards now show current YES/NO odds, trade values, locations, and participant indicators.
    • Improved activity filtering prioritizes higher-volume conflict events.
    • Rolling activity signals remain consistent as live values update.
    • Activity card layouts are more structured and accessible on smaller screens.
  • Performance

    • Conflict maps and live feeds refresh more frequently.
    • Activity data updates faster with expanded event coverage and shorter caching intervals.
  • Bug Fixes

    • Improved handling of missing events and duplicate activity records.
    • Corrected activity expiration and signal freshness behavior.

@vercel

vercel Bot commented Aug 11, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
oddsfront Ready Ready Preview Aug 11, 2026 12:08pm

Request Review

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@svg8bit, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 45 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: b5f2ce0f-9bd4-4586-bdfc-187134975bf7

📥 Commits

Reviewing files that changed from the base of the PR and between 9e471bc and a901d1e.

📒 Files selected for processing (6)
  • app/api/global-conflict-activity/route.ts
  • features/global-conflict-map/preview/activity-rail.tsx
  • features/global-conflict-map/preview/types.ts
  • lib/activity-notice-lifecycle.ts
  • tests/conflict-activity-signals.spec.ts
  • tests/global-conflict-map-preview.spec.ts
📝 Walkthrough

Walkthrough

The PR centralizes Polymarket activity thresholds and event selection, shortens cache and refresh windows, stabilizes rolling signals, and updates activity-card metrics, accessibility metadata, layout, and related tests.

Changes

Polymarket activity flow

Layer / File(s) Summary
Activity selection and signal identity
lib/polymarket-activity-query.ts, lib/conflict-activity-signals.ts, tests/polymarket-activity-query.spec.ts, tests/conflict-activity-signals.spec.ts
Shared volume and event-ID limits now control activity selection and signal eligibility. Activity queries use a 30-minute window and a limit of 500. Rolling signal IDs remain stable when values change.
Feed refresh and cache windows
lib/polymarket-conflict-preview.ts, app/api/global-conflict-activity/route.ts, app/api/global-conflict-events/route.ts, app/global-conflict-map/page.tsx, app/page.tsx, tests/global-conflict-map-preview.spec.ts
Conflict feeds, API responses, and page regeneration use shorter refresh and cache windows. Activity route validation uses the shared event-ID limit and an updated cache key.
Activity rail lifecycle and presentation
features/global-conflict-map/preview/activity-rail.tsx, features/global-conflict-map/preview/conflict-map-preview.module.css, tests/global-conflict-map-preview.spec.ts
Activity notices apply shared volume filtering, shared expiration, stable rolling-notice storage, current odds or trade metrics, structured footer metadata, and responsive layout rules.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

  • svg8bit/OddsFront#8: This PR builds on its Polymarket activity routes, query utilities, and activity-rail alert logic.
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: fixing and expanding conflict map alerts.
Description check ✅ Passed The description explains the changes and verification results, but it omits the template headings and Safety checklist.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/activity-card-layout

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9e471bc493

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread lib/conflict-activity-signals.ts
Comment thread features/global-conflict-map/preview/activity-rail.tsx Outdated
@svg8bit
svg8bit enabled auto-merge (squash) August 11, 2026 11:59

@svg8bit svg8bit left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified locally and in CI: alert lifecycle, USD 400K coverage, responsive layout, and production build are all passing.

@svg8bit
svg8bit merged commit 8ff07c6 into main Aug 11, 2026
6 checks passed
@svg8bit
svg8bit deleted the codex/activity-card-layout branch August 11, 2026 12:12
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.

1 participant