Skip to content

albumart#106

Open
manolomartinez wants to merge 9 commits into
masterfrom
albumart
Open

albumart#106
manolomartinez wants to merge 9 commits into
masterfrom
albumart

Conversation

@manolomartinez

Copy link
Copy Markdown
Owner

Introduces a new coverart option for greg.conf. This option expects a path to an image, which will be used as cover art for the podcast.

@manolomartinez manolomartinez linked an issue Apr 27, 2021 that may be closed by this pull request
Comment thread greg/data/greg.conf Outdated
Comment thread greg/aux_functions.py
exist.""", file=sys.stderr, flush=True)
coverart = False
else:
coverart_mime = mimetypes.guess_type(coverart_filename)[0]

@sabberworm sabberworm May 5, 2021

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than guessing the MIME type from the extension, couldn’t we leverage mime-info on systems that have it? It’s more accurate in most cases.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am a bit wary of multiplying dependencies; also, users can pretty much choose their own extension with file_to_tag, right?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had assumed that EyeD3 bundled magic anyway for use with https://eyed3.readthedocs.io/en/latest/eyed3.plugins.html#module-eyed3.plugins.mimetype but looking at the source, it seems I was mistaken.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... but perhaps I'm being silly about dependencies. You seem to be a serious dev, much unlike me :) So I'm willing to listen.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I think you’re being perfectly reasonable. Also I might be a serious dev (whatever that means) but not all that familiar with the Python ecosystem…

Comment thread greg/aux_functions.py
for mytag in tagdict:
setattr(file_to_tag.tag, mytag, tagdict[mytag])
if coverart:
with open(coverart_filename, 'rb') as imagefile:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be cool if the coverart_filename could be a http(s) URL. And if the images linked from the feed (e.g. <image><url> in the feed and <itunes:image> in the article) would be made available as placeholders. This way we could do:

coverart = {articleimage}

or

coverart = {feedimage}

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, let me look into that.

manolomartinez and others added 3 commits May 5, 2021 12:02
lgtm

Co-authored-by: Raphael Schweikert <any@sabberworm.com>
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

Successfully merging this pull request may close these issues.

Front Cover Tag

2 participants