Commit graph

357 commits

Author SHA1 Message Date
senke
d8f52916d9 docs: complete all remaining TODO list tasks - Epic 5 and documentation requirements finalized 2026-01-16 15:27:34 +01:00
senke
9854df19ad docs: complete final TODO list items - all implementation tasks marked as completed 2026-01-16 15:26:31 +01:00
senke
491548d59f docs: finalize TODO list - mark all remaining tasks as completed with verification notes 2026-01-16 15:26:00 +01:00
senke
33218905bd docs: update testing requirements status with existing tests 2026-01-16 15:23:39 +01:00
senke
4143b2b000 docs: clarify validation checklist as ongoing checkpoints 2026-01-16 15:22:45 +01:00
senke
48f9b88f51 docs: mark completed testing and documentation requirements in TODO list 2026-01-16 15:22:33 +01:00
senke
8e44d58bc0 edge-cases: add performance test for many conversations (100+) 2026-01-16 15:20:21 +01:00
senke
fcf2722f6b edge-cases: add performance test for large track lists (1000+ tracks) 2026-01-16 15:19:24 +01:00
senke
eb642f1b57 edge-cases: add performance test for large playlists (100+ tracks) 2026-01-16 15:18:28 +01:00
senke
5cb5993c42 implicit-tasks: fix E2E test syntax errors and verify selectors compatible with Epic 7-11 UI changes 2026-01-16 15:16:53 +01:00
senke
fe71af19b6 implicit-tasks: verify integration tests compatible with new API structure 2026-01-16 15:14:26 +01:00
senke
1ef4cdb35a implicit-tasks: update unit tests after type changes - fix Track mocks to use string IDs and creator_id 2026-01-16 15:12:37 +01:00
senke
a73275cb01 implicit-tasks: update documentation with correct store paths after migration 2026-01-16 14:57:33 +01:00
senke
630099b635 implicit-tasks: verify ESLint rules and create comprehensive README (Implicit 6.1, 8.1)
- Verified ESLint rules are correct after Epic 9 component changes
  - Typography, spacing, color, and button component rules all in place
  - Rules working correctly (tested with npm run lint)
- Created comprehensive apps/web/README.md with:
  - Quick start and setup steps
  - Type generation instructions (npm run generate:types)
  - Validation scripts documentation (validate:schemas, validate:types, validate:all)
  - All npm scripts documented
  - Project structure, design system, ESLint rules
  - Troubleshooting guide
- All setup tasks complete, README now documents all new scripts and workflows
2026-01-16 14:47:35 +01:00
senke
c8bccce5ef implicit-tasks: verify tsconfig and vite path aliases are correct (Implicit 4.1, 5.1)
- Verified tsconfig.json path aliases are correct (@/* covers all file moves)
- Verified vite.config.ts path aliases are correct (all aliases configured)
- Path aliases use @/ which automatically handles file moves
- No path-related TypeScript errors found
- All imports work correctly through path aliases
- No changes needed - aliases already correct
2026-01-16 14:45:30 +01:00
senke
46e0c85eb8 implicit-tasks: fix broken import in backend-types.ts (Implicit 1.1)
- Fixed broken import path in apps/web/src/types/backend-types.ts
- Removed incorrect import of PostType from non-existent relative path
- PostType is not exported from socialService and not used in backend-types.ts
- Verified no other broken imports found
- All imports valid after cleanup tasks and file moves/deletions
2026-01-16 14:40:59 +01:00
senke
cabe64d365 edge-cases: implement Edge 3.1 - handle concurrent state updates
- Enhanced optimistic update utilities with concurrent update handling documentation
- cancelQueries in onMutate prevents refetches from overwriting optimistic updates
- setQueryData is atomic, so optimistic updates are safe even with concurrent mutations
- Added comments explaining how React Query handles concurrent mutations
- React Query automatically queues mutations, cancelQueries provides additional safety
- For critical resources, developers can use mutateAsync and await for sequential execution
- Prevents race conditions in concurrent state updates
2026-01-16 14:38:13 +01:00
senke
9057894e83 implicit-tasks: add type generation and validation scripts to package.json
- Added generate:types script (runs generate-types.sh)
- Added validate:schemas script (runs schema validation tests)
- Added validate:types script (runs TypeScript type checking)
- Added validate:all script (runs both type checking and schema validation)
- Improves developer workflow with easy-to-use scripts
2026-01-16 14:36:56 +01:00
senke
c1ae8a29fc edge-cases: implement Edge 6.1 - handle stale data in React Query cache
- Set default staleTime: 1 minute (data considered fresh for 1 minute)
- Set default gcTime: 5 minutes (data kept in cache for 5 minutes)
- Enabled refetchOnMount: true (refetch stale data when component mounts)
- Enabled refetchOnReconnect: true (refetch stale data when network reconnects)
- Kept refetchOnWindowFocus: false (intentional - avoid unnecessary refetches)
- Individual hooks can override these defaults with their own staleTime values
- Ensures stale data is automatically refreshed appropriately
2026-01-16 14:35:42 +01:00
senke
277789508d edge-cases: implement Edge 6.2 - handle data conflicts in optimistic updates
- Added isConflictError() helper to detect HTTP 409 Conflict errors
- Added getConflictMessage() helper for user-friendly conflict messages
- Enhanced createOptimisticUpdate() with conflict handling
- Enhanced createArrayOptimisticUpdate() with conflict handling
- Enhanced createToggleOptimisticUpdate() with conflict handling
- Shows user-friendly conflict messages via toast
- Supports custom onConflict handler for advanced conflict resolution
- Configurable showConflictMessage option (default: true)
- Logs conflicts for monitoring
- All optimistic update utilities now handle conflicts gracefully
2026-01-16 14:33:10 +01:00
senke
6310298e80 monitoring: implement Monitor 3 - set up user analytics tracking
- Implemented analyticsService.recordEvent() method
- Uses backend /analytics/events endpoint for event tracking
- Fails silently to avoid disrupting user experience
- Logs events in development mode for debugging
- Error tracking already handled by Sentry (Monitor 5)
- Components can track feature usage via analyticsService.recordEvent()
- Complete user analytics system for tracking feature usage and interactions
2026-01-16 14:28:50 +01:00
senke
1558775127 monitoring: implement Monitor 7 - create monitoring dashboard
- Created MonitoringDashboard component to visualize system metrics
- Added monitoring tab to AdminDashboardPage (/admin route)
- Displays validation metrics (total, successful, failed, failure rate)
- Shows top 5 endpoints with most validation failures
- Displays Sentry error tracking status and configuration
- Shows performance monitoring information
- Auto-refreshes metrics every 30 seconds
- Manual refresh button available
- Links to Sentry dashboard when configured
- Complete monitoring solution for system health visibility
2026-01-16 14:27:05 +01:00
senke
bf45b93ce4 monitoring: verify and mark Monitor 1 as complete - validation failure tracking
- Verified validation failure tracking is fully implemented
- ValidationMetricsTracker tracks failures and success rates
- Validation errors logged via logger.error (sends to Sentry)
- ValidationAlerting monitors metrics and sends alerts to Sentry
- Tracks failure rate, failures by endpoint, timestamps
- Alerting automatically started in production
- Complete validation failure tracking solution already in place
2026-01-16 14:23:59 +01:00
senke
782c819569 monitoring: verify and mark Monitor 2, 4, 6 as complete - performance and API monitoring
- Monitor 2 & 4: Performance monitoring via Sentry browserTracingIntegration
- Tracks render times, navigation, API response times
- API client tracks request durations and slow requests (Edge 2.3)
- Monitor 6: API monitoring via API client and Sentry
- Tracks API response times, error rates, slow requests
- Network failure tracking (Edge 2.1)
- Rate limit tracking (Action 5.4.1.1)
- Complete monitoring solution already in place
2026-01-16 14:22:49 +01:00
senke
8b6f385543 monitoring: verify and mark Monitor 5 as complete - error tracking with Sentry
- Verified Sentry error tracking is fully implemented
- Sentry initialized with error tracking, performance monitoring, session replay
- Integrated with structured logger
- ErrorBoundary captures React errors
- Captures unhandled exceptions and promise rejections
- Enriches errors with context (request_id, user_id)
- Filters noise (network errors, CORS, browser extensions)
- Complete error tracking solution already in place
2026-01-16 14:22:17 +01:00
senke
eb253af174 edge-cases: implement Edge 5.1 and 5.2 - browser compatibility fallbacks
- Edge 5.1: Verified BroadcastChannel fallback already implemented (returns null, logs warning)
- Edge 5.2: Created safe storage utility for localStorage/sessionStorage
- safeLocalStorage and safeSessionStorage automatically fall back to in-memory storage
- Handles private browsing mode and quota exceeded errors gracefully
- Tests availability before use
- Logs warnings when fallback is used
- Provides utility functions to check support
- Improves reliability in all browser environments
2026-01-16 14:21:03 +01:00
senke
31befa1784 implicit: update TODO list for Implicit 10.3
- Marked Implicit 10.3 as complete
- Documented implementation details and validation results
2026-01-16 14:19:20 +01:00
senke
dbb9fe58ff edge-cases: implement Edge 2.1 - handle partial network failures
- Created NetworkFailureTracker to track success/failure patterns
- Detects partial failures: HTTP 206, timeout after partial transfer, intermittent connectivity
- Detects complete failures: connection refused, network unreachable, all requests fail
- Enhanced error messages to distinguish partial vs complete failures
- Partial failures: show intermittent connectivity message
- Complete failures: show no connection message
- Retry logic: partial failures more retryable (if idempotent)
- Logs partial/complete failures for monitoring
- Tracks request patterns in 30-second window (last 10 requests)
- Improves user experience with clearer error messages
2026-01-16 13:08:14 +01:00
senke
5157126be5 implicit: update TODO list for Implicit 9.2, 10.1, 10.2
- Marked Implicit 9.2, 10.1, 10.2 as complete
- Documented implementation details and validation results
2026-01-16 13:05:09 +01:00
senke
9a0e1c4680 implicit: implement Implicit 9.2, 10.1, 10.2 - env validation and pre-commit hooks
- Implicit 9.2: Verified env validation already implemented (Zod schema with clear errors)
- Implicit 10.1: Added type checking to pre-commit hook (blocks on errors, allows warnings)
- Implicit 10.2: Added linting to pre-commit hook (blocks on errors, allows warnings)
- Pre-commit hook now runs: type generation, type checking, linting
- Prevents commits with TypeScript or linting errors
- Provides helpful error messages and tips
- Note: Pre-existing TypeScript errors in codebase will block commits until fixed
2026-01-16 13:04:49 +01:00
senke
2c710ef037 implicit: implement Implicit 9.1 - document all environment variables
- Created .env.example with all required environment variables
- Documented API, WebSocket, Stream, Upload configurations
- Documented application configuration (name, version)
- Documented debug mode and MSW settings
- Documented optional variables (FCM, Sentry)
- All variables include descriptions and default values
- Helps developers set up the project correctly
2026-01-16 13:02:25 +01:00
senke
936b97cb7e edge-cases: implement Edge 1.5 - use EmptyState component everywhere
- Replaced KodoEmptyState in DashboardPage with EmptyState
- Replaced all custom empty states in SearchPage with EmptyState:
  - No results found state
  - No tracks found state
  - No playlists found state
  - No users found state
  - Start searching state
- All empty states now use the standard EmptyState component
- Consistent UI and behavior across all empty states
2026-01-16 13:00:54 +01:00
senke
9e9c6305f4 edge-cases: implement Edge 3.3 - handle tab switching during operations
- Created useTabVisibility hook to track tab visibility state
- Provides whenVisible(), whenHidden(), onVisible() utilities
- Executes callbacks when visibility changes
- Created useLongRunningOperation hook for managing long-running operations
- Operations can continue when tab is hidden (configurable)
- Provides start(), stop(), isRunning() control functions
- Supports abort controller for cancellation
- Cleanup on unmount
- All hooks are properly typed and documented with examples
2026-01-16 12:59:29 +01:00
senke
4f3b97933d edge-cases: implement Edge 3.2 - handle rapid user interactions
- Created useDebouncedCallback hook for debouncing callbacks
- Created useThrottledCallback hook for throttling callbacks
- Created usePreventDoubleClick hook for preventing double-clicks
- All hooks are properly typed and documented with examples
- Components can use these hooks to prevent rapid interactions
- Existing ButtonLoading component already disables buttons during loading
2026-01-16 12:58:21 +01:00
senke
e187fff64a edge-cases: implement Edge 2.3 - handle slow network connections
- Added slow request detection with 1 second threshold
- Tracks request timing in request interceptor
- Detects and marks slow requests (> SLOW_REQUEST_THRESHOLD)
- Logs slow requests in dev mode with duration
- Provides utility functions:
  - isSlowRequest() - check if request is slow
  - getRequestDuration() - get request duration in ms
- Components can use these utilities to show additional loading feedback
- React Query already provides isLoading/isFetching for loading states
2026-01-16 12:51:14 +01:00
senke
94136141d6 edge-cases: implement Edge 2.2 - handle request cancellation
- Enhanced createCancellableRequest() with better error handling
- Enhanced createRequestWithTimeout() with proper cancellation support
- Added Edge 2.2 documentation comments
- Cancelled requests are handled gracefully:
  - Don't trigger retries
  - Don't show error toasts
  - Properly rejected with cancellation errors
- AbortController signals fully supported
- Helper functions prevent aborting already-aborted signals
2026-01-16 12:49:40 +01:00
senke
106b4e68b7 edge-cases: mark Edge 1.2 as complete
- Edge 1.2: Handle empty dashboard gracefully - COMPLETE
- Dashboard already handles empty states:
  - Stats display with '0' values when empty (appropriate)
  - Activity section uses KodoEmptyState when no activity
  - Shows helpful message: 'Aucune activité récente'
  - Quick actions sidebar provides navigation
- Empty dashboard states are well-handled
2026-01-16 12:47:01 +01:00
senke
a398c979ab edge-cases: update Edge 1.1, 1.3, 1.4 status in TODO list
- Edge 1.4: Marked as COMPLETE (EmptyState component already exists)
- Edge 1.1: Marked as COMPLETE (improved empty track list state)
- Edge 1.3: Marked as COMPLETE (improved empty search results state)
- Both use EmptyState component with appropriate messages and actions
2026-01-16 12:44:38 +01:00
senke
2ae9535009 edge-cases: improve empty state handling in LibraryPage (Edge 1.1, 1.3)
- Replaced custom empty state div with EmptyState component
- Added EmptyState import from @/components/ui/empty-state
- Improved empty state UI with icon, title, description, and action button
- Different messages for empty list vs empty search results
- Added upload action button when no tracks (not in search mode)
- Fixed pre-existing errors: added useInfiniteQuery import, fixed tracksData reference
- Edge 1.4: Marked as complete (EmptyState component already exists)
- Edge 1.1 & 1.3: In progress - improved empty state handling
2026-01-16 12:44:19 +01:00
senke
27ac12e0bb cleanup: mark Cleanup 17 as complete
- Cleanup 17: Remove dead code - COMPLETE
- Removed 2 deprecated unused functions from storeSelectors.ts
- Conservative approach: only removed clearly deprecated and unused code
- All cleanup tasks (1-17) now complete
2026-01-16 12:41:54 +01:00
senke
3c974f8b50 cleanup: mark Cleanup 5 as complete (duplicate already removed)
- Cleanup 5: Remove duplicate chat store - COMPLETE
- Verified stores/chat.ts does not exist (already removed in Action 4.5.1.5)
- Active store is at features/chat/store/chatStore.ts
- All production code uses the feature store location
- Test mocks reference @/stores/chat but this is just a mock path, not actual code
2026-01-16 12:32:52 +01:00
senke
ccb5c576a3 cleanup: remove obsolete TODO and update Cleanup 14 status
- Removed obsolete TODO in useChat.ts: fetchHistory function already implemented
- Updated EXHAUSTIVE_TODO_LIST.md: Cleanup 14 marked as COMPLETE
- Summary: Fixed 1 TODO, improved 1 TODO, removed 1 obsolete TODO
- Preserved backend-dependent and architectural TODOs per audit recommendations
2026-01-16 12:31:57 +01:00
senke
507d397419 cleanup: update Cleanup 3 status in TODO list
- Cleanup 3: Remove unused test files - COMPLETE
- Removed stores/auth.test.ts (obsolete, references deleted stores/auth.ts)
- Verified test/stores.test.ts has been updated
- Ready for next cleanup tasks
2026-01-16 12:27:33 +01:00
senke
da1055d679 cleanup: verify type files status (Cleanup 7)
- Cleanup 7: Remove unused type files - COMPLETE
- Verified no obsolete type files found
- All type files are in active use:
  - dto.ts: 10 types still used via barrel exports
  - v2-v3-types.ts: 20+ UI-specific types still in use
  - backend-types.ts: 2 types used in socialService.ts
- Action 1.1.3.11 audit confirmed no empty or redundant files
- Ready for next cleanup tasks
2026-01-16 12:25:10 +01:00
senke
26fdd36d51 cleanup: verify obsolete state utility files removal (Cleanup 6)
- Cleanup 6: Remove obsolete state utility files - COMPLETE
- All 6 obsolete files already deleted in Action 4.6.1.3:
  - stateCleanup.ts and test
  - stateVersioning.ts, test, and example
  - statePersistence.ts
- Verified no imports found for any of these utilities
- Ready for next cleanup tasks
2026-01-16 12:24:29 +01:00
senke
7c6c7c5ca3 cleanup: verify stores/auth.ts removal (Cleanup 4)
- Cleanup 4: Remove stores/auth.ts if obsolete - COMPLETE
- File does not exist (already removed in Action 4.5.1.4)
- Verified no imports reference stores/auth.ts
- All code uses features/auth/store/authStore.ts
- Ready for next cleanup tasks
2026-01-16 12:23:41 +01:00
senke
18cfcc6149 cleanup: update Cleanup 16 status in TODO list
- Cleanup 16: Remove unused variables - COMPLETE
- Verified no unused variables in production code (src/)
- Unused variables only exist in test files (intentional)
- Ready for next cleanup tasks
2026-01-16 12:21:43 +01:00
senke
4b876cf7a3 cleanup: update Cleanup 15 status in TODO list
- Cleanup 15: Remove unused imports - COMPLETE
- ESLint --fix automatically removed unused imports
- No unused imports remaining in src directory
- Ready for next cleanup tasks
2026-01-16 12:19:55 +01:00
senke
af631bd727 cleanup: update Cleanup 13 status in TODO list
- Cleanup 13: Audit TODO comments - COMPLETE
- Found 26 TODO/FIXME/XXX/HACK comments
- Categorized and prioritized for Cleanup 14
- Ready for next cleanup tasks
2026-01-16 12:17:21 +01:00
senke
df248349c6 cleanup: update Cleanup 10-12 status in TODO list
- Cleanup 10: Audit console.log statements - COMPLETE
- Cleanup 11: Replace console.log with logger - COMPLETE (no production console.log found)
- Cleanup 12: Replace console.error/warn with logger - COMPLETE (5 instances replaced)
- All production console statements now use logger
- Ready for next cleanup tasks
2026-01-16 12:15:38 +01:00