Skip to content

fix(docreader): encode spaces in remote HTML image and link URLs - #6241

Open
Yzzz88 wants to merge 1 commit into
Tencent:mainfrom
Yzzz88:fix/html-remote-url-spaces
Open

Yzzz88 wants to merge 1 commit into
Tencent:mainfrom
Yzzz88:fix/html-remote-url-spaces

Conversation

@Yzzz88

@Yzzz88 Yzzz88 commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

Description

HTML pages often name diagrams and downloadable manuals with spaces, such as Deployment Diagram.png. The converter emitted these HTTP URLs literally in Markdown destinations, producing invalid image/link syntax. Encode literal spaces in remote HTTP(S) image and anchor attributes before conversion. Existing percent escapes and local archive image keys remain intact.

Testing

The image and download regressions fail on main. Three new cases plus nine existing image/footer cases pass (12 total), using the real HTML converter and locked markdownify 1.2.0. Python compilation and git diff --check pass. Local tests use an isolated parser loader to skip unrelated Office/PDF registry imports; no live download or full docreader service/suite was run.

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant