show endpoint count and how we process - #1231
Conversation
|
Warning Review limit reached
Next review available in: 59 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the 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 configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughThe dataview pipeline now fetches sources and exposes an ChangesEndpoint count data notices
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested labels: Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
Coverage Report
File Coverage
|
||||||||||||||||||||||||||||||||||||||||||||
There was a problem hiding this comment.
🧹 Nitpick comments (1)
test/unit/middleware/dataview.middleware.test.js (1)
209-209: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick winCover the complete endpoint-count contract.
The new logic has two behaviours that are not covered by the current test: counting ordinary sources and forcing zero for
authority === 'some'.
test/unit/middleware/dataview.middleware.test.js#L209-L209: add assertions for multiple sources and the special authority case.src/middleware/dataview.middleware.js#L96-L100: retain these tests as protection for both endpoint-count branches.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@test/unit/middleware/dataview.middleware.test.js` at line 209, Extend the endpoint-count tests in test/unit/middleware/dataview.middleware.test.js around the existing endpointCount fixture to assert counting multiple ordinary sources and returning zero when authority is 'some'. Retain src/middleware/dataview.middleware.js lines 96-100 unchanged; the tests should cover both existing endpoint-count branches.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@test/unit/middleware/dataview.middleware.test.js`:
- Line 209: Extend the endpoint-count tests in
test/unit/middleware/dataview.middleware.test.js around the existing
endpointCount fixture to assert counting multiple ordinary sources and returning
zero when authority is 'some'. Retain src/middleware/dataview.middleware.js
lines 96-100 unchanged; the tests should cover both existing endpoint-count
branches.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: f335cd0d-fe70-403d-bcb7-f2219295163a
📒 Files selected for processing (5)
src/middleware/dataview.middleware.jssrc/routes/schemas.jssrc/views/organisations/dataset-overview.htmlsrc/views/organisations/dataview.htmltest/unit/middleware/dataview.middleware.test.js
What type of PR is this? (check all applicable)
Description
Adds content to better explain the data shown on the dataset details and dataset table tabs.
The endpoint count is derived the same way on both tabs (from the LPA's own sources;
some/alternative-source datasets report no endpoints).Related Tickets & Documents
QA Instructions, Screenshots, Recordings
Change 1 on the dataset overview page:
Change 2 on the data view page:
Added/updated tests?