-
-
Notifications
You must be signed in to change notification settings - Fork 64
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
Failed loading manifest #137
Comments
Could also be fallout like #135 (comment)? Looks like workspaces weren't tested recently. |
It is likely that. Won't have time to look into this for a while unfortunately, so contributions here are welcomed. |
Hmm, that's unfortunate. I hit this in a CI pipeline as well which pulled the latest patch release. I use virtual workspaces across several projects, and this thread has been helpful understanding the issue. As for solutions, let's see if I can get my head around the factors. First, it looks like the changes introduced are aimed at avoiding copying extra libraries which are unneeded/harmful. It tries to do so by looking at
@mightyguava wrote the above, and it's mostly correct. Every rust package can have 0 or 1 libraries, per the cargo book. However, the code as-is assumes that we are parsing a manifest for a single package rather than a workspace, which may contain multiple packages. I'm not sure that the current model's assumptions hold for more complex projects. In the simple case, there is only one library, so you just recursively parse the workspace member manifests and then get the library/package name. That would work for my use case, but I feel there's something missing for the general case. Thoughts? |
How are you invoking We never run the build at the workspace level. Does that automatically build all packages in the workspace? If so, then maybe cargo-ndk may want to revert to the old behavior of copying the whole target directory on build in this scenario... or probably better, parse all member manifests and copy every lib found. |
@mightyguava see https://doc.rust-lang.org/cargo/reference/workspaces.html#the-default-members-field. Afaik this defaults to the root |
My use case is perhaps similar to @fenhl's as I'm using UniFFI. While there is more than one way to do it, I found that it's easiest to use a gradle plugin. Here is my invocation.
@MarijnS95's answer is correct. However, you raise an interesting idea in the first half of your comment. It looks like the gradle plugin lets you pass arbitrary cargo args. It looks like I can pass I don't know if this will work if you need to bundle multiple libraries, but it works for my use case. |
I have yanked 3.5.5 and 3.5.6. This'll have to be revisited in 3.6.x or later. |
why is this closed? this still happens for us on |
Ah shit, yeah the offending changes were never reverted. I'll yank this too lol |
First off, thank you for this excellent crate!
Same on
See commit: quinn-rs/quinn@7b74ffe See GitHub Action run: https://github.com/quinn-rs/quinn/actions/runs/10450996767/job/28936466966
See commit: quinn-rs/quinn@898cba1 See GitHub Action run: https://github.com/quinn-rs/quinn/actions/runs/10451996839/job/28939531590?pr=1950 Discovered on quinn-rs/quinn#1950. |
It is yanked! |
## Description cargo-ndk has [known issues](bbqsrc/cargo-ndk#137) with workspace setups for versions 3.5.5 and up. Ensuring docker test runs start with a fresh docker setup. ## Breaking Changes <!-- Optional, if there are any breaking changes document them, including how to migrate older code. --> ## Notes & open questions <!-- Any notes, remarks or open questions you have to make about the PR. --> ## Change checklist - [ ] Self-review. - [ ] Documentation updates following the [style guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text), if relevant. - [ ] Tests if relevant. - [ ] All breaking changes documented.
@mxinden @dignifiedquire could you try with the |
@bbqsrc (There is an unrelated issue with the emulator.) |
## Description cargo-ndk has [known issues](bbqsrc/cargo-ndk#137) with workspace setups for versions 3.5.5 and up. Ensuring docker test runs start with a fresh docker setup. ## Breaking Changes <!-- Optional, if there are any breaking changes document them, including how to migrate older code. --> ## Notes & open questions <!-- Any notes, remarks or open questions you have to make about the PR. --> ## Change checklist - [ ] Self-review. - [ ] Documentation updates following the [style guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text), if relevant. - [ ] Tests if relevant. - [ ] All breaking changes documented.
## Description cargo-ndk has [known issues](bbqsrc/cargo-ndk#137) with workspace setups for versions 3.5.5 and up. Ensuring docker test runs start with a fresh docker setup. ## Breaking Changes <!-- Optional, if there are any breaking changes document them, including how to migrate older code. --> ## Notes & open questions <!-- Any notes, remarks or open questions you have to make about the PR. --> ## Change checklist - [ ] Self-review. - [ ] Documentation updates following the [style guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text), if relevant. - [ ] Tests if relevant. - [ ] All breaking changes documented.
I have a package
night-uniffi
that's part of a virtual workspace. Withcargo-ndk
3.5.4, everything works fine. Withcargo-ndk
3.5.6, the commandcargo ndk --platform=34 --target=arm64-v8a build --package=night-uniffi --lib
errors with the following output:The text was updated successfully, but these errors were encountered: