Skip to content
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

Don't log call errors for 204 response codes #105

Closed
smarquard opened this issue Jul 23, 2014 · 1 comment
Closed

Don't log call errors for 204 response codes #105

smarquard opened this issue Jul 23, 2014 · 1 comment

Comments

@smarquard
Copy link

In utils/mhttpclient.py, an error is logged if a request gets a response code that is not 200:

if status_code != 200:
if self.logger:
self.logger.error('call error in %s, status code {%r}: %s',
urlparse.urlunparse(url), status_code, b.getvalue())
raise IOError, 'Error in Matterhorn client'

However the GC dashboard returns status code 204, and as the docs/scripts/run_dashboard_push.py uses mhttpclient, GC logs are filled up with:

galicaster 2014-07-23 10:53:31,707 ERROR mhhttpclient call error in http://media.uct.ac.za/dashboard/rest/agents/jamesc/snapshot.png, status code {204}:

As 204 is not an error code, mhttpclient should not log an error when receiving it.

@hcaloto
Copy link
Contributor

hcaloto commented May 13, 2015

Thank you Stephen

@hcaloto hcaloto closed this as completed May 13, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants