Skip to content

Commit

Permalink
fix: remove trailing commas from error message constants (googleapis#505
Browse files Browse the repository at this point in the history
)

The _DOWNLOAD_AS_STRING_DEPRECATED constant includes a dangling comma
which makes it a tuple and not a string. This causes a TypeError as reported in googleapis#501.

Fixes googleapis#501
  • Loading branch information
rjw57 authored and cojenco committed Oct 13, 2021
1 parent 8c1f1b3 commit cb6d7f9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions google/cloud/storage/blob.py
Expand Up @@ -119,7 +119,7 @@
_COMPOSE_IF_GENERATION_LIST_DEPRECATED = (
"'if_generation_match: type list' is deprecated and supported for "
"backwards-compatability reasons only. Use 'if_source_generation_match' "
"instead' to match source objects' generations.",
"instead' to match source objects' generations."
)
_COMPOSE_IF_GENERATION_LIST_AND_IF_SOURCE_GENERATION_ERROR = (
"Use 'if_generation_match' to match the generation of the destination "
Expand All @@ -130,14 +130,14 @@
"'if_metageneration_match: type list' is deprecated and supported for "
"backwards-compatability reasons only. Note that the metageneration to "
"be matched is that of the destination blob. Please pass in a single "
"value (type long).",
"value (type long)."
)
_COMPOSE_IF_SOURCE_GENERATION_MISMATCH_ERROR = (
"'if_source_generation_match' length must be the same as 'sources' length"
)
_DOWNLOAD_AS_STRING_DEPRECATED = (
"Blob.download_as_string() is deprecated and will be removed in future. "
"Use Blob.download_as_bytes() instead.",
"Use Blob.download_as_bytes() instead."
)


Expand Down

0 comments on commit cb6d7f9

Please sign in to comment.