Skip to content
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

fix(deps): update rust crate lofty to 0.21.0 #22

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Aug 22, 2023

This PR contains the following updates:

Package Type Update Change
lofty dependencies minor 0.12.1 -> 0.21.0

Release Notes

Serial-ATA/lofty-rs (lofty)

v0.21.1

Compare Source

Changed
  • FLAC: Vendor strings are now retained when writing tags (PR)
    • This behavior already exists for OGG formats.
Fixed
  • FLAC: Stop writing invalid PADDING blocks (issue) (PR)
    • If a PADDING block existed in the original file, and it wasn't placed at the end of the header, it would be
      moved without setting the Last-metadata-block flag. This would cause decoders to believe that the file was corrupted.
  • Fuzzing (Thanks @​qarmin!) (PR):
    • MusePack: Fix panic when tag sizes exceed the stream length (issue)
    • AAC: Fix panic when tag sizes exceed the stream length (issue)

v0.21.0

Compare Source

Added
  • ParseOptions:
    • ParseOptions::read_tags to skip the parsing of tags (issue) (PR)
    • ParseOptions::read_cover_art (issue) (PR)
      • As cover art can be large, it is now possible to disable reading it when parsing a file.
    • ParseOptions::implicit_conversions to prevent automatic data conversions (PR)
      • Be sure to read the warnings in the docs to understand what this means.
  • ID3v2: Support writing ID3v2.3 tags (issue) (PR)
    • This can be done by setting WriteOptions::use_id3v23 to true.
  • Tag: Tag::take_filter (PR)
    • This is like Tag::take, but allows for per-TagItem filtering.
    • This is useful for TagType::Id3v2, as it allows specifying descriptions and languages for frames.
      See the docs and PR description for more details.
Changed
  • Timestamp: Timestamp::parse with empty inputs will return None when not using ParsingMode::Strict (PR)
  • MP4: Atoms with sizes greater than the remaining file size will be ignored with ParsingMode::Relaxed (PR)
  • ID3v2 (PR):
    • PopularimeterFrame::as_bytes() is now fallible
    • PrivateFrame::as_bytes() is now fallible
Fixed
  • Fuzzing (Thanks @​qarmin!) (PR) (PR):
    • MP4:
      • Fix panic when reading properties of a file with no timescale specified (issue)
      • Fix panics when reading improperly sized freeform atom identifiers (issue) (issue)
      • Fix panic when data atom length is less than 16 bytes (issue)
      • Fix panic with improperly sized freeform identifiers (issue)
      • Fix panic when hdlr atom is an unexpected length (issue)
      • Fix panic when stts atom has an unrealistically large entry count (issue) (PR)
    • WAV:
      • Fix panic when reading properties with large written bytes per second (issue)
      • Fix panic when reading an improperly sized INFO LIST (issue)
      • Fix panic when reading a fmt chunk with an invalid bits_per_sample field (issue)
    • Vorbis:
      • Fix panic when reading properties of a file with large absolute granule positions (issue)
      • Fix attempted large allocations with invalid comment counts (issue)
    • FLAC: Fix panic when reading properties of a file with incorrect block sizes (issue)
    • AIFF: Fix panic when reading properties of a file with invalid f80 sample rate (issue)

v0.20.1

Compare Source

Fixed
  • MPEG: Fix durations being slightly off (issue) (PR)

v0.20.0

Compare Source

Added
  • Tag:
    • Support ItemKey::ParentalAdvisory for Ilst and Id3v2Tag (issue) (PR)
    • New tag::items module for generic representations of complex tag items
    • New Timestamp item for ISO 8601 timestamps (PR)
  • ID3v2: Special handling for frames with timestamps with Frame::Timestamp (PR)
  • GlobalOptions: preserve_format_specific_items() (issue) (PR)
    • This will allow for the preservation of format-specific items when converting between tag types.
    • Previously, these items would be discarded when converting to the generic Tag. Now they are stored
      in an immutable container, and silently rejoined with the tag when converting back to the original format
      or when writing.
  • TagItem: set_lang and set_description to allow for generic conversions of additional ID3v2 frames (such as comments) (issue) (PR)
  • BoundTaggedFile: BoundTaggedFile::into_inner to get the original file handle (PR)
Changed
  • VorbisComments/ApeTag: Verify contents of ItemKey::FlagCompilation during Tag merge (PR)
  • ID3v2:
    • ⚠️ Important ⚠️: Frame has been converted to an enum (PR):
      • This makes it easier to validate frame contents, as one can no longer make an AttachedPictureFrame with the ID "TALB", for example.
        See the PR for a full description of the changes.
      // Old:
      let frame = Frame::new(
          "TALB",
          FrameType::Text(TextInformationFrame {
              TextEncoding::UTF8,
              value: String::from("Foo album"),
          }),
          FrameFlags::default(),
      ).unwrap();
      
      // New:
      let frame = Frame::Text(TextInformationFrame::new(
          FrameId::new("TALB").unwrap(),
          FrameFlags::default(),
          TextEncoding::UTF8,
          String::from("Foo album"),
      ));
    • Renamed Popularimeter -> PopularimeterFrame
    • Renamed SynchronizedText -> SynchronizedTextFrame
Fixed
  • ID3v2: Disallow 4 character TXXX/WXXX frame descriptions from being converted to ItemKey (issue) (PR)
  • MPEG: Durations estimated by bitrate are more accurate (PR)
  • MP4:
    • Bitrate calculation is now more accurate (PR)
    • Existing tags will no longer be overridden if another udta atom is encountered (PR)
  • WAV: Bitrate calculation is now more accurate (PR)
  • MusePack: Overall improved audio properties (PR)

v0.19.2

Compare Source

Added
  • Length: impl<T: Length> Truncate for &mut T

v0.19.1

Compare Source

Added
  • Truncate: impl<T: Truncate> Truncate for &mut T (PR)
  • Length: impl<T: Length> Truncate for &T (PR)
Changed
  • MP4: All surrounding free atoms will be used when writing ilst tags (issue) (PR)
    • Previously, only the free atoms immediately surrounding the ilst atom were used.

v0.19.0

Compare Source

Added
  • WriteOptions (issue) (PR):
    • ⚠️ Important ⚠️: This update introduces WriteOptions to allow for finer grained control over how
      Lofty writes tags. These are best used as global user-configurable options, as most options will
      not apply to all files. The defaults are set to be as safe as possible,
      see here.
  • Generic Writes (PR):
    • ⚠️ Important ⚠️: This update introduces FileLike, which is a combination of the Truncate + Length traits
      that allows one to write to more than just Files. In short, Cursor<Vec<u8>> can now be written to.
  • ChannelMask
    • BitAnd and BitOr implementations (PR)
    • Associated constants for common channels, ex. ChannelMask::FRONT_LEFT (PR)
    • ChannelMask::from_{mp4, opus}_channels
  • Opus: OpusProperties now contains the channel mask
  • AAC: AacProperties now contains the channel mask
  • Prelude: lofty::prelude module to make trait imports easier (PR)
Changed
  • ID3v2: Ignore empty duplicate frames (PR)
    • Some software will apparently write an empty duplicate frame after the actual frame. As the latest frame
      is the only one that gets preserved, we now check if the frame is empty before replacing.
  • Properties: FileProperties and ChannelMask have been moved from the root to the new lofty::properties
    module (PR)
  • ParseOptions/WriteOptions/GlobalOptions:
    • ⚠️ Important ⚠️: Moved to lofty::config (PR)
  • AudioFile/TaggedFileExt/TaggedFile/BoundTaggedFile/FileType:
    • ⚠️ Important ⚠️: Moved to lofty::file (PR)
  • Tag:
    • ⚠️ Important ⚠️- The following items have been moved to lofty::tag (PR):
      • Tag
      • Accessor
      • TagType
      • TagItem
      • ItemKey
      • ItemValue
  • Probe:
    • ⚠️ Important ⚠️- Moved to lofty::probe (PR):
  • Picture:
    • ⚠️ Important ⚠️- The following items have been moved to lofty::picture (PR):
      • Picture
      • PictureType
      • PictureInformation
      • MimeType
  • IFF (PR):
    • AIFF: AIFFTextChunks renamed to AiffTextChunks
    • RIFF: RIFFInfoList renamed to RiffInfoList
Fixed
  • Vorbis: Fix panic when reading properties of zero-length files (issue) (PR)
  • ID3v2:
    • Fix panic when reading a UTF-16 with no BOM (issue) (PR)
    • Fix panic when reading an RVA2 frame with a peak larger than 248 bits (issue) (PR)
  • WAV: Length and bitrate values are properly rounded (PR)
  • ParseOptions: No longer derives {PartialOrd, Ord} (PR)
