Skip to content

[codex] support text direct downloads#490

Draft
monlor wants to merge 1 commit into
vastsa:masterfrom
monlor:codex/support-text-direct-download
Draft

[codex] support text direct downloads#490
monlor wants to merge 1 commit into
vastsa:masterfrom
monlor:codex/support-text-direct-download

Conversation

@monlor

@monlor monlor commented Jul 15, 2026

Copy link
Copy Markdown

Summary

  • return text shares as UTF-8 plain-text attachments from GET /share/select/
  • use the share name with a .txt fallback for the downloaded filename
  • preserve the existing expiration, download-count, and usage-accounting behavior
  • cover direct text downloads with a regression test

Why

The direct-download endpoint always delegated to the configured file storage. Text shares do not have a physical file, so valid text shares were incorrectly reported as deleted or expired when accessed through a direct link.

Impact

Direct links now work for both uploaded files and text shares. Existing file-download behavior is unchanged.

Validation

  • .venv/bin/python -m unittest tests.test_issue_482_share_usage -v
  • .venv/bin/python -m compileall -q apps/base/views.py tests/test_issue_482_share_usage.py
  • git diff --check
  • full test run: 31 tests passed; 2 unrelated theme-asset tests fail because themes/2023 assets are absent from this checkout

@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

@monlor is attempting to deploy a commit to the vastsa's projects Team on Vercel.

A member of the Team first needs to authorize it.

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