-
Notifications
You must be signed in to change notification settings - Fork 127
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
Not able to read FLAC tags from certain files. #90
Comments
Also stumbled upon this now! |
Using |
Same problem. Is there any else way to solve it? |
Under the assumption you use it in the browser, music-metadata-browser will do the job. In node.js use music-metadata. |
If anyone cares, you can find the actual problem explained by reading the closed Media tags not working cybercase issue above this comment. The problem is that some FLAC tags are not TITLE, but Title or title instead. jsmediatags is running a switch case on these with only ALL CAPS, so it's missing the FLACs that have them with all lowercase or first-letter-capitalized and the rest lower. I just edited it to add the necessary checks (pull requests have gone unanswered here for awhile so I'm not going to bother.) jsmediatags/src/FLACTagReader.js - find the _parseData function and replace the case statements there with this: switch (split[0]) { You can see its merely appending two additional case lines for the Title and title options (and so on down the line) Tested working with one of my FLACs that caused me to look into this. Most of you probably just want this to work and are not looking to fork and compile, in which case just go to the dist directory, copy out the jsmediatags.js file (not the minified one) and make the edits there, its fairly near the top. Save and there you go or run it through your own online minifier of choice if you need/want a min version. Adventurous individuals can look at one of the lingering pull requests here for adding missing tag fields to FLACs - since you are already editing the file you may wish to insert those changes in as well - equally as easy as this edit. And thanks to @aadsm hope things are well for you. The music-metadata-browser option someone posted above is much more expansive, but also comes with a lot more dependencies and a different use-flow. This js is pleasantly lean and fits my use case quite well. |
@AllAstronauts oh wow, I didn't receive any mail of the past PRs on this repo 😧. I did receive a mail for this comment though so decided to check those claims about unanswered pr's 😅 , and realized I had no idea about them 😬. |
lol - so that's why - crazy I could do the pull requests, but you can see they are brain dead changes (so is that pull with the added FLAC fields). A case change to upper on the var before the switch cases would be more practical and you can skip a few (all) of of those multiple case additions I made - I just smacked the thing to get it working - nothing elegant or thought out on my end 😄 I'd just assume let you deal with these minor edits 😄 Glad you are doing alright! |
Finally fixed in 3.9.5! |
The example file and original report is in captbaritone/webamp#461.
The text was updated successfully, but these errors were encountered: