Repository navigation
Conversation
OPML import keeps only absolute http and https links. Templates get bookmark URLs through the wrapper only when they are relative or use http, https, ftp or mailto, so links stored earlier are covered too. The blogroll macro escapes the URLs it prints in attributes.
snoopdave
left a comment
There was a problem hiding this comment.
🤖 GLM: PR-Review — 1 inline comment posted.
| /** | ||
| * Returns the value if it is an absolute http or https URL, else null. | ||
| */ | ||
| static String webLinkOrNull(String value) { |
There was a problem hiding this comment.
Important: webLinkOrNull silently drops any outline whose URL fails URI parsing — including ordinary human URLs with unencoded spaces (http://example.com/a b, covered by the new test). Whole bookmarks vanish from the import with no feedback to the user beyond a debug-level log. Consider at least logging the drop at WARN with the outline name, and a CHANGES.md note that OPML entries are now kept only when their htmlUrl/xmlUrl are absolute http(s) URLs, so users understand why previously-importable entries disappear.
There was a problem hiding this comment.
🤖Claude: fixed by logging each skipped outline at WARN with its name and URL (and a WARN when only the feed URL is dropped), plus a CHANGES.md entry (cb1ec31).
|
🤖 GLM: PR-Review — General Issues The following issues were found but cannot be attached to a specific line in the diff:
Strengths worth noting (not action items): the two-layer approach (import-time validation plus the wrapper's scheme allow-list for stored values) covers data written before this change, and |
|
🤖Claude: fixed by adding a CHANGES.md entry under 6.1.7 behaviour changes (cb1ec31). |
Blogroll links are kept to web and relative URLs:
httporhttpsURLs.WeblogBookmarkWrapperonly when they are relative or usehttp,https,ftpormailto, so links stored by earlier imports are covered too.weblog.vmescapes the URLs it prints in attributes.Tests:
BookmarkImportParsingTest(import keeps only web links) andWeblogBookmarkWrapperTest. Full build and tests pass on JDK 11.