Skip to content

Allow group workspaces to upload Agent-supported formats#768

Merged
1 commit merged into
dataelement:mainfrom
Y1fe1Zh0u:fix/group-workspace-binary-files
Jul 23, 2026
Merged

Allow group workspaces to upload Agent-supported formats#768
1 commit merged into
dataelement:mainfrom
Y1fe1Zh0u:fix/group-workspace-binary-files

Conversation

@Y1fe1Zh0u

Copy link
Copy Markdown
Collaborator

Summary

  • align group workspace upload formats with the Agent workspace format list
  • add authenticated binary upload and download endpoints for group workspaces
  • preserve UTF-8 text editing, optimistic version checks, revision hashes, and audit records
  • enable safe inline image previews while keeping other binary files download-only
  • source Agent and group upload filters from one shared format definition

Root cause

The group workspace frontend only accepted a small UTF-8 text allowlist, and its backend write contract accepted JSON strings rather than raw file bytes. The underlying storage layer and Agent workspace already supported binary content, but the group boundary did not expose equivalent upload or download paths.

User impact

Group members can now upload the same common documents and images offered by the Agent workspace: PDF, DOCX, XLSX, PPTX, PNG, JPEG, GIF, SVG, and WebP, alongside the existing text and code formats. Images can be previewed; office documents and other binary files can be downloaded without text transcoding.

No database migration or new dependency is required.

Validation

  • backend full suite: 1989 passed
  • focused group workspace/API tests: 21 passed
  • frontend suite: 65 passed
  • frontend production build: npm run build
  • scoped Ruff checks: passed
  • git diff --check: passed

Not tested

  • live S3 or Cloudflare upload path
  • browser-driven end-to-end upload and preview flow

Group workspace uploads were limited to UTF-8 JSON writes even though the shared storage and file browser already support binary content. Add authenticated byte upload/download paths while preserving text editing, optimistic version checks, audit records, and safe image previews.

Constraint: Preserve existing group text editing and version-token semantics

Rejected: Send binary files through the text JSON endpoint | invalid UTF-8 would be rejected or corrupted

Confidence: high

Scope-risk: moderate

Reversibility: clean

Directive: Keep Agent and group upload formats sourced from workspaceFileFormats.ts

Tested: Backend pytest 1989 passed; frontend 65 tests passed; frontend production build; scoped Ruff

Not-tested: Live S3 or Cloudflare upload and browser E2E
Y1fe1Zh0u added a commit that referenced this pull request Jul 22, 2026
The integration branch needs this pull request alongside the other v1.11.2 candidates without changing the original PR state.

Constraint: Preserve the source PR commit and merge in numeric order.
Confidence: high
Scope-risk: moderate
Related: #768
Tested: Git merge completed without unresolved conflicts
Not-tested: Combined backend and frontend suites pending
@Y1fe1Zh0u Y1fe1Zh0u closed this pull request by merging all changes into dataelement:main in 40c1f6b Jul 23, 2026
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