Skip to content

feat(gateway): accept rar and 7z document uploads - #28792

Closed
Qwinty wants to merge 1 commit into
NousResearch:mainfrom
Qwinty:feat/telegram-rar-archive-uploads
Closed

feat(gateway): accept rar and 7z document uploads#28792
Qwinty wants to merge 1 commit into
NousResearch:mainfrom
Qwinty:feat/telegram-rar-archive-uploads

Conversation

@Qwinty

@Qwinty Qwinty commented May 19, 2026

Copy link
Copy Markdown
Contributor

Summary

  • accept .rar and .7z as supported gateway document attachments
  • keep archive uploads cached as documents so the agent can inspect them with existing terminal/file workflows
  • add Telegram and shared document-cache regressions for the new archive types

Closes #28791.

Notes

This intentionally does not add archive extraction behavior or bundle extractor binaries. It only lets the gateway cache the uploaded archive and pass the local path to the agent, matching existing .zip behavior from #4846.

Test Plan

  • RED: /usr/local/lib/hermes-agent/venv/bin/python -m pytest tests/gateway/test_document_cache.py::TestSupportedDocumentTypes::test_expected_extensions_present tests/gateway/test_telegram_documents.py::TestDocumentDownloadBlock::test_archive_document_cached -q failed for missing .rar/.7z
  • GREEN: /usr/local/lib/hermes-agent/venv/bin/python -m pytest tests/gateway/test_document_cache.py::TestSupportedDocumentTypes::test_expected_extensions_present tests/gateway/test_telegram_documents.py::TestDocumentDownloadBlock::test_archive_document_cached -q
  • /usr/local/lib/hermes-agent/venv/bin/python -m pytest tests/gateway/test_document_cache.py tests/gateway/test_telegram_documents.py -q
  • git diff --check

@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have comp/gateway Gateway runner, session dispatch, delivery platform/telegram Telegram bot adapter labels May 19, 2026
@Qwinty

Qwinty commented May 19, 2026

Copy link
Copy Markdown
Contributor Author

CI note: all non-test checks are green on this PR. The test job hit the workflow-level 20-minute timeout and was cancelled, not a specific assertion failure.

This looks like existing CI behavior on current main rather than a regression from this small allowlist change: recent main Tests workflow runs are also cancelled after ~20 minutes (for example runs 26106201446 and 26099815519).

Local focused verification for this PR passed:

/usr/local/lib/hermes-agent/venv/bin/python -m pytest \
  tests/gateway/test_document_cache.py::TestSupportedDocumentTypes::test_expected_extensions_present \
  tests/gateway/test_telegram_documents.py::TestDocumentDownloadBlock::test_archive_document_cached \
  -q
# 11 passed

/usr/local/lib/hermes-agent/venv/bin/python -m pytest \
  tests/gateway/test_document_cache.py \
  tests/gateway/test_telegram_documents.py \
  -q
# 67 passed

@Qwinty
Qwinty force-pushed the feat/telegram-rar-archive-uploads branch from e84f778 to 307ac5a Compare May 21, 2026 21:50
@Qwinty
Qwinty force-pushed the feat/telegram-rar-archive-uploads branch from 307ac5a to be6e259 Compare May 26, 2026 08:47
@Qwinty

Qwinty commented May 26, 2026

Copy link
Copy Markdown
Contributor Author

Rebased on current upstream/main; PR is mergeable again.

Local verification:

  • python -m pytest -q -o addopts='' tests/gateway/test_document_cache.py tests/gateway/test_telegram_documents.py - 67 passed
  • python -m ruff check gateway/platforms/base.py tests/gateway/test_document_cache.py tests/gateway/test_telegram_documents.py - passed
  • git diff --check upstream/main...HEAD - passed

CI has been retriggered on be6e259df.

@Qwinty

Qwinty commented Jun 9, 2026

Copy link
Copy Markdown
Contributor Author

Closing this optional/non-critical upstream feature PR to keep the open queue focused on production bugfixes. The branch can be reopened or recreated later if we decide to pursue this feature upstream.

@Qwinty Qwinty closed this Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery P3 Low — cosmetic, nice to have platform/telegram Telegram bot adapter type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Telegram: accept .rar and .7z archive uploads as document attachments

2 participants