Skip to content

fix(translator): reject unresolved image file IDs - #1256

Closed
bloodf wants to merge 9 commits into
mainfrom
v5/1080
Closed

bloodf wants to merge 9 commits into
mainfrom
v5/1080

Conversation

@bloodf

@bloodf bloodf commented Oct 9, 2026 •

Copy link
Copy Markdown
Owner

Current scope and review state — 2026-10-19

Reject scoped Responses image file IDs with HTTP 400 when translating to Chat Completions, while retaining URL precedence and native same-format Responses references. Cover message images and tool-output image arrays through registered conversion, the public POST boundary, and the secondary worker converter.

Repairs and reconciliation

Added worker error-result handling for intentional converter HTTP 400 failures. Follow-up RED/GREEN verification exposed and repaired scoped tool-output image IDs being serialized to text; paired image blocks are now validated before that serialization.

This head also retains the shared macOS fixture repair originating at 42267fb63e70e5d7c49e571230347ff2beb88f29: canonicalize the child fixture working directory so /var and /private/var aliases do not cause a false boundary failure. This is a test-fixture correction, not a relaxation of the production boundary.

The previously identified newer #1256 residual is reconciled in #1297. This does not declare all #1089 protocol-conformance obligations complete, nor require merging both PRs merely to count delivery. Both remain open for maintainer disposition.

Verification and remaining gates

  • Preceding-head evidence: bdd243e3d7ed284ee94ce224a0d6e5c27bca2644 passed 806 expanded offline assertions across 63 files, with zero failures and exact executed-file inventory. Root lint, docs, and pinned commitlint also passed that preceding candidate. These counts do not certify the newer head above.
  • Current-head focused evidence: 53/53 assertions across 6 relevant worker, registered/public Responses, and tool-output suites; intentional RED had 2 failures at the new worker tool-output cases before the fix. Anti-slop/docs and pinned commitlint passed for the repair. This remains focused evidence, not a full checkpoint.
    Current-head full checkpoint: PASS. Independently authenticated 2d7fb0acc7515bed93fc16abdaa7eac8bbefe42e against main e94884312ff6651f80d13f1c862e54a916bc870e: 1,424 eligible test files in four sequential batches; 12,565 passed, 0 failed, 65 reviewed conditional skips. Skipped assertions were not executed and are not counted as passes. Root lint, production build, repository consistency checks and pinned commit-range/title lint passed; website build/docs checks passed. Receipt SHA-256: 4460e6aaca391f848b1172d80248765a9b542a197b57fd3da2c3d9743528319f. Runner SHA-256: 459ecc7a85ce5d2ea2b3dd8fdccdbd971f7135c800944d36219c601cba499d9c. Source continuity: exact first-comment normalization independently verified; all remaining bundle bytes match HEAD. The external reviewed runner reused only hash-verified independent copies of matching locked dependency installations. This is offline gate evidence; live-provider, deployment and other platform acceptance remain limited to separately recorded tests.
  • No new live-provider, browser, or platform-wide acceptance is inferred from offline tests. No baseline failures were added.

The GitHub ruleset requires zero approving reviews and requires resolved review threads. The repository’s independent local review contract still applies. Required exact-head V5 Local CI, strict up-to-date integration, and thread resolution must be satisfied before a later maintainer merge; Vercel success alone is insufficient.

Older statements below about draft publication, missing administrator/confinement proof, mandatory GitHub approving reviews, or unreconciled predecessor work are historical and are superseded by this current section. Older test counts and receipts apply only to their named heads.

Preserved prior PR description and historical evidence

The following is historical context; current scope and verification above supersede stale readiness, gate, dependency and environment claims. Earlier counts apply only to their named heads.

Scope

