Skip to content

fix(files): support arbitrary uploads and in-document links - #8807

Merged
waleedlatif1 merged 3 commits into
stagingfrom
codex/files-storage-and-markdown-links
Oct 8, 2026
Merged

waleedlatif1 merged 3 commits into
stagingfrom
codex/files-storage-and-markdown-links

Conversation

@waleedlatif1

@waleedlatif1 waleedlatif1 commented Oct 8, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Accept arbitrary file types in Files, queue upload batches, and show actionable errors for failed uploads and unsupported folder drops.
  • Preview common configuration templates and declared text formats, with bounded text loading and a download fallback for large files.
  • Keep Markdown heading links inside the document, including Unicode and duplicate headings, across editable and public views.

Type of Change

  • Bug fix

Testing

  • 1,494 focused file, upload, and query tests passed locally, followed by targeted text-reader regression and sibling tests; the full suite runs in CI.
  • 51 browser checks against the running app and local database: uploads and byte-exact downloads, queued failures, edit/save/reopen, media previews, size limits, private/public Markdown navigation, parameterized MIME types, image-extension precedence, and retry behavior. Two additional Chromium checks exercise real gzip HTTP responses at and above the decoded-byte limit. JSON reports, screenshots, and traces saved locally.
  • Regression negative controls cover heading slugs, response-size guards, transient retry recovery, and current-edit downloads.
  • Cleanup review, lint, all 58 audits, all workspace type checks, block registry, docs manifest, and pinned actionlint.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@waleedlatif1
waleedlatif1 requested a review from a team as a code owner October 8, 2026 18:50
@vercel

vercel Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

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

1 Skipped Deployment
Project Deployment Actions Updated
docs Skipped Skipped Oct 8, 2026 8:01pm UTC

Request Review

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 17 files

Reply with feedback, questions, or to request a fix.

Turn on auto-fix | Re-trigger cubic

Comment thread apps/sim/hooks/queries/workspace-files.ts
@greptile-apps

greptile-apps Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[Medium impact] The changes since the previous review appear safe to merge.

Summary

This PR allows arbitrary uploads, queues upload batches, improves upload errors, bounds text previews, and keeps Markdown heading links inside the document.

  • Since the previous review, readFileText no longer treats an encoded response’s Content-Length as its decoded size.
  • The body-reading loop still enforces the text-size limit.
  • No new actionable issues or confirmed repository-rule violations were found.
  • No previous findings were supplied. Previous GitHub threads could not be retrieved because authentication was unavailable.
  • This review inspected code; it did not run tests or browser checks.

Reviews (3) · Last reviewed commit: "fix(files): bound decoded text for encod..." · Reviewed by Greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

1 issue found across 23 files

Confidence score: 4/5

  • text-content.ts can reject encoded responses that exceed the wire-size limit even when their decoded text is within the limit. Skip the header check for encoded responses.
Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="apps/sim/lib/uploads/client/text-content.ts">

<violation number="1" location="apps/sim/lib/uploads/client/text-content.ts:18">
P2: This precheck can reject a content-encoded response whose wire size exceeds the limit while its decoded text remains within it, such as high-entropy text near the cap. Skip the header check for encoded responses and rely on the streamed byte count.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Turn on auto-fix | Re-trigger cubic

Comment thread apps/sim/lib/uploads/client/text-content.ts Outdated
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 23 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Turn on auto-fix | Re-trigger cubic

@waleedlatif1
waleedlatif1 merged commit 96273a5 into staging Oct 8, 2026
40 of 41 checks passed
@waleedlatif1
waleedlatif1 deleted the codex/files-storage-and-markdown-links branch October 8, 2026 20:07

This branch was previously deployed

1 inactive deployment
Preview — 442a5e07 Deployed Oct 8, 2026 by vercel[bot]
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