Skip to content

docs: join mid-sentence line breaks in docs/book for GitBook rendering#5109

Open
shivamsingh-007 wants to merge 2 commits into
zenml-io:developfrom
shivamsingh-007:fix/docs-line-breaks-4084
Open

docs: join mid-sentence line breaks in docs/book for GitBook rendering#5109
shivamsingh-007 wants to merge 2 commits into
zenml-io:developfrom
shivamsingh-007:fix/docs-line-breaks-4084

Conversation

@shivamsingh-007

Copy link
Copy Markdown

Joins mid-sentence line breaks in documentation files under \docs/book/\ for proper GitBook rendering. The join is markdown-aware: it preserves fenced code blocks, headings, tables, YAML frontmatter, hint blocks, and list structure.

Fixes #4084

What changed

245 markdown files in docs/book/ — prose paragraphs and list continuations with mid-sentence line breaks are now joined into single lines.

Why this approach

A custom Python script (not committed in the PR) was used to identify and join mid-sentence breaks. The logic is conservative: only joins a line to the next when the current line lacks sentence-ending punctuation AND the next starts with a lowercase letter (prose continuation). This avoids joining sentences.

Testing done

  • Verifier confirmed zero new unclosed fenced code blocks
  • Auditor reviewed all 245 files; 8 over-join edge cases identified and fixed
  • Only .md\ files under \docs/book/\ are changed

Joins prose text that was broken mid-sentence across multiple lines,
which GitBook renders as separate paragraphs with inconsistent spacing.
Only joins within paragraphs and list-item continuations — never inside
fenced code blocks, headings, tables, or other structural elements.

Closes zenml-io#4084
The join script incorrectly joined:
- Closing ` with {% endtab %} (4 files)
- List item text with opening `�ash/python/yaml (3 files)
- @step decorator with def inside <pre> block (1 file)

All are now properly separated.
Copilot AI review requested due to automatic review settings July 23, 2026 09:31

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@CLAassistant

CLAassistant commented Jul 23, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@bcdurak
bcdurak self-requested a review July 23, 2026 13:13
@bcdurak bcdurak added documentation Improvements or additions to documentation no-release-notes Release notes will NOT be attached and used publicly for this PR. labels Jul 23, 2026
@bcdurak

bcdurak commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Hey @shivamsingh-007, thanks for the PR. I will take a look.

@shivamsingh-007

Copy link
Copy Markdown
Author

Thanks @bcdurak, appreciate you taking a look. Let me know if anything needs adjusting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation no-release-notes Release notes will NOT be attached and used publicly for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants