kornelski / lodepng-rust

All-in-one PNG image encoder/decoder in pure Rust
https://lib.rs/lodepng
zlib License
100 stars 23 forks source link

3.1.0 broke semver #45

Closed SpaceManiac closed 4 years ago

SpaceManiac commented 4 years ago

Commit d18dde7422d67b96a4c6a4b32473d9640b13ec53 changed the return type of Info::text_keys_cstr() to something different than before without bumping the major version number, breaking builds and interfering with debugging for some users https://github.com/SpaiR/StrongDMM/issues/63#issuecomment-686881335.

Example code:

    for (key, value) in decoder.info_png().text_keys_cstr() {
        if key.to_str() == Ok("Description") {
            if let Ok(value) = value.to_str() {
                return Ok(value.to_owned());
            }
        }
    }

I can work around this on my end but it caused problems for me so I wanted to complain about it.

kornelski commented 4 years ago

Oops, sorry.

It may be too disruptive to change it again, so I'm going to leave it. I've yanked 3.0.0 instead, so let's pretend that was meant to be changed in v3 from the start.