Skip to content

Unable to use SDK with build target wasm32-wasip1 & wasm32-wasip2 #28

@aturingmachine

Description

@aturingmachine

Description

Attempting to include the flagsmith crate in a project that has a build target of wasm32-wasip1 (or wasm32-wasip2), will cause the build to fail.

Version Information

  • flagsmith = "~2.0.0"

Reproduction

Cause

flagsmith makes use of the blocking feature of the reqwest crate, as seen here. reqwest cannot be compiled with the blocking feature enabled in async environments (see reqwest issue #891), this means flagsmith cannot be used when targeting wasm32-wasip1.

Desired Outcome

I am admittedly unaware of how important the use of reqwest::blocking is for the flagsmith crate, or if it could be updated to use the non-blocking reqwest client - however that would be the best case scenario.

If that is not possible, adding something to the documentation of flagsmith stating that it cannot be built to target wasm would possibly help someone some time in the future if they are attempting to make use of flagsmith while targeting wasm.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions