Need clarification on data design / filtering
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
- Issue type
- Documentation
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- ruby
- Domain
- build-system, databases
Research direction
Read the conversion code in Rakefile around lines 77–80 and compare its output with content_type_mime.db and ext_mime.db. Review the reported diffs and the priority-extensions branch to determine the intended filtering and ordering rules; done means the file’s design is clarified and the conversion behavior is understood.
Written by the indexing model from the issue text.
Description
I’m trying to understand the decisions made when building the content_type_mime.db file, because I’m embarking on a fairly major upgrade to the data in mime-types-data (https://github.com/mime-types/mime-types-data/tree/priority-extensions) where I’ve made it possible to specify relative extension priorities.
As far as I can tell, the ext_mime.db file looks to be mostly OK. It’s helping me find some issues (font/ttf should be the highest priority result for .ttf, which it isn’t).
However, it looks like the prioritization code I have put in place will break content_type_mime.db in unpleasant ways.
I’m using my translation of the conversion code from your own Rakefile (also in the same tree), but here’s some of the odder diffs:
+bin application/java-vm base64
+txt application/winhlp base64
+t application/x-troff-man 8bit
+t application/x-troff-me base64
+t application/x-troff-ms base64
The first should be class, but the code at https://github.com/discourse/mini_mime/blob/main/Rakefile#L77-L80 forces the first extension from application/octet-stream (because application/java-vm no longer sorts first for class).
There are a couple of other examples like this, but I’m trying to figure out what the intent for this particular file is in order to provide (a) recommendations for updates to your own code and (b) convert it correctly myself.
- Dominant language
- Ruby
- Stars
- 112
- Forks
- 35
- Avg merge
- 1h
- Merged PRs (30d)
- 1
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from discourse/mini_mime
-
Difficulty 2/5 1-3 hours Newbie friendliness 55/100
-
Random read failures Open
Difficulty 4/5 3-5 days Newbie friendliness 25/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
-
mini_mime vs marcel Open
Difficulty 5/5 Over a week Newbie friendliness 18/100
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
All issues in discourse/mini_mime
Similar issues
-
バグ
Difficulty 1/5 Under an hour Newbie friendliness 92/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
voxpupuli/puppet-epel#186 · 1 comment ·
-
external_created_at is no longer used for the message timestamp since the new message UI (v4.4.0) OpenBug Frontend
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
TheOdinProject/curriculum#31402 · 1 comment ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100