mirror of
https://github.com/encounter/adk-python.git
synced 2026-07-09 18:19:28 -07:00
Merge pull request #1669 from zshehov:use-starred-tuple-unpacking-on-gcs-artifact-blob-names-versions
PiperOrigin-RevId: 783413576
This commit is contained in:
@@ -213,6 +213,6 @@ class GcsArtifactService(BaseArtifactService):
|
|||||||
blobs = self.storage_client.list_blobs(self.bucket, prefix=prefix)
|
blobs = self.storage_client.list_blobs(self.bucket, prefix=prefix)
|
||||||
versions = []
|
versions = []
|
||||||
for blob in blobs:
|
for blob in blobs:
|
||||||
_, _, _, _, version = blob.name.split("/")
|
*_, version = blob.name.split("/")
|
||||||
versions.append(int(version))
|
versions.append(int(version))
|
||||||
return versions
|
return versions
|
||||||
|
|||||||
@@ -253,7 +253,7 @@ async def test_list_versions(service_type):
|
|||||||
app_name = "app0"
|
app_name = "app0"
|
||||||
user_id = "user0"
|
user_id = "user0"
|
||||||
session_id = "123"
|
session_id = "123"
|
||||||
filename = "filename"
|
filename = "with/slash/filename"
|
||||||
versions = [
|
versions = [
|
||||||
types.Part.from_bytes(
|
types.Part.from_bytes(
|
||||||
data=i.to_bytes(2, byteorder="big"), mime_type="text/plain"
|
data=i.to_bytes(2, byteorder="big"), mime_type="text/plain"
|
||||||
|
|||||||
Reference in New Issue
Block a user