diff --git a/qutebrowser/commands/command.py b/qutebrowser/commands/command.py index 6dee7db91..8dd830495 100644 --- a/qutebrowser/commands/command.py +++ b/qutebrowser/commands/command.py @@ -395,10 +395,11 @@ class Command: raise TypeError("{}: Legacy tuple type annotation!".format( self.name)) elif getattr(typ, '__origin__', None) is typing.Union or ( + # Older Python 3.5 patch versions + # pylint: disable=no-member,useless-suppression hasattr(typing, 'UnionMeta') and isinstance(typ, typing.UnionMeta)): # this is... slightly evil, I know - # pylint: disable=no-member,useless-suppression try: types = list(typ.__args__) except AttributeError: