This repository has been archived by the owner on Jun 28, 2022. It is now read-only.
Order of keyword args between versions can cause breakage. #526
Labels
lang: python
Issues specific to Python.
In Python, keyword args can also be passed as positional args. So in
gapic-google-logging-v2
(0.9.3),LoggingServiceV2Api.list_log_entries
had the signature:but in
gapic-google-logging-v2
(0.10.1), it became:i.e. it grew
resource_names
in the middle. Hence when we called via positional onlythat code broke on the upgrade from 0.9.x to 0.10.x.
This is somewhat fine, but if you wanted, you could force users to always use some arguments as keywords by using
*args, **kwargs
and then unpackingargs
according to a specified length needed for positional and then removing fromkwargs
to sanitize.The text was updated successfully, but these errors were encountered: