-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Dashboard - tests and infrastructure #288
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR extends the copyright header checker script to support JavaScript/TypeScript files in addition to Python files, and adds comprehensive dashboard implementation with test setup files. The changes support multiple file extensions with appropriate comment prefixes.
Key Changes:
- Extended
check_headers.pyto validate copyright headers in JS/TS files (.js,.jsx,.ts,.tsx,.mjs,.mts,.cjs,.cts) - Added comprehensive dashboard infrastructure including Vitest setup with Python server integration
- Implemented test utilities, pages, components, and store configuration
- Added numerous new files with proper copyright headers
Reviewed Changes
Copilot reviewed 84 out of 87 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
scripts/check_headers.py |
Extended to support multiple file types with configurable comment prefixes |
dashboard/vitest.setup.mjs |
Vitest configuration with Python server lifecycle management |
dashboard/vite.config.mjs |
Vite build and test configuration |
dashboard/tsconfig.json |
TypeScript compiler configuration |
dashboard/test-utils/*.ts |
Test utility functions and server setup helpers |
dashboard/src/**/*.tsx |
Page components, layouts, and UI implementation |
dashboard/src/**/*.ts |
State management, type definitions, and utilities |
dashboard/static/mockServiceWorker.js |
MSW service worker for mocking |
Comments suppressed due to low confidence (1)
scripts/check_headers.py:28
- The condition
not prefix.endswith(' ')is unnecessary since none of the prefixes inCOMMENT_PREFIX_BY_SUFFIXend with a space. All prefixes are either#or//, neither of which ends with a space. This condition can be simplified to always usef'{prefix} {HEADER_TEXT}'.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| } | ||
| return a.createdAt - b.createdAt; | ||
| }) | ||
| .at(-1)!; |
Copilot
AI
Nov 10, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using non-null assertion operator (!) after .at(-1) assumes the array is non-empty, but this is already checked at line 20-22. However, for clarity and type safety, consider returning the value directly from the sort instead of asserting non-null, or add an explicit check before the assertion.
| return; | ||
| } | ||
|
|
||
| if (!disposed && activeController === controller) { |
Copilot
AI
Nov 10, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This negation always evaluates to true.
No description provided.