-
Notifications
You must be signed in to change notification settings - Fork 79
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
Meta: Moving forward #153
Comments
Have you reviewed other crates to check whether you (and other users) might perhaps be better offer migrating to an existing other option? |
The mime crate is no longer maintained per hyperium/mime#153 The mediatype is a reasonable replacement, and actively maintained. https://crates.io/crates/mediatype/
To be frank, do many care about matching and comparisons? My understanding is that the vast majority simply use it as a crate of constants to use instead of strings. It seems unreasonable to block PRs attempting to add new types based on a desire to completely rework the crate. If its simply a lack of maintainer ship it may be worth asking for new maintainers. I think that honestly the only changes that matter are to maintain an update to date list. If we want to go further we could simply parse https://www.iana.org/assignments/media-types/media-types.xhtml |
This is a meta issue to collect the steps needed to move this crate forward. While it is currently "maintained", in that severe bugs will be merged, it's otherwise rotting. I'm hopeful we can revive it, but I'll need your help.
Related to
Previous Attempts
0.1:
Mime(TopLevel::Plain, SubLevel::Text, [])
This allowed "expressive" matching like
Mime(TopLevel::Text, SubLevel::Plain, _)
.Cons:
SubLevel
enum contained variants that only made sense for some top-level types.application/text+xml
) was conflated with the sub-level type.SubLevel::Other(String)
is a backwards-compatibility hazard for adding new variants that used to parse asOther
.0.3:
struct Mime
,mime::TEXT_PLAIN
constantsStill allowed matching,
(mime::TEXT, mime::PLAIN)
.Cons:
Mime
sName
s andValue
s0.4 (never released):
MediaType
,MediaRange
, andmime!
macro.Separated
Mime
into type and range. Themime!
macro was meant to allow easier constant creation. It could also allow nicer syntax, such asmime!("text" / "plain")
, without any extra imports.Cons:
const fn
has advanced that we probably could live without a macro.The text was updated successfully, but these errors were encountered: