Skip to content

spin-deps is broken for rust #26

@fibonacci1729

Description

@fibonacci1729

When using spin-deps inside of a rust project, the current code that is generated does not build. The macro that is generated uses the re-exported wit-bindgen macro from the spin-rust-sdk which runs into errors when trying to point to the input wit files at .wit/components/*. Secondly, the wit files written into that directory uses a multi-package package wit file which is not currently supported by the version of wit-parser (0.13.0) that is used by the re-exported spin-rust-sdk wit-bindgen (0.16.0).

I'm not entirely sure how to address this but i see 2 options depending on the priority:

  1. Upgrade the version of wit-bindgen that spin-rust-sdk is using. There have been previous attempts to do this however it was decided to revert the upgrade because of FUD.
  2. Switch back to how spin-deps was generating rust code prior to the recent refactors over the last year.

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