(fix) bundle the referrers map into backend builds - #607
Conversation
|
No actionable comments were generated in the recent review. π βΉοΈ Recent review infoβοΈ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: π Files selected for processing (7)
Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review. π WalkthroughWalkthroughBoth backend analytics apps now bundle and import identical referrer maps. Runtime filesystem lookup and fallback handling were removed. TypeScript JSON module resolution and tests were added. ChangesReferrer map bundling
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: βͺ Minimal Β· up to Canonical referrer filters now use a bundled map in both backend applications, restoring matching for known referrers while retaining raw-filter fallback behavior. No current merge-blocking risk remains. Suggested reviewers: π₯ 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 |
Fixes #606.
Changes
The backend loaded
web/app/referrers.map.jsonfrom disk at runtime, but that file is outside the backend Docker build context. Published API images therefore cached an empty map and canonicalreferrer_namefilters returned zero rows.resolveJsonModulein both app build configurations so the map is emitted beside the compiled module.Community Edition support
Database migrations
Documentation
Verification
dist/analytics/utils/referrers.map.json.readFileSyncfallback.Summary by CodeRabbit
New Features
Bug Fixes