You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "dmunozv04 (via GitHub)" <gi...@apache.org> on 2026/10/14 13:01:50 UTC

[PR] test(semantic-views): wait for the selected metric's schema refresh [superset]

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

   <!---
   Please write the PR title following the conventions at https://www.conventionalcommits.org/en/v1.0.0/
   Example:
   fix(dashboard): load charts correctly
   -->
   
   ### SUMMARY
   
   Fix intermittent `AddSemanticViewModal test` failures by waiting for the selected metric’s schema refresh in the preceding 500-metric test.
   
   Commit [`8175e0ecc7`](https://github.com/apache/superset/commit/8175e0ecc7b25f4c54dac0c0810763b4f2c1ae4e) ([#44995](https://github.com/apache/superset/pull/44995)) enabled refreshes for empty optional dependencies. On slower runs, an initial `{runtime_data: {}}` refresh completes before metric selection. 
   The existing wait accepts that earlier request, allowing the test to finish while the selected metric’s refresh debounce remains queued. That timer survives unmount and reaches the next test’s shared mock, producing two pending requests instead of one; and failing the test. 
   
   This PR matches the refresh payload’s selected metric instead of counting any refresh with truthy runtime data. 
   
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   N/A, test fix only
   
   ### TESTING INSTRUCTIONS
   
   From `superset-frontend`, run the focused suite:
   
   ```bash
   CI=true npm run test -- src/features/semanticViews/AddSemanticViewModal.test.tsx --coverage --coverageReporters=json
   ```
   
   Run the full CI shard:
   
   ```bash
   CI=true npm run test -- --coverage --shard=3/8 --coverageReporters=json
   ```
   
   Verified using the exact Docker artifact from [the failing CI job](https://github.com/apache/superset/actions/runs/38557386813/job/115833761603): Linux amd64, Node 24.21.0, npm 11.19.0, and three Jest workers. Both comparisons used fresh containers and the full coverage shard; the corrected run mounted only the changed test.
   
   Asked codex to create a reproduction test: https://gist.github.com/dmunozv04/55c51d57bc75646dcfdbb5f8e39fee7f , to confirm the test failure and not rely on guesses. 
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
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] test(semantic-views): wait for the selected metric's schema refresh [superset]

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

   ## [Codecov](https://app.codecov.io/gh/apache/superset/pull/45280?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 65.07%. Comparing base ([`ffee0a8`](https://app.codecov.io/gh/apache/superset/commit/ffee0a843f196cd08a5514b105b3c8bf29395b30?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`25088bd`](https://app.codecov.io/gh/apache/superset/commit/25088bd60217d3705cd0b43b6aca8b2f85d853d3?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
   
   <details><summary>Additional details and impacted files</summary>
   
   
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #45280      +/-   ##
   ==========================================
   + Coverage   65.02%   65.07%   +0.05%     
   ==========================================
     Files        3039     3040       +1     
     Lines      198382   198611     +229     
     Branches    46213    46346     +133     
   ==========================================
   + Hits       128992   129242     +250     
   + Misses      66489    66468      -21     
     Partials     2901     2901              
   ```
   
   | [Flag](https://app.codecov.io/gh/apache/superset/pull/45280/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [javascript](https://app.codecov.io/gh/apache/superset/pull/45280/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `78.97% <ø> (+0.07%)` | :arrow_up: |
   
   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/45280?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] test(semantic-views): wait for the selected metric's schema refresh [superset]

Posted by "codeant-ai-for-open-source[bot] (via GitHub)" <gi...@apache.org>.
codeant-ai-for-open-source[bot] commented on PR #45280:
URL: https://github.com/apache/superset/pull/45280#issuecomment-6169078233

   ## CodeAnt PR Risk: Low Risk
   
   - The PR appears safe to merge; it only makes the test wait for the selected metric's runtime refresh.
   
   **Assessed commit:** `25088bd60217`


-- 
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] test(semantic-views): wait for the selected metric's schema refresh [superset]

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

   Solved by #45282 
   Thanks!


-- 
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] test(semantic-views): wait for the selected metric's schema refresh [superset]

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

   Thanks for the comment @mikebridge!
   I totally missed that second issue. Feel free to close this PR if you'd prefer, instead of solving the minor issue of not checking its response


-- 
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] test(semantic-views): wait for the selected metric's schema refresh [superset]

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

   This issue seems to affect the following open PRs:
   #45277, #45272, #45275, #45142, #45022, #45176


-- 
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] test(semantic-views): wait for the selected metric's schema refresh [superset]

Posted by "dmunozv04 (via GitHub)" <gi...@apache.org>.
dmunozv04 closed pull request #45280: test(semantic-views): wait for the selected metric's schema refresh
URL: https://github.com/apache/superset/pull/45280


-- 
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