Using include-first in workspace members
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 76/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- rust
- Domain
- build-system
Research direction
Start in src/lib.rs at line 50 and reproduce the path resolution while building a workspace member crate. Check the behavior of CARGO_MANIFEST_DIR for the current package, then verify that src/{...} resolves within the member directory rather than the workspace root.
Written by the indexing model from the issue text.
Description
When building a workspace, the working directory during build will be root directory. When building member crates src/{} will point to root/src/{} instead of root/member/src/{} here.
I suggest changing this line to something like this:
let filename = Path::new(&std::env::var("CARGO_MANIFEST_DIR").unwrap()).join("src").join(filename.trim_matches('"'));
CARGO_MANIFEST_DIR always points to the directory of the package currently being built.
- Dominant language
- Rust
- Stars
- 3
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
ontola/atomic-server#1625 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
VirusTotal/yara-x#777 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
stratum-mining/stratum#2404 ·
-
bug ci good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 88/100