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

cover art archive now returns content type application/json #161

Open
alastair opened this issue Feb 10, 2015 · 2 comments
Open

cover art archive now returns content type application/json #161

alastair opened this issue Feb 10, 2015 · 2 comments
Milestone

Comments

@alastair
Copy link
Owner

http://tickets.musicbrainz.org/browse/CAA-75

We have a hack in the caa code: https://github.com/alastair/python-musicbrainzngs/blob/master/musicbrainzngs/caa.py#L72

@mineo
Copy link
Collaborator

mineo commented Feb 10, 2015

This has been (sadly) at the bottom of my todo list since I closed CAA-75. To implement a content type check we need to change _safe_read to return the file-like object returned by opener.open so we can access the headers. Unfortunately the docs don't really tell whether calling read can raise exceptions or if only open can - if read can raise some, moving that out of _safe_read would kind of defeat its purpose :)

@sampsyo
Copy link
Collaborator

sampsyo commented Feb 10, 2015

Sadly, I believe read can raise errors (I'm about 75% confident about that).

See also #123. 😃

@alastair alastair modified the milestone: 0.7 Nov 15, 2015
@alastair alastair modified the milestones: 0.7, 0.8 Sep 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants