-
Notifications
You must be signed in to change notification settings - Fork 4
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
WIP Issue #29 - Add batch capability for running analytics over historical results (e.g. after uploading data from SD cards) #30
base: main
Are you sure you want to change the base?
Conversation
… over historical results (e.g. after uploading data from SD cards)
… over historical results (e.g. after uploading data from SD cards)
src/core_decision_flask_app.py
Outdated
# Return 404 (Not Found) if the record IDs are invalid | ||
if (date is None) : | ||
logger.error('Missing parameters : '+DATE_PARAMETER+' : '+str(date)) | ||
abort(404) |
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.
Comment - @Gaurav-Ramakrishna @upkarlidder
Should this error be
- 400 - bad request (@Gaurav-Ramakrishna says this)
- 422 - Unprocessable Entity
FYI @JSegrave-IBM
src/core_decision_flask_app.py
Outdated
def batch_run_analytics_by_date(): | ||
|
||
try: | ||
date = request.args.get(DATE_PARAMETER) |
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.
@JSegrave-IBM should we validate the date here? We just check for None.
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.
@JSegrave-IBM added some comments.
Can we also write a unit test or something to test it out before pushing it into master?
…e-checking and 400 return code.
… records in the batch window (also refactored batch_run_analytics to be a little clearer - it takes a start & end time now (rather than a schedule of individual minutes)
Issue #29 - Add batch capability for running analytics over historical results (e.g. after uploading data from SD cards)