Skip to content

fix(artifacts): Preserve inline_data display_name on artifact load#5854

Open
kkj333 wants to merge 1 commit into
google:mainfrom
kkj333:fix/artifact-display-name-5833
Open

fix(artifacts): Preserve inline_data display_name on artifact load#5854
kkj333 wants to merge 1 commit into
google:mainfrom
kkj333:fix/artifact-display-name-5833

Conversation

@kkj333
Copy link
Copy Markdown

@kkj333 kkj333 commented May 26, 2026

Summary

  • Persist inline_data.display_name when saving binary artifacts to FileArtifactService (metadata.json) and GcsArtifactService (blob metadata)
  • Restore display_name when loading binary artifacts so user-facing filenames round-trip through durable storage
  • Add regression test covering InMemory, File, and GCS backends (including display names that differ from the storage key)

Fixes #5833

Test plan

  • uv run pytest tests/unittests/artifacts/test_artifact_service.py -q (62 passed)
  • Manual repro: FileArtifactService now returns display_name='My Report (final).png' after save/load (was None)

File and GCS artifact services dropped inline_data.display_name after
save/load, so clients saw generic attachment names instead of user-facing
filenames. Persist display_name in file metadata and GCS blob metadata,
then restore it when rebuilding binary Parts.

Fixes google#5833
@rohityan rohityan self-assigned this May 26, 2026
@rohityan rohityan added the services [Component] This issue is related to runtime services, e.g. sessions, memory, artifacts, etc label May 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

services [Component] This issue is related to runtime services, e.g. sessions, memory, artifacts, etc

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Blob.display_name not preserved when loading binary artifacts from FileArtifactService / GcsArtifactService

2 participants