Skip to content

Fix insights#642

Merged
feruzm merged 2 commits into
developfrom
ins
Feb 3, 2026
Merged

Fix insights#642
feruzm merged 2 commits into
developfrom
ins

Conversation

@feruzm
Copy link
Copy Markdown
Member

@feruzm feruzm commented Feb 3, 2026

Summary by CodeRabbit

  • Bug Fixes
    • Fixed date-range handling in Profile → Insights so statistics match the selected period.
    • Resolved mismatches between chosen filters (day, 7d, 30d, all) and displayed results.
    • Improved reliability when switching date ranges—metrics now update consistently without stale values.
    • Ensures visitor, pageview, and visit-duration metrics reflect the selected time frame.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Feb 3, 2026

📝 Walkthrough

Walkthrough

Changed analytics query options to accept a scalar string dateRange instead of a string array; updated the query key and request payload accordingly. Updated the profile insights page to pass a scalar dateRange. Also bumped package versions and updated changelogs for sdk and wallets.

Changes

Cohort / File(s) Summary
Analytics Query Options API
packages/sdk/src/modules/analytics/queries/get-page-stats-query-options.ts
Switched dateRange parameter type from string[] to string; updated function signature, queryKey composition, request body date_range to send a string, and parameter docs.
Profile Insights Page Usage
apps/web/src/app/(dynamicPages)/profile/[username]/insights/_page.tsx
Callsite updated to pass a scalar dateRange (string or undefined) to getPageStatsQueryOptions instead of an array.
Package metadata & changelogs
packages/sdk/CHANGELOG.md, packages/sdk/package.json, packages/wallets/CHANGELOG.md, packages/wallets/package.json
Bumped versions to 1.5.26 and added corresponding changelog entries; wallets changelog updated to reflect dependency bump to SDK 1.5.26.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

Hop hop — a single string I bring,
Gone the array, a tidier thing.
Keys line up, payload sings light,
Insights fetch on clearer flight.
— a rabbit's small delight 🐇✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title concisely describes the main intent of the changeset, focusing on fixing the insights feature.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch ins

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 and usage tips.

@feruzm feruzm marked this pull request as draft February 3, 2026 15:41
@feruzm feruzm marked this pull request as ready for review February 3, 2026 15:42
@feruzm feruzm added the patch Bug fixes and patches (1.0.0 → 1.0.1), add this only if any packages/ have patch changes in PR label Feb 3, 2026
@feruzm feruzm merged commit 8564d29 into develop Feb 3, 2026
1 check passed
@feruzm feruzm deleted the ins branch February 3, 2026 15:55
@coderabbitai coderabbitai Bot mentioned this pull request Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

patch Bug fixes and patches (1.0.0 → 1.0.1), add this only if any packages/ have patch changes in PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant