fix(ci): repair scheduled pre-commit drift - #43603
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #43603 +/- ##
==========================================
- Coverage 79.13% 79.13% -0.01%
==========================================
Files 2879 2879
Lines 165764 165764
Branches 38320 38320
==========================================
- Hits 131178 131176 -2
- Misses 32103 32105 +2
Partials 2483 2483
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Code Review Agent Run #8e90d5
Actionable Suggestions - 1
-
superset-frontend/src/dashboard/actions/dashboardLayout.ts - 1
- Operator Precedence Breaks Move Guard · Line 312-317
Review Details
-
Files reviewed - 5 · Commit Range:
6555936..6555936- superset-core/src/superset_core/semantic_layers/layer.py
- superset-frontend/src/dashboard/actions/dashboardLayout.ts
- superset-frontend/src/dataMask/reducer.ts
- superset-frontend/src/explore/components/controls/ColumnConfigControl/types.ts
- superset/semantic_layers/models.py
-
Files skipped - 0
-
Tools
- MyPy (Static Code Analysis) - ✔︎ Successful
- Astral Ruff (Static Code Analysis) - ✔︎ Successful
- Whispers (Secret Scanner) - ✔︎ Successful
- Detect-secrets (Secret Scanner) - ✔︎ Successful
- Eslint (Linter) - ✔︎ Successful
Bito Usage Guide
Commands
Type the following command in the pull request comment and save the comment.
-
/review- Manually triggers an incremental AI Review. -
/review full- Manually triggers a full AI Review. -
/pause- Pauses automatic reviews on this pull request. -
/resume- Resumes automatic reviews. -
/resolve- Marks all Bito-posted review comments as resolved. -
/abort- Cancels all in-progress reviews.
Refer to the documentation for additional commands.
Configuration
This repository uses Superset You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.
Documentation & Help
| source && | ||
| !( | ||
| // ensure it has moved | ||
| (destination.id === source.id && destination.index === source.index) | ||
| destination.id === source.id && destination.index === source.index | ||
| ) | ||
| ) { |
There was a problem hiding this comment.
Removing the parentheses changes operator precedence. ! binds tighter than &&, so the new expression parses as (!destination.id === source.id) && destination.index === source.index. The sub-expression !destination.id === source.id compares a boolean to a string and is always false, so moveComponent will essentially never be dispatched, breaking dashboard drag-and-drop. The existing test should move a component if the component is not new in dashboardLayout.test.ts would fail. Restore the parentheses around the inner AND.
Code suggestion
Check the AI-generated fix before applying
| source && | |
| !( | |
| // ensure it has moved | |
| (destination.id === source.id && destination.index === source.index) | |
| destination.id === source.id && destination.index === source.index | |
| ) | |
| ) { | |
| source && | |
| !( | |
| // ensure it has moved | |
| (destination.id === source.id && destination.index === source.index) | |
| ) | |
| ) { |
Code Review Run #8e90d5
Should Bito avoid suggestions like this for future reviews? (Manage Rules)
- Yes, avoid them
SUMMARY
Repairs the deterministic failures reported by the scheduled all-files pre-commit workflow:
column_formatsvalue type to matchExplorableDatasuperset_core.semantic_layersThis is an automation-owned replacement for the overlapping work in #43366. That PR correctly includes the MyPy, Ruff, and
ColumnConfigControl/types.tschanges, but omits the reported Oxfmt rewrites indashboardLayout.tsanddataMask/reducer.ts.BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
Not applicable; this changes type/lint/format output only.
TESTING INSTRUCTIONS
pre-commit run mypy --all-filesruff check superset-core/src/superset_core/semantic_layers/layer.pynpx oxfmt --check --no-error-on-unmatched-pattern -- src/dashboard/actions/dashboardLayout.ts src/dataMask/reducer.ts src/explore/components/controls/ColumnConfigControl/types.tsfromsuperset-frontendpre-commit run --all-fileswas executed before push. The repair-specific hooks pass; the local full sweep also reported unrelated baseline lint findings and missing generated frontend/docs build outputs.ADDITIONAL INFORMATION