You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using a workspace that uses a virtual manifest, cargo-docset docset panics with
thread 'main' panicked at 'Cargo.toml doesn't have a package table', src/commands/generate.rs:343:18
A virtual manifest workspace is one without a "root" package. cargo doc works just fine here (cargo doc --workspace --open just opens to the first crate in the workspace members list, but it includes all the crates).
It appears that cargo-docset is attempting to look up the root package name here. For virtual manifest workspaces, it would be really great if it could support a flag to provide a docset name, and default to the name of the containing folder. Until such time as cargo doc synthesizes a proper landing page for the docset, cargo-docset could just default to the first member crate exactly as cargo doc does (or it could synthesize a common landing page).
As a workaround, I can invoke cargo-docset docset --all from one of the member crates, but the resulting docset is named after that member crate.
To Reproduce
Steps to reproduce the behavior:
Make a virtual manifest workspace (a workspace whose Cargo.toml contains a [workspace] section but not a [package] section)
From the root of that workspace, run cargo-docset docset.
Expected behavior
It should build a docset for the workspace.
The text was updated successfully, but these errors were encountered:
It should now work. I haven't provided a flag to rename the docset yet, so the docset's name will be the same as the directory containing the virtual manifest, but it's one of the flags I was planning to add, I'll try to slip it in before the next release, as there's a couple of things I want to do before then. I'm hoping to ship the release by the end of next week :)
Describe the bug
When using a workspace that uses a virtual manifest,
cargo-docset docset
panics withA virtual manifest workspace is one without a "root" package.
cargo doc
works just fine here (cargo doc --workspace --open
just opens to the first crate in the workspace members list, but it includes all the crates).It appears that cargo-docset is attempting to look up the root package name here. For virtual manifest workspaces, it would be really great if it could support a flag to provide a docset name, and default to the name of the containing folder. Until such time as
cargo doc
synthesizes a proper landing page for the docset, cargo-docset could just default to the first member crate exactly ascargo doc
does (or it could synthesize a common landing page).As a workaround, I can invoke
cargo-docset docset --all
from one of the member crates, but the resulting docset is named after that member crate.To Reproduce
Steps to reproduce the behavior:
Cargo.toml
contains a[workspace]
section but not a[package]
section)cargo-docset docset
.Expected behavior
It should build a docset for the workspace.
The text was updated successfully, but these errors were encountered: