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

   ### SUMMARY
   PR #44015 ("fix(versioning): row-lock the live entity during version 
restore") added three new test methods to 
tests/integration_tests/charts/version_restore_tests.py that read `chart_uuid = 
chart.uuid` and pass it straight into `RestoreChartVersionCommand(chart_uuid, 
...)`. `Slice.uuid` is typed `UUID | None`, while 
`RestoreChartVersionCommand.__init__` (superset/commands/version_restore.py) 
requires a non-Optional `UUID`, so the nightly full-repo mypy check ("mypy 
(main)" in .github/workflows/pre-commit.yml) has failed on master since the Sep 
15 nightly run.
   
   This file already has the fix for this exact situation everywhere else: PR 
#42654 ("fix(versioning): narrow UUIDs in restore tests") added `assert 
entity_uuid is not None` immediately after every `.uuid` read in this file (and 
its dashboard/dataset siblings) before passing it onward. The three call sites 
added by #44015 are the only ones that skipped that guard. This PR adds the 
same one-line assert at each of the three sites — no other changes.
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   
   ### TESTING INSTRUCTIONS
   Run `pre-commit run mypy` (or `mypy --check-untyped-defs 
tests/integration_tests/charts/version_restore_tests.py`) against the changed 
file — the three `arg-type` errors on `RestoreChartVersionCommand` at the 
affected lines should no longer appear.
   
   ### ADDITIONAL INFORMATION
   - [x] Has associated issue: Fixes #44384
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in SIP-59)
     - [ ] 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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to