Skip to content

[codex] fix unsupported attachment error mapping#101

Draft
cotovanu-cristian wants to merge 1 commit into
mainfrom
codex/unsupported-attachment-error
Draft

[codex] fix unsupported attachment error mapping#101
cotovanu-cristian wants to merge 1 commit into
mainfrom
codex/unsupported-attachment-error

Conversation

@cotovanu-cristian

Copy link
Copy Markdown
Collaborator

Summary

  • Add a typed UiPathUnsupportedAttachmentError with stable UNSUPPORTED_ATTACHMENT_FORMAT error_code.
  • Map Bedrock Converse unsupported MIME ValueError chains into that typed UiPath error.
  • Preserve MIME type and provider detail for downstream agent-specific mapping.
  • Bump uipath-llm-client to 1.15.1 because 1.15.0 already exists without this API.

Root cause

Bedrock Converse request conversion can reject file blocks locally with a bare ValueError containing Unsupported MIME type before an HTTP response exists. The generic provider wrapper previously mapped that to the root UiPathError, losing the user-actionable attachment semantics.

Validation

  • uv run pytest tests/langchain/features/test_exception_wrapping.py -q
  • uv run ruff check src/uipath/llm_client/init.py src/uipath/llm_client/utils/exceptions.py tests/langchain/features/test_exception_wrapping.py
  • uv run ruff format --check src/uipath/llm_client/init.py src/uipath/llm_client/utils/exceptions.py tests/langchain/features/test_exception_wrapping.py
  • git diff --check

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