ogg_pager

See [ogg_pager's changelog].

v0.18.2

Compare Source

Fixed
  • MP4: Padding for shrinking tags will no longer overwrite unrelated data (PR)

v0.18.1

Compare Source

Fixed
  • ID3v2: Fix panic in UTF-16 parsing when BOM is missing (issue) (PR)
  • MP4:
    • Properly handle track/disc numbers greater than 16 bits (PR)
    • Atom offset updates will now be properly handled for shrinking tags (PR)

v0.18.0

Compare Source

Added
  • MP4: Check if audio streams are DRM protected, exposed as Mp4Properties::is_drm_protected() (PR)
  • ID3v2:
    • Add Id3v2ErrorKind::EmptyFrame (PR)
    • Support converting some TIPL frame values into generic TagItems (PR)
      • Supported TIPL keys are: "producer", "arranger", "engineer", "DJ-mix", "mix".
  • GlobalOptions: Options local to the thread that persist between reads and writes (PR)
  • ItemKey: ItemKey::IntegerBpm (issue) (PR)
Changed
  • ID3v1: Renamed GENRES[14] to "R&B" (Previously "Rhythm & Blues") (PR)
  • MP4: Duration milliseconds are now rounded to the nearest whole number (PR)
  • ID3v2:
    • Stop erroring on empty frames when not using ParsingMode::Strict (PR)
    • Verify contents of flag items (ItemKey::FlagCompilation, ItemKey::FlagPodcast) (PR)
    • Id3v2Tag::get_text() will now return the raw, unedited string (PR)
      • Previously, all null separators were replaced with "/" to make the string easier to display.
        Now, null separators are only replaced in Accessor methods.
        It is up to the caller to decide how to handle all other strings.
  • resolve: Custom resolvers will now be checked before the default resolvers (PR)
  • MPEG: Up to max_junk_bytes will now be searched for tags between the start of the file and the first MPEG frame (PR)
    • This allows us to read and write ID3v2 tags that are preceeded by junk
  • ItemKey:
    • Renamed ItemKey::PodcastReleaseDate to ItemKey::ReleaseDate (PR)
    • Renamed ItemKey::{PodcastURL, PoddcastGlobalUniqueID} to ItemKey::{PodcastUrl, PoddcastGlobalUniqueId} (issue) (PR)
Fixed
  • MP4:
    • The dfLa atom for FLAC streams will now be found, providing better properties (PR)
    • Offset atoms (stco, co64, and tfhd) will now be updated when writing (issue) (PR)
    • ItemKey::FlagPodcast will be checked in Tag -> Ilst conversion (PR)
  • ID3v2: Support UTF-16 encoded TIPL frames with a single BOM (issue) (PR)
  • Speex: Estimate bitrate when the nominal bitrate is not available (PR)
    • When no nominal bitrate was provided, the bitrate was previously set to 0. Now we will give an estimate based
      on the stream length, which may or may not be entirely accurate.
Removed
  • ItemKey: ItemKey::InvolvedPeople
  • MimeType: MimeType::None, Picture now stores an Option<MimeType>.
  • ID3v2: TextSizeRestrictions::None and ImageSizeRestrictions::None
    • TagRestrictions now stores an Option<TextSizeRestrictions> and Option<ImageSizeRestrictions>.
  • MPEG: Emphasis::None, MpegProperties now stores an Option<Emphasis>.

v0.17.1

Compare Source

Changed
  • MP4: Skip over invalid ilst atoms by default (issue) (PR)

v0.17.0

Compare Source

Added
  • ParseOptions: ParseOptions::allocation_limit to change the default allocation limit. (PR)
  • ID3v2: Id3v2Tag::genres to handle all the ways genres can be stored in TCON frames. (PR)
Changed
  • VorbisComments: When converting from Tag to VorbisComments, ItemKey::Unknowns will be checked for spec compliance. (PR)
  • ID3v2: Any trailing null terminators will be trimmed when reading Comment, Text, UserText, UserUrl, and UnsynchronizedText frames. (PR)
  • Alloc: The default allocation limit for any single tag item is now 16MB. (PR)
  • Probe: Probe::set_file_type() will return the Probe to allow for builder-style usage. (PR)
Fixed
  • MP4: Verify atom identifiers fall within a subset of characters (PR)
    • For a multitude of reasons, garbage data can be left at the end of an atom, resulting in Lofty attempting to
      parse it as another atom definition. As the specification is broad, there is no way for us to say with certainty
      that an identifier is invalid. Now we unfortunately have to guess the validity based on the commonly known atoms.
      For this, we follow [TagLib]'s checks.
  • ID3v1: No longer error on inputs shorter than 128 bytes (the length of an ID3v1 tag). (PR)
  • ID3v2: No longer error on multi-value UTF-16 encoded text frames (issue) (PR)
Removed
  • MP4: Ilst::{track_total, disc_number, disc_total} (PR)
    • These existed prior to the methods on Accessor. There is no need to keep them around, as they behave the same.

v0.16.1

Compare Source

Fixed
  • MP4: Skip unexpected or empty data atoms in ilst (PR)
    • It is possible for an ilst item to have both empty data atoms and unexpected (likely vendor-specific) atoms other than data.
      These are both cases we can safely ignore unless using ParsingMode::Strict.

v0.16.0

Compare Source

Added
  • ID3v2:
    • Support for "RVA2", "OWNE", "ETCO", and "PRIV" frames through
      id3::v2::{RelativeVolumeAdjustmentFrame, OwnershipFrame, EventTimingCodesFrame, PrivateFrame} (PR)
    • FrameId now implements Display (PR)
    • Id3v2Tag::get_texts for multi-value text frames (PR)
  • MP4 (PR):
    • Atom::into_data
    • Atom::merge
  • OGG: Support for reading "COVERART" fields, an old deprecated image storage format. (issue) (PR)
Changed
  • ID3v2:
    • Tag header parsing errors will be ignored unless using ParsingMode::Strict (PR)
    • For spec compliance, Id3v2Tag::insert will now check for frames that are only meant to appear
      in a tag once and remove them. Those frames are: "MCDI", "ETCO", "MLLT", "SYTC", "RVRB", "PCNT", "RBUF", "POSS", "OWNE", "SEEK", and "ASPI". (PR)
    • Id3v2Tag::remove will now take a FrameId rather than &str (PR)
    • FrameId now implements Into<Cow<'_, str>>, making it possible to use it in Frame::new (PR)
    • Id3v2Tag getters will now use &FrameId instead of &str for IDs (PR)
  • MP4 (PR):
    • Ilst::remove will now return all of the removed atoms
    • Ilst::insert_picture will now combine all pictures into a single covr atom
    • Ilst::insert will now merge atoms with the same identifier into a single atom
  • FLAC:
    • Allow multiple Vorbis Comment blocks when not using ParsingMode::Strict (PR)
      • This is not allowed by spec, but is still possible
        to encounter in the wild. Now we will just take whichever tag happens to be latest in the stream and
        use it, they will not be merged.
    • Allow picture types greater than 255 when not using ParsingMode::Strict (issue) (PR)
      • This is not allowed by spec, but has been encountered
        in the wild. Now we will just cap the picture type at 255.
Fixed
  • WavPack: Custom sample rates will no longer be overwritten (PR)
    • When a custom sample rate (or multiplier) was encountered, it would accidentally be overwritten with 0, causing
      incorrect duration and bitrate values.
  • APE: Reading properties on older files will no longer error (PR)
    • Older APE stream versions were not properly handled, leading to incorrect properties and errors.
  • ID3v2: Don't expect text frames to be null terminated (issue) (PR)

v0.15.0

Compare Source

Added
  • ID3v2:
    • Id3v2ErrorKind::UnsupportedFrameId (PR)
    • FrameValue::KeyValue for TIPL/TMCL frames (PR)
    • Id3v2Tag::get_user_text, Id3v2Tag::insert_user_text, and Id3v2Tag::remove_user_text for working with TXXX frames (PR)
  • ParseOptions: ParseOptions::max_junk_bytes, allowing the parser to sift through junk bytes to find required information, rather than
    immediately declare a file invalid. (discussion) (PR)
  • WavPack: WavPackProperties now contains the channel mask, accessible through WavPackProperties::channel_mask() (PR)
  • AIFF:
    • AiffProperties to hold additional AIFF-specific information
    • AIFC compression types are now exposed through AiffCompressionType
Changed
  • ID3v2:
    • Id3v2ErrorKind::BadFrameId now contains the frame ID (PR)
    • Bad frame IDs will no longer error when using ParsingMode::{Relaxed, BestAttempt}. The parser will now just move on to the next frame. (PR)
  • APE: The default track/disk number is now 0 to line up with ID3v2.
    This is only used when set_{track, disk}_total is used without a corresponding set_{track, disk}.
  • VorbisComments: When writing, items larger than u32::MAX will throw ErrorKind::TooMuchData, rather than be silently discarded.
  • AIFF: AiffFile will no longer use FileProperties. It now uses AiffProperties.
Fixed
  • APE: Track/Disk number pairs are properly converted when writing (issue) (PR)
  • ID3v2: TIPL/TMCL frames will no longer be read as a single terminated string (issue) (PR)
  • WavPack: Multichannel files will no longer be marked as mono, supporting up to 4095 channels (PR)

v0.14.0

Compare Source

Added
  • ParsingMode: A new variant, BestAttempt will attempt to fill holes in otherwise valid tag items (PR)
  • 🎉 Support for Musepack files (issue) (PR)
Changed
  • Probe: The default ParsingMode is now ParsingMode::BestAttempt (It was previously ParsingMode::Strict)
  • Alloc:
    • ⚠️ Important ⚠️: The allocation limit for any single tag item is now 8MB (PR).
      This is not configurable yet (issue).
Fixed
  • MP4: Fixed potential panic with malformed plID atoms (issue) (PR)
Removed
  • ID3v2: Removed id3::util::synchsafe::unsynch_content. This has been replaced with UnsynchronizedStream.

v0.13.0

Compare Source

Added
  • Tag/ItemValue: Tag::remove_empty/ItemValue::is_empty (PR)
  • ItemKey: Variants for MusicBrainz Release group/Artist/Release artist/Work IDs (PR)
  • ID3v2:
    • ItemKey::{Barcode, CatalogNumber} mappings (PR)
    • SynchsafeInteger trait to convert multiple integer types to/from their unsynchronized variants (PR)
    • Concrete types for all FrameValue variants (PR)
    • Support for the audio-text accessibility (ATXT) frame (PR)
  • VorbisComments: ItemKey::Barcode mapping (PR)
Changed
  • ID3v1: ID3v1Tag -> Id3v1Tag
  • ID3v2:
    • SyncTextInformation no longer uses a String for its language (PR)
    • FrameID -> FrameId
    • ID3v2Version -> Id3v2Version
    • ID3v2TagFlags -> Id3v2TagFlags
    • ID3v2Tag -> Id3v2Tag
    • There are fewer redundant, intermediate allocations (PR)
  • FileType/TagType/ItemKey: All variants have been changed to UpperCamelCase (PR)
  • MPEG:
    • MPEGFile -> MpegFile
    • MPEGProperties -> MpegProperties
Fixed
  • ID3v2: Compressed frames are now properly handled (PR)
Removed
  • ID3v2:
    • All uses of ID3v2ErrorKind::Other have been replaced with concrete errors
    • SyncTextInformation and GEOBInformation have been flattened into their respective items (PR)

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot changed the title Update Rust crate lofty to 0.15.0 Update Rust crate lofty to 0.16.0 Oct 1, 2023
@renovate renovate bot changed the title Update Rust crate lofty to 0.16.0 Update Rust crate lofty to 0.16.1 Oct 15, 2023
@renovate renovate bot changed the title Update Rust crate lofty to 0.16.1 fix(deps): update rust crate lofty to 0.16.1 Oct 29, 2023
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.16.1 fix(deps): update rust crate lofty to 0.17.0 Nov 15, 2023
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.17.0 fix(deps): update rust crate lofty to 0.17.1 Nov 26, 2023
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.17.1 fix(deps): update rust crate lofty to 0.18.0 Jan 12, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.18.0 fix(deps): update rust crate lofty to 0.18.2 Jan 23, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.18.2 fix(deps): update rust crate lofty to 0.19.0 Apr 21, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.19.0 fix(deps): update rust crate lofty to 0.19.2 Apr 26, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.19.2 fix(deps): update rust crate lofty to 0.19.0 May 5, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.19.0 fix(deps): update rust crate lofty to 0.20.0 Jun 6, 2024
@renovate renovate bot changed the title fix(deps): update rust crate lofty to 0.20.0 fix(deps): update rust crate lofty to 0.21.0 Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants