Links with empty path cause error
Open
Nobody has claimed this yet.
C-bug
- Dominant language
- Rust
- Stars
- 22.2k
- Forks
- 1.9k
- PR merge metrics
- PR metrics pending
Description
Problem
Metal3 project is using mdbook for documentation. I added a prerocessor to the docs. When the preprocessor is in use mdbook build trows error if there are Draft Chapters aka links with out any path. This is the error: thread 'main' panicked at '', src/utils/fs.rs:45:10.
Steps
- Add a Draft Chapter in the SUMMARY.md
- run mdbook build in directory https://github.com/metal3-io/metal3-docs/tree/main/docs/user-guide or run make netlify-build in the root directory
- get output: thread 'main' panicked at '', src/utils/fs.rs:45:10
Possible Solution(s)
No response
Notes
No response
Version
v0.0.28
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.
Research direction
Reproduce the failure by adding a draft chapter link to SUMMARY.md and running mdbook build or make netlify-build. Start at src/utils/fs.rs:45:10 and trace how the empty path is handled; done means the build completes without panicking for draft chapters.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system, documentation
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100