Skip to content

fix(privacy): handle file roots in no-split resource imports - #6260

Merged
MaojiaSheng merged 1 commit into
mainfrom
codex/fix-no-split-privacy-root
Oct 19, 2026
Merged

MaojiaSheng merged 1 commit into
mainfrom
codex/fix-no-split-privacy-root

Conversation

@yeshion23333

Copy link
Copy Markdown
Collaborator

Description

Importing a single Markdown file with --args parse_mode:no_split --processing-mode vectors_only can fail with PROCESSING_ERROR: not a directory. Privacy sanitization uses the temporary artifact container's type to choose directory traversal, even when the resolved document root inside that container is a file. Local output stores can silently skip that file instead.

Pass the resolved root_is_file into the sanitizer so it reads and sanitizes the document directly before persistence and indexing. Keep the existing directory traversal and file-type artifact fallback.

Human Involvement

  • A human participated in the implementation or review loop
  • This PR was generated entirely by AI agents without human participation in the loop

Related Issue

Follow-up to #6161.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactoring (no functional changes)
  • Performance improvement
  • Test update

Changes Made

  • Forward the existing document-root classification into Privacy sanitization.
  • Sanitize file roots directly while retaining the directory traversal path.

Testing

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested this on the following platforms:
    • Linux
    • macOS
    • Windows

No new regression tests were added. Validation:

  • 47 existing tests passed across Markdown no-split parsing, resource routing, processing modes, local artifact persistence, and Privacy sanitization.
  • One-off reproduction using the actual Markdown parser and Privacy sanitizer with AGFS/local output-store adapters: confirmed the original file-root failure/skip, successful sanitization and matching manifest hashes after the fix, and unchanged directory traversal/internal-sidecar handling.
  • ruff check, ruff format --check, and git diff --check passed.

Checklist

  • My code follows the project's coding style
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

@MaojiaSheng
MaojiaSheng merged commit ac0f180 into main Oct 19, 2026
8 of 9 checks passed
@MaojiaSheng
MaojiaSheng deleted the codex/fix-no-split-privacy-root branch October 19, 2026 03:30
@github-project-automation github-project-automation Bot moved this from Backlog to Done in OpenViking project Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants