question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Range error [offset > 6], while parsing POPM frame in ID3v2 header

See original GitHub issue

Bug description I’m trying to read data from an array of file paths. I get the following error:

(node:15553) UnhandledPromiseRejectionWarning: RangeError [ERR_OUT_OF_RANGE]: The value of "offset" is out of range. It must be >= 0 and <= 6. Received 9
    at boundsError (internal/buffer.js:49:9)
    at Buffer.readUInt8 (internal/buffer.js:137:5)
    at Function.readData (/home/binyamin/Documents/Coding/musia/node_modules/music-metadata/lib/id3v2/FrameParser.js:129:31)
    at Function.readFrameData (/home/binyamin/Documents/Coding/musia/node_modules/music-metadata/lib/id3v2/ID3v2Parser.js:90:46)
    at ID3v2Parser.parseMetadata (/home/binyamin/Documents/Coding/musia/node_modules/music-metadata/lib/id3v2/ID3v2Parser.js:183:40)
    at ID3v2Parser.parseId3Data (/home/binyamin/Documents/Coding/musia/node_modules/music-metadata/lib/id3v2/ID3v2Parser.js:139:32)
(node:15553) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:15553) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Expected behavior Receive metadata Problematic Audio

audio.zip

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
Borewitcommented, Aug 5, 2019

Please open a new issue for that one, otherwise my administration becomes a mess.

I am traveling at the moment, and my laptop battery is empty. Therefor that issue may need to wait a bit longer to be solved.

0reactions
Borewitcommented, Aug 6, 2019

It looks like the POPM “Email to user” field should read as as an ISO-639-2 encoded string after all.

In both your sample files, it consusing that the POPM frame is flagged as UTF-16-with-BOM, since there is no text field which could be read as such. Secondly that the content of the e-mail address 0x01.

Related documentation:

Read more comments on GitHub >

github_iconTop Results From Across the Web

id3v2-00 - ID3.org
The first byte of ID3 version is it's major version, while the second byte is its ... A frame must be at least...
Read more >
ID3v2 - Informal standard - Java ID3 Tag Library
The decision to have a 6 byte frame header was taken in an attempt to balance big frames against little overhead. One might...
Read more >
Parsing ID3V2 Frames in C - Stack Overflow
I have been attempting to retrieve ID3V2 Tag Frames by parsing through the mp3 file and retrieving each frame's size. So far I...
Read more >
New MP3 decoder misidentifies MP3 header within ID3v2 tag
I think I've found what goes wrong: In FrameParser::Parse, if we have detected a valid ID3v2 header, we try skipping past the ID3...
Read more >
the universal Tag Editor - History of changes - Mp3tag
(#44746) [2019-03-08] FIX: runtime error when parsing certain invalid ID3v2 TCON frames. [2019-03-07] FIX: creation of files and folders with reserved names ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found