Skip to content

fix: broaden markdown extractor IRI validation#127

Merged
Jurij89 merged 3 commits intotest/devnet-e2e-sections-18-24from
fix/issue-123-markdown-iri-validation
Apr 12, 2026
Merged

fix: broaden markdown extractor IRI validation#127
Jurij89 merged 3 commits intotest/devnet-e2e-sections-18-24from
fix/issue-123-markdown-iri-validation

Conversation

@Jurij89
Copy link
Copy Markdown
Contributor

@Jurij89 Jurij89 commented Apr 12, 2026

Summary

  • replace the remaining narrow http/https/did/urn IRI allowlists in markdown-extractor.ts with a shared absolute-scheme + isSafeIri helper
  • preserve valid non-whitelist IRIs like tag:, doi:, and ark: in frontmatter type, generic frontmatter scalar values, and Dataview field values
  • stop passing malformed scheme-prefixed values through as raw IRIs by falling back to the existing schema-class or literal branches
  • add focused extractor regressions for the three issue-123 sites

Verification

  • pnpm exec vitest run test/extraction-markdown.test.ts
  • pnpm exec vitest run test/import-file-integration.test.ts

Docs

  • No separate dkgv10-spec PR needed for this fix. The current spec already describes these values generically and does not define the narrow implementation allowlist that this PR removes.

Comment thread packages/cli/src/extraction/markdown-extractor.ts Outdated
Comment thread packages/cli/src/extraction/markdown-extractor.ts
Comment thread packages/cli/src/extraction/markdown-extractor.ts
Comment thread packages/cli/src/extraction/markdown-extractor.ts
Comment thread packages/cli/src/extraction/markdown-extractor.ts
Comment thread packages/cli/src/extraction/markdown-extractor.ts
@Jurij89 Jurij89 merged commit c0db599 into test/devnet-e2e-sections-18-24 Apr 12, 2026
1 check passed
@branarakic branarakic mentioned this pull request Mar 25, 2026
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