Explorar o código

remove return type hint from __exit__ to restore python<3.8 support

Fabian Peter Hammerle %!s(int64=4) %!d(string=hai) anos
pai
achega
6fdf41560b
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      cc1101/__init__.py

+ 1 - 1
cc1101/__init__.py

@@ -319,7 +319,7 @@ class CC1101:
             raise ValueError("expected marcstate idle (actual: {})".format(marcstate))
         return self
 
-    def __exit__(self, exc_type, exc_value, traceback) -> typing.Literal[False]:
+    def __exit__(self, exc_type, exc_value, traceback):  # -> typing.Literal[False]
         # https://docs.python.org/3/reference/datamodel.html#object.__exit__
         self._spi.close()
         return False