Skip to content

gh-122631 Add video/3gpp and video/3gpp2 to mimetypes #122632

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

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

robotmlg
Copy link

@robotmlg robotmlg commented Aug 2, 2024

@robotmlg robotmlg requested a review from a team as a code owner August 2, 2024 20:02
@ghost
Copy link

ghost commented Aug 2, 2024

All commit authors signed the Contributor License Agreement.
CLA signed

@bedevere-app
Copy link

bedevere-app bot commented Aug 2, 2024

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

Copy link
Member

@AA-Turner AA-Turner left a comment

Choose a reason for hiding this comment

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

As you note, the audio/ versions already exist:

cpython/Lib/mimetypes.py

Lines 527 to 530 in efcd65c

'.3gp' : 'audio/3gpp',
'.3gpp' : 'audio/3gpp',
'.3g2' : 'audio/3gpp2',
'.3gpp2' : 'audio/3gpp2',

The suffixes are the same, though, so this would overwrite as they appear later in the dict. Can you think of a way to fix that?

A

@bedevere-app
Copy link

bedevere-app bot commented Aug 3, 2024

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@AA-Turner AA-Turner added the pending The issue will be closed if no feedback is provided label Aug 3, 2024
@robotmlg
Copy link
Author

robotmlg commented Sep 3, 2024

@AA-Turner I have made the requested changes; please review again.

I think ideally types_map would also be a dict[str, list[str]] like types_map_inv is, so that every extension would map to a list of types. But that would be a pretty big breaking change for my first PR here (since types_map gets exported), lemme know if you think I should tackle that instead of my more band-aid solution here.

(Also I'm not sure what's going on with my NEWS build errors, would appreciate any pointers there.)

EDIT: I put up a PR on my fork of how I would do the breaking version. I do think it's cleaner, and more future-proof, but obviously it's a breaking change on types_map and presumably we'd have to go through channels for that. Lemme know your thoughts. robotmlg#1

@bedevere-app
Copy link

bedevere-app bot commented Sep 3, 2024

Thanks for making the requested changes!

@AA-Turner: please review the changes made to this pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting change review pending The issue will be closed if no feedback is provided
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants