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

Wasm dependencies not marked as optional #104

Open
theunkn0wn1 opened this issue Aug 8, 2024 · 0 comments
Open

Wasm dependencies not marked as optional #104

theunkn0wn1 opened this issue Aug 8, 2024 · 0 comments

Comments

@theunkn0wn1
Copy link

The wasm dependencies are not marked as optional, making them mandatory during dependency resolution.
the wasm features should be marked as optional in the dependencies, and enabled via feature flag.

This non-optional status causes dependency resolution issues downstream for non-wasm targets that want to use a newer chrono package version (indirect dependency of wasm in this crate).

image

error: failed to select a version for `wasm-bindgen-shared`.
    ... required by package `wasm-bindgen-macro-support v0.2.40`
    ... which satisfies dependency `wasm-bindgen-macro-support = "=0.2.40"` of package `wasm-bindgen-macro v0.2.40`
    ... which satisfies dependency `wasm-bindgen-macro = "=0.2.40"` of package `wasm-bindgen v0.2.40`
    ... which satisfies dependency `wasm-bindgen = "^0.2.23"` of package `web-sys v0.3.0`
    ... which satisfies dependency `web-sys = "^0.3"` of package `quanta v0.12.0`
    ... which satisfies dependency `quanta = "^0.12"` of package `clickhouse v0.12.1`
    ... which satisfies dependency `clickhouse = "^0.12.1"` (locked to 0.12.1) of package `REDACTED v3.4.0 (/REDACTED)`
versions that meet the requirements `=0.2.40` are: 0.2.40

the package `wasm-bindgen-shared` links to the native library `wasm_bindgen`, but it conflicts with a previous package which links to `wasm_bindgen` as well:
package `wasm-bindgen-shared v0.2.92`
    ... which satisfies dependency `wasm-bindgen-shared = "=0.2.92"` (locked to 0.2.92) of package `wasm-bindgen-macro-support v0.2.92`
    ... which satisfies dependency `wasm-bindgen-macro-support = "=0.2.92"` (locked to 0.2.92) of package `wasm-bindgen-macro v0.2.92`
    ... which satisfies dependency `wasm-bindgen-macro = "=0.2.92"` (locked to 0.2.92) of package `wasm-bindgen v0.2.92`
    ... which satisfies dependency `wasm-bindgen = "^0.2"` (locked to 0.2.92) of package `chrono v0.4.38`
    ... which satisfies dependency `chrono = ">=0.4.20, <1"` (locked to 0.4.38) of package `REDACTED v3.4.0 (/REDACTED)`
Only one package in the dependency graph may specify the same links value. This helps ensure that only one copy of a native library is linked in the final binary. Try to adjust your dependencies so that only one package uses the `links = "wasm_bindgen"` value. For more information, see https://doc.rust-lang.org/cargo/reference/resolver.html#links.

failed to select a version for `wasm-bindgen-shared` which could resolve this conflict
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

No branches or pull requests

1 participant