contentauth / c2pa-rs

Rust SDK for the core C2PA (Coalition for Content Provenance and Authenticity) specification
Other
99 stars 42 forks source link

Upgrade uuid to 1.7.0 & fix removed wasm-bindgen feature #450

Open diliop opened 2 months ago

diliop commented 2 months ago

Changes in this pull request

Since uuid PR #536 the wasm-bindgen feature has be renamed to js and since PR #727, the wasm-bindgen dependency is optional and marked so using dep:wasm-bindgen under the js feature. With both these in place, given a Cargo.toml file that depends on uuid = "1.7.0":

[package]
name = "some_bin"
version = "0.1.0"
edition = "2021"

[dependencies]
uuid = "1.7.0"
c2pa = "0.29.1"

running cargo build will generate the following error:

error: failed to select a version for `uuid`.
    ... required by package `c2pa v0.29.1`
    ... which satisfies dependency `c2pa = "^0.29.1"` of package `some_bin v0.1.0 (/home/diliopoulos/bucket/some_bin)`
versions that meet the requirements `^1.3.1` are: 1.8.0, 1.7.0, 1.6.1, 1.6.0, 1.5.0, 1.4.1, 1.4.0, 1.3.4, 1.3.3, 1.3.2, 1.3.1

the package `c2pa` depends on `uuid`, with features: `wasm-bindgen` but `uuid` does not have these features.
 It has an optional dependency with that name, but that dependency uses the "dep:" syntax in the features table, so it does not have an implicit feature with that name.

all possible versions conflict with previously selected packages.

  previously selected package `uuid v1.7.0`
    ... which satisfies dependency `uuid = "^1.7.0"` of package `some_bin v0.1.0 (/home/diliopoulos/bucket/some_bin)`

failed to select a version for `uuid` which could resolve this conflict

Upgrading uuid to 1.70.0 and replacing the wasm-bindgen feature with js in sdk/Cargo.toml fixes the above.

Checklist

gpeacock commented 2 months ago

Hi, thanks for submitting this. It is ready to go except for the Adobe CLA requirement. It basically just says you agree to not contribute anything that you don't have the rights to contribute. https://opensource.adobe.com/cla.html

diliop commented 1 month ago

@gpeacock I signed the Adobe CLA a while back, let me know if there is anything else you need from me to merge this