fix(translator): reject unresolved image file IDs (issue #1080). Draft publication of verified local implementation; base 93f6de6.

Closes #1080

Changed files

  • docs/reference/api.mdx
  • open-sse/translator/request/openai-responses.js
  • tests/translator/bugs-codexCli-responses.test.js

Local evidence

  • Checkpoint: 067a951 committed;23 focused/full12322passed, lint+review+smoke; not merged
  • tests/.test-results.json: 12322 passed / 0 failed / 66 pending of 12388; success=True
  • Docs: docs/reference/api.mdx
  • No baseline additions.

Status

Draft. Not integrated; CI pending. Not merged or released. Publication gates (commitlint) not yet run by this publisher.

Review readiness update — 2026-10-09

Ready for review of the stated, finished PR scope; not ready to merge. This update supersedes earlier draft/parent-only publication wording without removing the original body or user notes.

  • Audited head: 067a951a689c5bc8c892040797dcc69ee4fce6f4; current main at audit: e51ab1c089800c2a70587822189997c482f53654.
  • Required V5 Local CI: missing. No success status is published by this update.
  • Merge requires actual full-CI success for the final exact head, strict up-to-date main, required reviews and resolved review threads. Any rebase or new head invalidates previous head-bound evidence.
  • Missing administrator/confinement proof blocks the serial full-CI/merge path, not review readiness. No gate is waived; no build or test was run for this update.

Retained implementation evidence supports review of the stated PR scope. Historical test counts and older successful checks do not establish integration with current main or a current full-CI pass. Prior local publication notes are historical; no gates were rerun by this delivery worker.

Current scope and review state — 2026-10-28

Reject scoped Responses image file IDs with HTTP 400 when translating to Chat Completions, while retaining URL precedence and native same-format Responses references. Cover message images and tool-output image arrays through registered conversion, the public POST boundary, and the secondary worker converter.

Closes #1080

Scope

  • open-sse/translator/formats/responsesApi.js — responsesImageUrl rejects scoped file_id without URL
  • open-sse/translator/request/openai-responses.js — registered Responses→Chat lowering uses the same helper
  • open-sse/handlers/responsesHandler.js — converter HTTP 400 contract + main's Cursor pre-conversion image validation
  • Docs: docs/reference/api.mdx
  • Tests: tests/unit/responses-file-id-*.test.js, tests/translator/bugs-codexCli-responses.test.js

Integration (this update)

  • Merged origin/main (5209b4aec3953106439231093c0c504af556959f) into v5/1080 (no rebase / no force-push).
  • Conflict: open-sse/handlers/responsesHandler.js only. Resolution keeps both main's validateCursorImages pre-check and this PR's try/catch around convertResponsesApiFormat for HTTP 400.
  • Follow-up fix: capabilities mock in tests/unit/responses-file-id-chatcore.test.js spreads the real module so main's enforceCursorCapabilities remains available.

Exact SHAs

  • Base: 5209b4aec3953106439231093c0c504af556959f (origin/main)
  • Head: 7a8fe94e80eb60e11c6f77f2b008906cfc3600d0

Tests run (this head)

  • Pinned commitlint @commitlint/cli@18.6.1 --from=origin/main --to=HEAD: PASS (0 problems; 1 historical footer warning)
  • PR title commitlint: PASS
  • Focused: cd tests && node node_modules/vitest/vitest.mjs run translator/bugs-codexCli-responses.test.js unit/responses-file-id-chatcore.test.js unit/responses-file-id-handler.test.js unit/local-ci.test.js --maxWorkers=2 → 51/51 passed
  • cd tests && npm run test:ci → PASS — 13519 passed / 0 failed / 66 pending of 13585

Docs / baseline

  • Docs: docs/reference/api.mdx (unchanged intent from PR)
  • Baseline impact: none — tests/__baseline__/known-fails.txt not modified

Local-CI pre-check (authoritative runner from clean main; status NOT published)

  • Runner checkout: clean detached origin/main at 5209b4ae… (/tmp/durindoor-local-ci-runner-main-1256)
  • Command: node scripts/local-ci.mjs --base 5209b4aec3953106439231093c0c504af556959f --head 7a8fe94e80eb60e11c6f77f2b008906cfc3600d0 --mode full --title "fix(translator): reject unresolved image file IDs" --repo <workspace> --out <0700 private root> --path-prepend /home/ubuntu/.nvm/versions/node/v20.20.2/bin
  • Result: PASSED (43/43 steps)
  • Head SHA gated: 7a8fe94e80eb60e11c6f77f2b008906cfc3600d0
  • Aggregate tests: 13519 passed, 0 failed, 66 pending (batches 3238+3106+3664+3511)
  • Receipt / evidence path: /home/ubuntu/.cache/durindoor-local-ci/pr1256-7a8fe94e80eb-20261028T202727Z/evidence.json
  • Runner SHA-256: a5f20fb4e0569ea68030df64c1a48bf42556d11cbdafb27d7c709f0b16ae6547
  • This is offline pre-check evidence only; it does not publish V5 Local CI and does not authorize merge by itself.
Preserved prior PR description and historical evidence

The following is historical context; current scope and verification above supersede stale readiness, gate, dependency and environment claims. Earlier counts apply only to their named heads.

Scope

fix(translator): reject unresolved image file IDs (issue #1080). Draft publication of verified local implementation; base 93f6de6.

Closes #1080

Changed files

  • docs/reference/api.mdx
  • open-sse/translator/request/openai-responses.js
  • tests/translator/bugs-codexCli-responses.test.js

Local evidence

  • Checkpoint: 067a951 committed;23 focused/full12322passed, lint+review+smoke; not merged
  • tests/.test-results.json: 12322 passed / 0 failed / 66 pending of 12388; success=True
  • Docs: docs/reference/api.mdx
  • No baseline additions.

Status

Draft. Not integrated; CI pending. Not merged or released. Publication gates (commitlint) not yet run by this publisher.

Review readiness update — 2026-10-09

Ready for review of the stated, finished PR scope; not ready to merge. This update supersedes earlier draft/parent-only publication wording without removing the original body or user notes.

  • Audited head: 067a951a689c5bc8c892040797dcc69ee4fce6f4; current main at audit: e51ab1c089800c2a70587822189997c482f53654.
  • Required V5 Local CI: missing. No success status is published by this update.
  • Merge requires actual full-CI success for the final exact head, strict up-to-date main, required reviews and resolved review threads. Any rebase or new head invalidates previous head-bound evidence.
  • Missing administrator/confinement proof blocks the serial full-CI/merge path, not review readiness. No gate is waived; no build or test was run for this update.

Retained implementation evidence supports review of the stated PR scope. Historical test counts and older successful checks do not establish integration with current main or a current full-CI pass. Prior local publication notes are historical; no gates were rerun by this delivery worker.

Open in Web Open in Cursor 

Preserve native file references and reject unsupported cross-format use.
Refs #1080
@vercel

vercel Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
durindoor Ready Ready Preview Oct 28, 2026 8:28pm UTC

Request Review

bloodf commented Oct 19, 2026

Copy link
Copy Markdown
Owner Author

V5 delivery tracking update

Keep this PR active. Current head 33aa7f6 contains newer shared-converter and public POST file-ID fixes that are absent/different in #1297. Reconcile those residual changes into the canonical integration route before considering this source absorbed. Issue #1080 remains open until its full acceptance is verified.

Evidence: current head 33aa7f6c36e971f6b9e2c40c8afdc90694ad3710 rechecked on 2026-10-19; current main e94884312ff6651f80d13f1c862e54a916bc870e. This update changes organization only.

@bloodf bloodf added area:protocol Protocol correctness and client compatibility priority:P1 First: correctness, safety or accounting risk type:bug Verified existing behavior defect labels Oct 19, 2026 — with ChatGPT Codex Connector
cursoragent and others added 2 commits October 28, 2026 20:17
Preserve main's Cursor image pre-conversion validation and this PR's
converter HTTP 400 contract for unresolved input_image.file_id values.

Co-authored-by: Heitor Ramon Ribeiro <heitor.ramon@gmail.com>
chatCore now imports enforceCursorCapabilities; spreading the real
capabilities module preserves that export without changing file-ID coverage.

Co-authored-by: Heitor Ramon Ribeiro <heitor.ramon@gmail.com>
@bloodf

bloodf commented Oct 28, 2026

Copy link
Copy Markdown
Owner Author

Superseded by #1297 (squash-merged to main as 8aef5ec). Closing as part of v5 backlog cleanup.

@bloodf bloodf closed this Oct 28, 2026

This branch was successfully deployed

1 active deployment
Preview — 7a8fe94e Deployed Oct 28, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:protocol Protocol correctness and client compatibility priority:P1 First: correctness, safety or accounting risk type:bug Verified existing behavior defect

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(translator): Handle Responses file_id image references without treating IDs as URLs

2 participants