Skip to content

Commit 5d3289c

Browse files
hugovkplamut
authored andcommitted
fix: replace unsafe six.PY3 with PY2 for better future compatibility with Python 4 (#10081)
* fix: fix for Python 4: replace unsafe six.PY3 with PY2 * Fix wording
1 parent 225bcc5 commit 5d3289c

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/google-cloud-pubsub/synth.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,10 +127,10 @@
127127
"google/cloud/pubsub_v1/gapic/publisher_client.py",
128128
"class PublisherClient",
129129
"""# TODO: remove conditional import after Python 2 support is dropped
130-
if six.PY3:
131-
from collections.abc import Mapping
132-
else:
130+
if six.PY2:
133131
from collections import Mapping
132+
else:
133+
from collections.abc import Mapping
134134
135135
136136
def _merge_dict(d1, d2):

0 commit comments

Comments
 (0)