We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c7f0b97 commit a1f920aCopy full SHA for a1f920a
1 file changed
sdks/python/apache_beam/typehints/typehints.py
@@ -1037,8 +1037,11 @@ def __repr__(self):
1037
1038
@staticmethod
1039
def _is_subclass_constraint(sub):
1040
- return isinstance(sub, CollectionTypeConstraint) or isinstance(
1041
- sub, SetTypeConstraint) or isinstance(sub, FrozenSetTypeConstraint)
+ return isinstance(
+ sub, (
1042
+ CollectionTypeConstraint,
1043
+ FrozenSetTypeConstraint,
1044
+ SetTypeConstraint))
1045
1046
def _consistent_with_check_(self, sub):
1047
if self._is_subclass_constraint(sub):
0 commit comments