-
Notifications
You must be signed in to change notification settings - Fork 0
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
Updated chart data, S3 aggregate parquet moved #124
Conversation
eade41e
to
8e5589e
Compare
☂️ Python Coverage
Overall Coverage
New Files
Modified Files
|
docs/dashboard_api.prod.yaml
Outdated
@@ -580,12 +577,23 @@ paths: | |||
content: {} | |||
security: | |||
- api_key: [] | |||
/study-periods: | |||
/data_packages/{data_package_id}: |
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.
nit: this is so lonely at the end, separated from its child API
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.
This is autogenerated from API gateway, I have no control over it.
res = functions.http_response(200, res) | ||
except errors.AggregatorS3Error: | ||
res = functions.http_response( | ||
404, f"Aggregate for {path_params['data_package_id']} not found" |
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.
nit: that's a very specific conclusion to draw from a generic "something happened error". Might be helpful to log the original error message and/or include it here too.
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.
The error should get logged to cloudwatch, security asked us to have no stack traces in responses and to generally have these error messages be unhelpful while the API is externally accessible.
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.
Maybe add a comment to that effect? Like... if a third developer comes across this in 2 years, they won't have that context. Something like "# don't be too informative about internal state in our error messages" (but in Matt voice) above this generic response.
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.
ok, added a brief note.
/chart_data/
endpoint to/data_packages/[data_package_id]/chart