-
Notifications
You must be signed in to change notification settings - Fork 18.4k
mime: extend "builtinTypes" to include a more complete list of common types #69533
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
Conversation
Simply implements the first recommended type for each file extension listed in MDN https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types However, this excludes ".3gp" and ".3gp2" as from from I can tell it is not possible to know if it is video or audio solely from file extension. As far as I can tell there are two previous PRs that each implemented a type simply because they were in common use. Updates golang#69530
This PR (HEAD: 4526569) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Message from Gopher Robot: Patch Set 1: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Gopher Robot: Patch Set 1: Congratulations on opening your first change. Thank you for your contribution! Next steps: Most changes in the Go project go through a few rounds of revision. This can be During May-July and Nov-Jan the Go project is in a code freeze, during which Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Aidan Welch: Patch Set 2: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Ian Lance Taylor: Patch Set 2: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Ian Lance Taylor: Patch Set 2: Hold+1 (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Comment with the source of the builtin types Updates golang#69530
This PR (HEAD: 3cc1e3c) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Message from Aidan Welch: Patch Set 2: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
… agree Implement all agreed upon types, using IANA's listed media types to decide when there is a disagreement in type. Except in the case of `.wav` where `audio/wav` is used. Fixes golang#69530
This PR (HEAD: 480e944) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Add the newly included file extensions to the expected TypeByExtension. Fixes golang#69530
This PR (HEAD: 7f59c2c) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Message from Aidan Welch: Patch Set 6: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Aidan Welch: Patch Set 6: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Aidan Welch: Patch Set 6: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 6: Commit-Queue+1 (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 6: Dry run: CV is trying the patch. Bot data: {"action":"start","triggered_at":"2025-08-27T23:41:56Z","revision":"f6b1e6e7345d5bab6230579e67db85487f858293"} Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 6: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 6: This CL has failed the run. Reason: Tryjob golang/try/x_debug-gotip-linux-amd64 has failed with summary (view all results):
Error: Additional links for debugging: Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 6: LUCI-TryBot-Result-1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 7: Commit-Queue+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 7: Dry run: CV is trying the patch. Bot data: {"action":"start","triggered_at":"2025-08-28T23:15:31Z","revision":"5c8b6e29d02f7ee0a2ac7e9b3a7e82f777e99204"} Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 7: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 7: This CL has passed the run Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 7: LUCI-TryBot-Result+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 7: Code-Review+2 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Sean Liao: Patch Set 7: Code-Review+1 (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Sean Liao: Patch Set 9: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 9: This CL has passed the run Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 9: LUCI-TryBot-Result+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Emmanuel Odeke: Patch Set 9: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
This PR (HEAD: 58e7c6c) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Message from Aidan Welch: Patch Set 10: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Emmanuel Odeke: Patch Set 10: Auto-Submit+1 Code-Review+2 Commit-Queue+1 (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 10: Dry run: CV is trying the patch. Bot data: {"action":"start","triggered_at":"2025-09-25T20:28:43Z","revision":"2e96cc05090462ffe901e249138fa701e42a71be"} Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Emmanuel Odeke: Patch Set 10: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 10: This CL has failed the run. Reason: Failed Tryjobs:
Error: Additional links for debugging:
Error:
Additional links for debugging: Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 10: LUCI-TryBot-Result-1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
This PR (HEAD: e314c5e) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/go/+/614376. Important tips:
|
Message from Aidan Welch: Patch Set 10: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Emmanuel Odeke: Patch Set 11: Auto-Submit+1 Code-Review+2 Commit-Queue+1 (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 11: Dry run: CV is trying the patch. Bot data: {"action":"start","triggered_at":"2025-09-25T21:01:58Z","revision":"47a4d4a4018e0ff8a5b78c578ba1dd6629421164"} Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Emmanuel Odeke: Patch Set 11: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 11: This CL has failed the run. Reason: Tryjob golang/try/x_debug-gotip-linux-amd64 has failed with summary (view all results):
Error: Additional links for debugging: Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 11: LUCI-TryBot-Result-1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Sean Liao: Patch Set 12: Commit-Queue+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 12: Dry run: CV is trying the patch. Bot data: {"action":"start","triggered_at":"2025-09-26T19:31:31Z","revision":"1d6414aef00db61e25adda80651555e784e99e38"} Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Sean Liao: Patch Set 12: -Commit-Queue Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 12: This CL has passed the run Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Go LUCI: Patch Set 12: LUCI-TryBot-Result+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Sean Liao: Patch Set 12: Auto-Submit+1 Code-Review+1 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
Message from Damien Neil: Patch Set 12: Code-Review+2 Please don’t reply on this GitHub thread. Visit golang.org/cl/614376. |
… types Implement all agreed upon types, using IANA's listed media types to decide when there is a disagreement in type. Except in the case of `.wav` where `audio/wav` is used. Fixes #69530 Change-Id: Iec99a6ceb534073be83c8390f48799bec3e4cfc7 GitHub-Last-Rev: e314c5e GitHub-Pull-Request: #69533 Reviewed-on: https://go-review.googlesource.com/c/go/+/614376 Reviewed-by: Damien Neil <[email protected]> Reviewed-by: Emmanuel Odeke <[email protected]> Auto-Submit: Sean Liao <[email protected]> Reviewed-by: Sean Liao <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Carlos Amedee <[email protected]>
This PR is being closed because golang.org/cl/614376 has been merged. |
Implement all agreed upon types, using IANA's listed media types to decide
when there is a disagreement in type. Except in the case of
.wav
whereaudio/wav
is used.Fixes #69530