diff --git a/python-pyu2f-no-six.patch b/python-pyu2f-no-six.patch new file mode 100644 index 0000000..f9bf4ec --- /dev/null +++ b/python-pyu2f-no-six.patch @@ -0,0 +1,71 @@ +Index: pyu2f-0.1.5a/pyu2f/convenience/localauthenticator.py +=================================================================== +--- pyu2f-0.1.5a.orig/pyu2f/convenience/localauthenticator.py ++++ pyu2f-0.1.5a/pyu2f/convenience/localauthenticator.py +@@ -13,7 +13,6 @@ + # limitations under the License. + + """Convenience class for U2F signing with local security keys.""" +-import six + import base64 + import sys + +@@ -36,7 +35,7 @@ class LocalAuthenticator(baseauthenticat + device = u2f.GetLocalU2FInterface(origin=self.origin) + except errors.NoDeviceFoundError: + print_callback('Please insert your security key and press enter...') +- six.moves.input() ++ input() + device = u2f.GetLocalU2FInterface(origin=self.origin) + + print_callback('Please touch your security key.\n') +Index: pyu2f-0.1.5a/pyu2f/hid/macos.py +=================================================================== +--- pyu2f-0.1.5a.orig/pyu2f/hid/macos.py ++++ pyu2f-0.1.5a/pyu2f/hid/macos.py +@@ -13,8 +13,7 @@ + # limitations under the License. + + """Implements HID device interface on MacOS using IOKit and HIDManager.""" +-from six.moves import queue +-from six.moves import range ++import queue + import ctypes + import ctypes.util + import logging +Index: pyu2f-0.1.5a/pyu2f/tests/apdu_test.py +=================================================================== +--- pyu2f-0.1.5a.orig/pyu2f/tests/apdu_test.py ++++ pyu2f-0.1.5a/pyu2f/tests/apdu_test.py +@@ -14,7 +14,6 @@ + + """Tests for pyu2f.apdu.""" + +-from six.moves import range + import sys + + from pyu2f import apdu +Index: pyu2f-0.1.5a/pyu2f/tests/hidtransport_test.py +=================================================================== +--- pyu2f-0.1.5a.orig/pyu2f/tests/hidtransport_test.py ++++ pyu2f-0.1.5a/pyu2f/tests/hidtransport_test.py +@@ -14,7 +14,6 @@ + + """Tests for pyu2f.hidtransport.""" + +-from six.moves import range + import sys + + import mock +Index: pyu2f-0.1.5a/pyu2f/tests/util_test.py +=================================================================== +--- pyu2f-0.1.5a.orig/pyu2f/tests/util_test.py ++++ pyu2f-0.1.5a/pyu2f/tests/util_test.py +@@ -14,7 +14,6 @@ + + """Tests for pyu2f.tests.lib.util.""" + +-from six.moves import range + import sys + + from pyu2f.tests.lib import util diff --git a/python-pyu2f.changes b/python-pyu2f.changes index 45b40d5..e993724 100644 --- a/python-pyu2f.changes +++ b/python-pyu2f.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Mon Dec 12 14:56:04 UTC 2022 - pgajdos@suse.com + +- do not require six +- added patches + fix https://github.com/google/pyu2f/issues/34 + + python-pyu2f-no-six.patch + ------------------------------------------------------------------- Tue Nov 1 09:26:18 UTC 2022 - Markéta Machová diff --git a/python-pyu2f.spec b/python-pyu2f.spec index 4ba9dff..f9244ae 100644 --- a/python-pyu2f.spec +++ b/python-pyu2f.spec @@ -26,6 +26,8 @@ URL: https://github.com/google/pyu2f/ Source: https://github.com/google/pyu2f/archive/refs/tags/%{version}.tar.gz#/pyu2f-%{version}.tar.gz # PATCH-FIX-UPSTREAM https://github.com/google/pyu2f/pull/32 fix DeprecationWarning for logging and fake_filesystem Patch: fix-deprecation-warning.patch +# https://github.com/google/pyu2f/issues/34 +Patch1: python-pyu2f-no-six.patch BuildRequires: %{python_module setuptools} BuildRequires: python-rpm-macros # SECTION test requirements