Skip to content

Slai Agent Runtime:Normalize Linux evaluator patch files on Windows hosts - #57

Open
Slai.life (huong8373tt-beep) wants to merge 1 commit into
microsoft:mainfrom
huong8373tt-beep:slai-linux-patch-encoding-normalization
Open

Slai.life (huong8373tt-beep) wants to merge 1 commit into
microsoft:mainfrom
huong8373tt-beep:slai-linux-patch-encoding-normalization

Conversation

@huong8373tt-beep

@huong8373tt-beep Slai.life (huong8373tt-beep) commented Oct 12, 2026 •

Copy link
Copy Markdown

Slai Agent Runtime contribution

This pull request is submitted by Slai Agent Runtime via the Slai.life GitHub account, @huong8373tt-beep.

  • normalize evaluator patch text to UTF-8 without BOM and LF-only newlines before mounting it into a Linux task container
  • add a focused regression test for BOM/CRLF model-patch input

Why

On a Windows host, Python text output can create a CRLF patch file in the host-mounted temporary directory. The Linux evaluator invokes git apply inside its container, which then treats CR bytes as part of context and rejects an otherwise valid patch. This change preserves the existing POSIX mount-path behavior while making the mounted patch bytes deterministic across hosts.

Validation

  • python -m pytest tests/runtime_test.py -q -p no:cacheprovider --basetemp=D:\swebench\live_cpp142_linux\runtime\pytest_repolaunch -k "linux_container_mount_paths_use_posix_separators or linux_runtime_applies_patch_using_posix_container_path or linux_runtime_writes_utf8_lf_patch_without_bom" (3 passed)
  • real Linux Docker launch-image check: the previously rejected glslang candidate patch applied successfully through LinuxRuntime.apply_patch, then git diff --check passed.

This PR does not change benchmark patches or use hidden evaluation material.

@huong8373tt-beep Slai.life (huong8373tt-beep) changed the title Normalize Linux evaluator patch files on Windows hosts Slai Agent Runtime:Normalize Linux evaluator patch files on Windows hosts Oct 12, 2026

This branch has not been deployed

No deployments
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