You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "msyavuz (via GitHub)" <gi...@apache.org> on 2026/07/16 16:34:40 UTC

[PR] chore(deps): upgrade React 18 to 19 [superset]

msyavuz opened a new pull request, #42112:
URL: https://github.com/apache/superset/pull/42112

   ### SUMMARY
   
   Upgrades the frontend to React 19 (`react`/`react-dom`/`@types/react` 19, RTL 16, `@testing-library/dom` 10).
   
   **Draft for visibility** — rebased on current master, typecheck/lint/prettier green, but the full jest suite, a production build, and manual verification are still outstanding.
   
   Decisions worth reviewing:
   - Master independently landed the `react-loadable` → native renderer swap and the redux 4 pinning, so those commits from the original branch are dropped.
   - `reactify` silently dropped `renderFn.defaultProps` — React 19 ignores `defaultProps` on function/forwardRef components. Defaults are now merged explicitly (no compiler catches this; only its test does).
   - `@testing-library/user-event` is deliberately **not** bumped to 14. It isn't required (12.8.3 already peers `@testing-library/dom >=7.21.4`), and v14's async API would break ~1000 sync call sites while only 2 fail to compile. Separate PR if we want it.
   - AG Grid commits its rows after the initial render under React 19, so a few tests now await the grid instead of reading the DOM synchronously. The grid itself renders fine.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   N/A — dependency upgrade, no intended visual change.
   
   ### TESTING INSTRUCTIONS
   
   `npm run type`, `npm run lint`, `npm run test`. Manually exercise dashboards, Explore, and the SQL Lab results grid (AG Grid render timing changed).
   
   ### ADDITIONAL INFORMATION
   - [ ] Has associated issue: No
   - [ ] Required feature flags: None
   - [ ] Changes UI: No — no intended visual change
   - [ ] Includes DB Migration: No — frontend only
     - [ ] Migration is atomic, supports rollback & is backwards-compatible: N/A
     - [ ] Confirm DB migration upgrade and downgrade tested: N/A
     - [ ] Runtime estimates and downtime expectations provided: N/A
   - [ ] Introduces new feature or API: No
   - [ ] Removes existing feature or API: No — though `react-loadable` is removed from dependencies
   
   https://claude.ai/code/session_01W1ZGRXC5g7r9Twzdqw3fgc
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "EnxDev (via GitHub)" <gi...@apache.org>.
EnxDev commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r4163619227


##########
superset-frontend/packages/superset-ui-core/src/components/MetadataBar/MetadataBar.test.tsx:
##########
@@ -41,18 +40,32 @@ const TAGS = ['management', 'research', 'poc'];
 const A_WEEK_AGO = 'a week ago';
 const TWO_DAYS_AGO = '2 days ago';
 
+// react-resize-detector's ESM export is non-configurable, so jest.spyOn can't
+// replace it; swap the implementation through the module mock instead.
+let mockResizeImpl: ((props: any) => unknown) | null = null;

Review Comment:
   Nit, take it or leave it. The three `props: any` here are new `any`s, and `Parameters<typeof useResizeDetector>[0]` gives you the real shape for free.
   
   It would also have caught the `onResize` payload change at compile time rather than at runtime.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5667437671

   AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
   
   <details>
   <summary>
   Bito Usage Guide
   </summary>
   
   **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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
         
   **Configuration**
   
   This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
         
   **Documentation & Help**
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
   
   </details>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "sadpandajoe (via GitHub)" <gi...@apache.org>.
sadpandajoe commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r4020733314


##########
superset-frontend/plugins/plugin-chart-table/package.json:
##########
@@ -49,7 +49,7 @@
     "@testing-library/user-event": "*",
     "@types/react": "*",
     "match-sorter": "^8.2.0",
-    "react": "^18.3.0",
-    "react-dom": "^18.3.0"
+    "react": "^18.3.0 || ^19.0.0",

Review Comment:
   React 19 consumers cannot install this package under npm's normal peer resolution: it depends on \`react-table@^7.8.0\`, whose React peer stops at 18, while the root \`overrides\` used here are not inherited by the published package. Can the dependency be made React-19-compatible, or should this peer range remain at React 18?



##########
superset-frontend/src/dashboard/components/gridComponents/DynamicComponent/DynamicComponent.tsx:
##########
@@ -158,7 +158,9 @@ const DynamicComponent: FC<DynamicComponentProps> = ({
               onResizeStop={onResizeStop}
             >
               <div
-                ref={dragSourceRef}
+                ref={el => {
+                  dragSourceRef(el);

Review Comment:
   In view mode, \`DragDroppable\` omits \`dragSourceRef\`, so this ref callback calls \`undefined\` as soon as React attaches the element and the dashboard subtree crashes. The current DynamicComponent shard also has all 13 tests failing on this new callable-only assumption. Can this guard the optional connector and keep the edit-mode mock callable?



##########
superset-frontend/package.json:
##########
@@ -196,20 +196,19 @@
     "postcss": "^8.5.28",
     "query-string": "9.5.1",
     "re-resizable": "^6.11.2",
-    "react": "^18.3.0",
+    "react": "^19.2.0",
     "react-arborist": "^3.16.0",
-    "react-checkbox-tree": "^1.8.0",
+    "react-checkbox-tree": "^2.0.1",

Review Comment:
   The 2.x package renders the global controls and labels as \`.rct-actions\` and \`.rct-label\`, but \`FilterScopeSelector\` still overrides the removed \`.rct-options\` and \`.rct-title\` hooks. That makes Expand/Collapse regain the library's right alignment and lose its bottom spacing, and the root label loses its strong weight. Can those selectors be migrated with this bump?



##########
superset-frontend/packages/superset-ui-core/src/chart/components/reactify.tsx:
##########
@@ -26,11 +26,21 @@ import {
 } from 'react';
 import type {
   ComponentType,
-  WeakValidationMap,
   ForwardRefExoticComponent,
   PropsWithoutRef,
   RefAttributes,
 } from 'react';
+import type { Validator } from 'prop-types';

Review Comment:
   Downstream TypeScript consumers can now fail with \`TS2307\` while resolving this public declaration: \`Validator\` flows into the exported \`RenderFuncType\`, but \`@types/prop-types\` is only a devDependency, and \`@types/react@19\` no longer supplies it transitively. Can the package declare this type dependency or make the emitted declaration self-contained?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5664970583

   🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) is building environment on [GHA](https://github.com/apache/superset/actions/runs/34851119172) for [a9d21ba](https://github.com/apache/superset/commit/a9d21ba)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5668161332

   🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) deployed environment on [GHA](https://github.com/apache/superset/actions/runs/34874047105) for [e3e2303](https://github.com/apache/superset/commit/e3e2303)
   
   • **Environment:** http://35.93.21.99:8080 (admin/admin)
   • **Lifetime:** 48h auto-cleanup
   • **Updates:** New commits create fresh environments automatically


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5454837477

   AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
   
   <details>
   <summary>
   Bito Usage Guide
   </summary>
   
   **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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
         
   **Configuration**
   
   This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
         
   **Documentation & Help**
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
   
   </details>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5670296862

   AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).
   
   <details>
   <summary>
   Bito Usage Guide
   </summary>
   
   **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 <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/available-commands" target="_blank" rel="noopener noreferrer">documentation</a> for additional commands.
         
   **Configuration**
   
   This repository uses `Superset` You can customize the agent settings <a href="https://alpha.bito.ai/home/ai-agents/code-review-agent" target="_blank" rel="noopener noreferrer">here</a> or contact your Bito workspace admin at evan@preset.io.
         
   **Documentation & Help**
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/getting-started/install-run-using-bito-cloud/create-or-customize-an-agent-instance" target="_blank" rel="noopener noreferrer">Customize agent settings</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/implementing-custom-code-review-rules" target="_blank" rel="noopener noreferrer">Review rules</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent" target="_blank" rel="noopener noreferrer">General documentation</a>
   - <a href="https://docs.bito.ai/bito-dev-agents/ai-code-review-agent/faqs" target="_blank" rel="noopener noreferrer">FAQ</a>
   
   </details>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "netlify[bot] (via GitHub)" <gi...@apache.org>.
netlify[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5667907337

   ### <span aria-hidden="true">✅</span> Deploy Preview for *superset-docs-preview* ready!
   
   
   |  Name | Link |
   |:-:|------------------------|
   |<span aria-hidden="true">🔨</span> Latest commit | e3e23030fbcd6488c94571a507a6b934f9990e99 |
   |<span aria-hidden="true">🔍</span> Latest deploy log | https://app.netlify.com/projects/superset-docs-preview/deploys/6aa82ca0d3ef5c00084003c8 |
   |<span aria-hidden="true">😎</span> Deploy Preview | [https://deploy-preview-42112--superset-docs-preview.netlify.app](https://deploy-preview-42112--superset-docs-preview.netlify.app) |
   |<span aria-hidden="true">📱</span> Preview on mobile | <details><summary> Toggle QR Code... </summary><br /><br />![QR Code](https://app.netlify.com/qr-code/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1cmwiOiJodHRwczovL2RlcGxveS1wcmV2aWV3LTQyMTEyLS1zdXBlcnNldC1kb2NzLXByZXZpZXcubmV0bGlmeS5hcHAifQ.t4c-x2qo65DwLgcn6_ISn3-9KQmbzuy3BzMX__Oh9I4)<br /><br />_Use your smartphone camera to open QR code link._</details> |
   |<span aria-hidden="true">🤖</span> Make changes | [Run an agent on this branch](https://app.netlify.com/projects/superset-docs-preview/agent-runs#q1YqKMrPLShRslJS0lFKKkrMS84AsnOLKxPLSqv0kzPyi1L1i1ITk0t0DS2BKlJSC3LyKz1TgGrMEhMtjJITDVKMU9NMkw0MDCxMDAyMky2UagE) |
   ---
   <!-- [superset-docs-preview Preview](https://deploy-preview-42112--superset-docs-preview.netlify.app) -->
   _To edit notification comments on pull requests, go to your [Netlify project configuration](https://app.netlify.com/projects/superset-docs-preview/configuration/notifications#deploy-notifications)._


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5665275282

   🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) deployed environment on [GHA](https://github.com/apache/superset/actions/runs/34851119172) for [a9d21ba](https://github.com/apache/superset/commit/a9d21ba)
   
   • **Environment:** http://54.189.132.223:8080 (admin/admin)
   • **Lifetime:** 48h auto-cleanup
   • **Updates:** New commits create fresh environments automatically


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "geido (via GitHub)" <gi...@apache.org>.
geido commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r3970033104


##########
superset-frontend/packages/superset-ui-core/src/chart/models/ChartProps.ts:
##########
@@ -112,7 +112,7 @@ export interface ChartPropsConfig {
   /** is the chart refreshing its contents */
   isRefreshing?: boolean;
   /** chart ref */
-  inputRef?: RefObject<any>;
+  inputRef?: RefObject<any | null>;

Review Comment:
   `any | null` collapses to plain `any`, so this one is a no-op, along with the other ~25 `RefObject<any | null>` changes in the PR (SuperChart, labelUtils, ColumnOption/MetricOption, the `filters/*` and `chartCustomizations/*` types, SliceHeaderControls, and `useRef<any | null>` in Vertical.tsx).
   
   Not a correctness problem, but reverting them would cut a good chunk of noise and make the real `RefObject<HTMLDivElement | null>` changes much easier to pick out.



##########
superset-frontend/packages/superset-ui-core/src/components/Select/Select.tsx:
##########
@@ -685,10 +685,10 @@ const Select = forwardRef(
     const isLoading = loading ?? false;
 
     const popupRender = (
-      originNode: ReactElement & { ref?: RefObject<HTMLElement> },
+      originNode: ReactElement & { ref?: RefObject<HTMLElement | null> },
     ) =>
       dropDownRenderHelper(
-        originNode,
+        originNode as Parameters<typeof dropDownRenderHelper>[0],

Review Comment:
   Minor: `utils.tsx` now types this parameter as `ReactElement<FlattenOptionsProps>`, and then the cast here throws that away. If you widen the local `popupRender` param to the same type, the cast can go entirely. Same thing in `AsyncSelect.tsx`.



##########
superset-frontend/packages/superset-ui-core/src/components/CronPicker/CronPicker.test.tsx:
##########
@@ -28,13 +28,14 @@ test('Should send correct props to ReactCronPicker', () => {
     myCustomProp: 'myCustomProp',
   };
   render(<CronPicker {...(props as any)} />);
-  expect(spy).toHaveBeenCalledWith(
+  // React 19 calls function components with a single props argument, so assert
+  // on the props rather than the whole call signature.
+  expect(spy.mock.calls.at(-1)?.[0]).toEqual(

Review Comment:
   `toHaveBeenCalledWith` matched *any* call, whereas `at(-1)` only matches the last one, which makes this order-sensitive under StrictMode double-rendering.
   
   You used `mock.calls.map(call => call[0])` + `toContainEqual` in DashboardPage.test and PropertiesModal.test, which preserves the original semantics. Worth using that shape here too (and in Tab.test / ThemedAgGridReact.test) so they all read the same way.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r4162934747


##########
superset-frontend/plugins/preset-chart-deckgl/src/layers/Contour/Contour.tsx:
##########
@@ -167,7 +167,7 @@ export const getLayer: GetLayerType<ContourLayer> = function ({
     cellSize: safeCellSize,
     aggregation: aggregation.toUpperCase(),
     getPosition: (d: { position: number[]; weight: number }) =>
-      d.position as Position,
+      d.position as unknown as Position,
     getWeight: (d: { weight: number }) => d.weight || 0,

Review Comment:
   <!-- Bito Reply -->
   The `/resolve` command is not supported on inline comments. Please use it in a top-level comment instead.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5667896707

   🎪 [Showtime](https://github.com/mistercrunch/superset-showtime) is building environment on [GHA](https://github.com/apache/superset/actions/runs/34874047105) for [e3e2303](https://github.com/apache/superset/commit/e3e2303)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r3882376451


##########
superset-frontend/src/dashboard/components/gridComponents/DynamicComponent/DynamicComponent.tsx:
##########
@@ -158,7 +158,7 @@ const DynamicComponent: FC<DynamicComponentProps> = ({
               onResizeStop={onResizeStop}
             >
               <div
-                ref={dragSourceRef}
+                ref={dragSourceRef as unknown as React.Ref<HTMLDivElement>}
                 className="dashboard-component"
                 data-test="dashboard-component-chart-holder"
               >

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Double type assertion bypasses type safety</b></div>
   <div id="fix">
   
   The `as unknown as React.Ref<HTMLDivElement>` double-cast bypasses TypeScript's type checking entirely, violating the repo's 'NO any types' policy (AGENTS.md, dev-standard.mdc). The established pattern in `ChartHolder.tsx` uses a proper callback ref wrapper instead. Replace with `ref={el => dragSourceRef(el)}` to maintain type safety.
   </div>
   
   
   <details>
   <summary>
   <b>Code suggestion</b>
   </summary>
   <blockquote>Check the AI-generated fix before applying</blockquote>
   <div id="code">
   
   
   ````suggestion
                  onResizeStop={onResizeStop}
                >
                  <div
                   ref={el => dragSourceRef(el)}
                    className="dashboard-component"
                    data-test="dashboard-component-chart-holder"
                  >
   ````
   
   </div>
   </details>
   
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #f36098</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



##########
superset-frontend/plugins/preset-chart-deckgl/src/layers/Contour/Contour.tsx:
##########
@@ -167,7 +167,7 @@ export const getLayer: GetLayerType<ContourLayer> = function ({
     cellSize: safeCellSize,
     aggregation: aggregation.toUpperCase(),
     getPosition: (d: { position: number[]; weight: number }) =>
-      d.position as Position,
+      d.position as unknown as Position,
     getWeight: (d: { weight: number }) => d.weight || 0,

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Double-cast bypasses type safety</b></div>
   <div id="fix">
   
   The `as unknown as Position` double-cast bypasses TypeScript's type safety. `Position` from `@deck.gl/core` is a tuple type `[lng, lat, alt?]`, not `number[]`. The cleaner fix is to type `position` as `Position` directly in the parameter, matching the pattern already used in `Heatmap.tsx` (lines 143, 196). This avoids the unsafe cast and aligns with the repo's 'NO any types' guidance in AGENTS.md.
   </div>
   
   
   <details>
   <summary>
   <b>Code suggestion</b>
   </summary>
   <blockquote>Check the AI-generated fix before applying</blockquote>
   <div id="code">
   
   
   ````suggestion
       aggregation: aggregation.toUpperCase(),
       getPosition: (d: { position: Position; weight: number }) =>
         d.position,
       getWeight: (d: { weight: number }) => d.weight || 0,
   ````
   
   </div>
   </details>
   
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #f36098</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "bito-code-review[bot] (via GitHub)" <gi...@apache.org>.
bito-code-review[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-4994300405

   AI Code Review is in progress (usually takes 3 to 15 minutes unless it's a very large PR).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-4994337723

   ## [Codecov](https://app.codecov.io/gh/apache/superset/pull/42112?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
   :white_check_mark: All modified and coverable lines are covered by tests.
   :white_check_mark: Project coverage is 56.20%. Comparing base ([`e84f870`](https://app.codecov.io/gh/apache/superset/commit/e84f8707872c5d4e5462d57a88276854e038aaf4?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`d7f4a6b`](https://app.codecov.io/gh/apache/superset/commit/d7f4a6b0e24db106e2824602ca40f389772f7da4?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
   > :exclamation:  There is a different number of reports uploaded between BASE (e84f870) and HEAD (d7f4a6b). Click for more details.
   > 
   > <details><summary>HEAD has 36 uploads less than BASE</summary>
   >
   >| Flag | BASE (e84f870) | HEAD (d7f4a6b) |
   >|------|------|------|
   >|python|30|2|
   >|presto|5|1|
   >|hive|5|1|
   ></details>
   
   <details><summary>Additional details and impacted files</summary>
   
   
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #42112      +/-   ##
   ==========================================
   - Coverage   65.09%   56.20%   -8.89%     
   ==========================================
     Files        2752     2752              
     Lines      154475   154378      -97     
     Branches    35404    35396       -8     
   ==========================================
   - Hits       100550    86771   -13779     
   - Misses      52013    66778   +14765     
   + Partials     1912      829    -1083     
   ```
   
   | [Flag](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [hive](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `39.02% <ø> (ø)` | |
   | [mysql](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [postgres](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [presto](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `40.99% <ø> (ø)` | |
   | [python](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `41.05% <ø> (-18.19%)` | :arrow_down: |
   | [sqlite](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   | [unit](https://app.codecov.io/gh/apache/superset/pull/42112/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
   </details>
   
   [:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/superset/pull/42112?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).   
   :loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
   <details><summary> :rocket: New features to boost your workflow: </summary>
   
   - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
   - :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on PR #42112:
URL: https://github.com/apache/superset/pull/42112#issuecomment-5647703708

   Agreed with @geido here, nice deep dive. Needs a rebase before we can merge, and the `.github/dependabot.yml` ask seems worth folding in given the history there. Bito's two `as unknown as` casts are worth a quick cleanup too since we're pretty strict on `any` in this repo. Thanks for tackling this beast!
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] chore(deps): upgrade React 18 to 19 [superset]

Posted by "rusackas (via GitHub)" <gi...@apache.org>.
rusackas commented on code in PR #42112:
URL: https://github.com/apache/superset/pull/42112#discussion_r4162934294


##########
superset-frontend/plugins/preset-chart-deckgl/src/layers/Contour/Contour.tsx:
##########
@@ -167,7 +167,7 @@ export const getLayer: GetLayerType<ContourLayer> = function ({
     cellSize: safeCellSize,
     aggregation: aggregation.toUpperCase(),
     getPosition: (d: { position: number[]; weight: number }) =>
-      d.position as Position,
+      d.position as unknown as Position,
     getWeight: (d: { weight: number }) => d.weight || 0,

Review Comment:
   This is already done in the current diff, `position` is typed as `Position` directly and the cast is gone. Resolving.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org