Skip to content

fix: keep artifact checksums in sync#2973

Open
matthewflint wants to merge 6 commits intoopenai:mainfrom
matthewflint:fix/sandbox-artifact-checksum-sync
Open

fix: keep artifact checksums in sync#2973
matthewflint wants to merge 6 commits intoopenai:mainfrom
matthewflint:fix/sandbox-artifact-checksum-sync

Conversation

@matthewflint
Copy link
Copy Markdown
Contributor

@matthewflint matthewflint commented Apr 20, 2026

Summary

This PR is intentionally stacked on top of #2972.

On top of the safe LocalFile open path from that PR, this change:

  • computes artifact checksums from the same bytes written into the sandbox
  • preserves local source-read errors when write backends wrap stream failures
  • adds focused LocalFile / LocalDir regressions for checksum drift and wrapped read failures

Testing

  • uv run pytest -q tests/sandbox/test_entries.py
  • uv run ruff check src/agents/sandbox/entries/artifacts.py tests/sandbox/test_entries.py

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 344bb4728a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/agents/sandbox/entries/artifacts.py Outdated
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 23168abe77

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/agents/sandbox/entries/artifacts.py
@seratch seratch marked this pull request as draft April 20, 2026 21:26
@seratch seratch changed the title Keep artifact checksums in sync fix: keep artifact checksums in sync Apr 20, 2026
@github-actions github-actions Bot added the bug Something isn't working label Apr 21, 2026
@matthewflint matthewflint force-pushed the fix/sandbox-artifact-checksum-sync branch from e0d869b to 9a939ce Compare April 21, 2026 16:24
@matthewflint
Copy link
Copy Markdown
Contributor Author

Restacked this on top of #2972 and force-pushed a clean history. The PR base is still main, so it includes the #2972 changes for now; intended merge order is #2972 first, then this.

Route LocalFile reads through the same pinned path handling used by LocalDir so symlinked source paths are rejected consistently. Add focused regression coverage for symlinked ancestor and leaf paths.
Signed-off-by: matthewflint <277024436+matthewflint@users.noreply.github.com>
@matthewflint matthewflint force-pushed the fix/sandbox-artifact-checksum-sync branch from 9a939ce to 6407cd1 Compare April 21, 2026 16:31
@matthewflint
Copy link
Copy Markdown
Contributor Author

matthewflint commented Apr 21, 2026

Restacked this on the updated #2972 head and force-pushed. It now inherits the Windows metadata assertion fix; intended merge order is still #2972 first, then this PR.

@matthewflint matthewflint marked this pull request as ready for review April 21, 2026 16:32
@matthewflint matthewflint force-pushed the fix/sandbox-artifact-checksum-sync branch from 6407cd1 to bb060d5 Compare April 21, 2026 16:54
@matthewflint matthewflint force-pushed the fix/sandbox-artifact-checksum-sync branch from bb060d5 to 9f8b53c Compare April 22, 2026 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working feature:sandboxes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant