Skip to content

An out-of-sync uniffi-bindgen tool can create bugs #38

Closed
@thunderbiscuit

Description

@thunderbiscuit

The uniffi_bindgen_generate.sh script calls the uniffi-bindgen cli tool installed on the user's local machine, but if the tool is out of sync with the rest of the uniffi libraries used in Cargo.toml the bindings produced will often not work.

The long-term solution used by Mozilla and which we adopted in the bdk-ffi repo is to create and maintain within the repo a small cli tool which we call ourselves to generate the bindings file, in effect controlling which version of uniffi_bindgen is used to generate the glue file.

The short-term solution is to just add a note to the readme that specifies which version of the uniffi-bindgen tool developers should have on the local setup before running the uniffi_bindgen_generate.sh script. At the moment this is version 0.21.0, which can be downloaded using

cargo install uniffi_bindgen --version 0.21.0

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