-
Notifications
You must be signed in to change notification settings - Fork 14k
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
chore: Migrate /superset/stop_query/ to API v1 #22624
chore: Migrate /superset/stop_query/ to API v1 #22624
Conversation
Codecov Report
@@ Coverage Diff @@
## master #22624 +/- ##
==========================================
- Coverage 66.88% 65.51% -1.38%
==========================================
Files 1859 1859
Lines 71103 71147 +44
Branches 7782 7782
==========================================
- Hits 47557 46610 -947
- Misses 21520 22511 +991
Partials 2026 2026
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
c8b384f
to
601562f
Compare
superset/queries/dao.py
Outdated
|
||
@staticmethod | ||
def stop_query(client_id: str) -> None: | ||
query = db.session.query(Query).filter_by(client_id=client_id).one() |
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.
an invalid client_id
will raise, and the API would return HTTP 500, would be nicer to respond HTTP 404
|
||
assert rv.status_code == 200 | ||
data = json.loads(rv.data.decode("utf-8")) | ||
assert data["result"] == "OK" |
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.
add one test for a non existent client_id
…h42050/migrate-superset-stop-query-to-api-v1
SUMMARY
Continuing the effort on deprecating all /superset/ REST API endpoints
Deprecates /stop_query & moves is into api v1
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
ADDITIONAL INFORMATION