-
Notifications
You must be signed in to change notification settings - Fork 324
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
Add support for Cargo's virtual workspaces #8874
Comments
Is the scope of work needed to implement this known? I.e. is this expected to be a large change, or relatively easy for a new contributor? |
At least to me, the scope is not really clear. I guess it mostly depends on understanding what virtual workspaces are, and how they should semantically map to the ORT data model. From what I've read, in essence virtual workspaces are a way to group projects to ease dependency management. Which would mean that in ORT-speak they are neither projects nor packages, and could simply be omitted (which would be easy). Or, on the other hand, they could be seen as a "fake parent project" that "depends" on the projects it groups (which would be a bit more challenging to implement). |
IMHO ORT can just view virtual workspaces as being used to ensure a consistent set of dependency versions are used across multiple crates. An example file hierarchy might look like
With the result being that the version of |
If that's correct, then I believe ORT could simply ignore Phrased differently, based on your example there should be no need / value in calling Would you agree to that? Do you have a nice & small example project with a virtual workspace plus expected results (in terms of dependencies that should be found) that we could test with? |
https://github.com/hyperium/http-body is a small example of a virtual workspace that fails today, with just two crates and a relatively small dependency tree. The output of Expand output
I'm not entirely sure, to be honest. It seems like The more I look at this, the more skeptical I become that ORT is even doing the correct thing for normal crates today. Having modified the
BUT This means ORT is listing sub-dependencies which are demonstrably not actually included by |
Thanks for the analysis!
That's interesting as
Are you aware of a |
But isn't that a good sign? That sounds to me like an indication that we could omit
Parsing on ORT side you mean? ORT does very little extra parsing / interpretation but more or less just maps all |
I believe this is a weird interaction of |
In this case I wasn't expecting them to be identical. 😄
I'm not, but it looks like there is a I don't know if |
Running Expand output
|
I suppose for the sake of this bug, just ignoring the root Then there's the larger bug of "more crates than expected are included in Rust crate dependency graphs", which can likely be handled separately. |
Virtual worspaces do not define anypackages and thus can simply be filtered out without loosing any information. Resolves #8874. Signed-off-by: Sebastian Schuberth <[email protected]>
Virtual workspaces do not define any packages and thus can simply be filtered out without loosing any information. Resolves #8874. Signed-off-by: Sebastian Schuberth <[email protected]>
Agree, see #9716. |
Agree as well, see #9717. |
Virtual workspaces do not define any packages and thus can simply be filtered out without loosing any information. Resolves #8874. Signed-off-by: Sebastian Schuberth <[email protected]>
Virtual workspaces do not define any packages and thus can simply be filtered out without losing any information. Resolves #8874. Signed-off-by: Sebastian Schuberth <[email protected]>
The text was updated successfully, but these errors were encountered: