fix: RSS channel metadata leakage / crash, and ZIP option forwarding - #2281
Open
4ngv4eek4k1hpa wants to merge 3 commits into
Open
fix: RSS channel metadata leakage / crash, and ZIP option forwarding#22814ngv4eek4k1hpa wants to merge 3 commits into
4ngv4eek4k1hpa wants to merge 3 commits into
Conversation
Signed-off-by: 4ngv4eek4k1hpa <4ngv4eek4k1hpa@users.noreply.github.com>
Signed-off-by: 4ngv4eek4k1hpa <4ngv4eek4k1hpa@users.noreply.github.com>
Signed-off-by: 4ngv4eek4k1hpa <4ngv4eek4k1hpa@users.noreply.github.com>
|
4ngv4eek4k1hpa please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.
Contributor License AgreementContribution License AgreementThis Contribution License Agreement (“Agreement”) is agreed to by the party signing below (“You”),
|
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.
Summary
getElementsByTagNameis recursive, so a feed without<title>incorrectly stole the first item/entry title (metadata leakage).md_textbefore conditionals so feeds with no titles no longer raiseUnboundLocalError(bug: RSS converter crashes with UnboundLocalError when channel title is missing #1946).# Nonewhen the feed title is missing.keep_data_uris) into nestedconvert_streamcalls, and skip directory-only zip entries.Why
Real-world RSS exports often omit channel
<title>. That used to either crash conversion or silently use an item title as the feed title. ZIP members also ignored per-call options that standalone conversion honors.Test plan
python packages/markitdown/tests/test_rss_zip_fixes.py(RSS leak/crash + ZIP keep_data_uris)test_rss.xmlvector still converts with channel title preferred