-
Notifications
You must be signed in to change notification settings - Fork 6
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
Standardise api #222
Standardise api #222
Conversation
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.
Thanks for doing this, just a couple of minor points. Also the CI is unhappy.
This PR is awaiting Callum's #202, which it will need to be rebased on top of. Until then the Liniting and tests will fail as the signature and purpose of the worker.submit_tasks method and its tests are in flux. Consequently do not merge this until #202 has been cleared and the rebase updates performed |
src/blueapi/service/main.py
Outdated
) | ||
|
||
|
||
@app.get("/plans", response_model=PlanResponse) | ||
def get_plans(handler: Handler = Depends(get_handler)): | ||
def get_plans(response: Response, handler: Handler = Depends(get_handler)): |
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.
response
is no longer used
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.
Done
ad503ea
to
df08a65
Compare
Codecov Report
@@ Coverage Diff @@
## main #222 +/- ##
==========================================
+ Coverage 90.32% 90.37% +0.04%
==========================================
Files 40 40
Lines 1168 1174 +6
==========================================
+ Hits 1055 1061 +6
Misses 113 113
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Rework the existing endpoints to comply with the guidelines:
API version is set in app declaration after loading it from REST config object.
Added function to allow easy appending of endpoint specific response headers to defaults
Submit task method refactored to return task id (currently UUID)