mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-27 07:52:24 +00:00
- Replaced unbounded `Promise.all` with `pMap` and `RELAY_BACKGROUND_CONCURRENCY || 3` in `js/nostr/dmSignalEvents.js` and `js/services/dmNostrService.js` to prevent network saturation. - Updated `scripts/check-hex.js` to exclude agent artifact directories (`perf/`, `test_logs/`, `context/`, etc.) to prevent lint failures when agents log code snippets or hex codes. - Increased `maxBuffer` in `scripts/check-hex.js` to 10MB to be robust against large matches. - Updated `js/services/exploreDataService.js` to trigger immediate data refresh (`refreshWatchHistoryTagCounts` and `refreshTagIdf`) when visibility state changes to visible, fixing a unit test failure. - Includes daily performance report and context logs. Co-authored-by: PR0M3TH3AN <[email protected]>
1.5 KiB
1.5 KiB
Daily Performance Report: 2026-02-15
Summary: Visibility gating implemented for LoginModalController to reduce background CPU usage. Upload documentation verified.
Findings
P2: Background CPU Usage
- File:
js/ui/loginModalController.js - Issue: Uses
setInterval(500ms) for modal close polling (fallback for MutationObserver) which runs even when the tab is hidden. - Fix: Implemented
handleVisibilityto clear the interval whendocument.hiddenis true, and restart it when visible. - Status: Fixed.
Verified Existing Mitigations
js/services/exploreDataService.js: Already useshandleVisibilityto gatewatchHistoryIntervalandtagIdfInterval.js/app/playbackCoordinator.js: Already usesdocument.visibilityStatecheck and visibility handlers fortorrentStatusIntervalId.
P2: Upload Performance
- File:
js/storage/s3-multipart.js - Observation: Uses 5MB minimum part size for S3 multipart uploads. Correctly continues upload in background (doesn't pause on hidden), which is desired for user uploads.
- Docs: Verified
/content/docs/guides/upload-content.mdaligns with code (multipart upload, client-side hashing memory note).
Metrics
- Login Time: Not measured in this run.
- Queue Sizes: Not measured.
Actions
- Code Change: Updated
js/ui/loginModalController.jsto add visibility gating. - Documentation: Confirmed alignment of upload docs.
Blockers
- None.