Repository navigation
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With
markdown-file-links,[guide](guide.md#install)keeps pointing to Markdown instead of HTML. Conversely,[part](guide.html#part.md)changes the fragment to#part.html. The same suffix check affects link definitions.Split off query/fragment suffixes before checking the
.mdfilename and share that conversion between inline links and definitions. Preserve the suffix exactly, including empty?/#delimiters. Also let the extra run after definitions are stripped, so a document containing only a reference link is converted without needing another.mdin the body.Add three regression tests covering 34 inline/reference combinations,
link_defs=False, and unchanged inline images. Update the README with the query/fragment behavior.Validation on Windows, CPython 3.13.5:
cd test && python test.py -- -knownfailurepasses all 299 selected tests with all optional dependencies installed (including version-specific Pygments fixture selection).python test/test_redos.py: all 10 cases pass.git diff --check: clean. No PEP8 diagnostics on added Python lines; existing whole-file diagnostics remain (markdown2.py 412 to 410, test_markdown2.py unchanged at 68).Other Python versions/platforms are left to CI. AI assistance: OpenAI Codex assisted with investigation, code, tests and this description. No human review or personal production usage is claimed.