help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Python Package Build Issue


From: Antwane Mason
Subject: Python Package Build Issue
Date: Tue, 24 Aug 2021 08:29:20 -0400

I am trying to package a fido2 python library with the ultimate goal of
packaging the cli for a hardware password manager, 2FA authenticator, and
private key store called onlykey.

While building the package definition obtained from guix importer, I get
the following stacktrace. From googling it seems as though this is due to
trying to use windows types on a linux machine but I'm not sure how to fix
or correct this as I'm not sure why this test wasn't filtered out. Any
guidance would be appreciated.

-------------------------------------------------------------------------
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "setup.py", line 46, in <module>
    setup(
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/site-packages/setuptools/__init__.py",
line 145, in setup
    return distutils.core.setup(**attrs)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/distutils/core.py",
line 148, in setup
    dist.run_commands()
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/distutils/dist.py",
line 966, in run_commands
    self.run_command(cmd)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/distutils/dist.py",
line 985, in run_command
    cmd_obj.run()
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/site-packages/setuptools/command/test.py",
line 229, in run
    self.run_tests()
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/site-packages/setuptools/command/test.py",
line 247, in run_tests
    test = unittest.main(
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/main.py",
line 100, in __init__
    self.parseArgs(argv)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/main.py",
line 124, in parseArgs
    self._do_discovery(argv[2:])
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/main.py",
line 244, in _do_discovery
    self.createTests(from_discovery=True, Loader=Loader)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/main.py",
line 154, in createTests
    self.test = loader.discover(self.start, self.pattern, self.top)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/loader.py",
line 349, in discover
    tests = list(self._find_tests(start_dir, pattern))
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/loader.py",
line 405, in _find_tests
    tests, should_recurse = self._find_test_path(
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/loader.py",
line 483, in _find_test_path
    tests = self.loadTestsFromModule(package, pattern=pattern)
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/site-packages/setuptools/command/test.py",
line 55, in loadTestsFromModule
    tests.append(self.loadTestsFromName(submodule))
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/unittest/loader.py",
line 154, in loadTestsFromName
    module = __import__(module_name)
  File
"/tmp/guix-build-python-fido2-0.9.1.drv-0/fido2-0.9.1/fido2/win_api.py",
line 43, in <module>
    from ctypes.wintypes import BOOL, DWORD, LONG, LPCWSTR, HWND
  File
"/gnu/store/9w9jvy3bgjg4qaqmrij01nbppiccqr7c-python-3.8.2/lib/python3.8/ctypes/wintypes.py",
line 20, in <module>
    class VARIANT_BOOL(ctypes._SimpleCData):
ValueError: _type_ 'v' not supported
-------------------------------------------------------------------------

Here is the package definition in case it is useful.

-------------------------------------------------------------------------
(define-public python-fido2
  (package
  (name "python-fido2")
  (version "0.9.1")
  (source
    (origin
      (method url-fetch)
      (uri (pypi-uri "fido2" version))
      (sha256
        (base32
          "0vpyknka7wa4jl1xhvhli48wk70dih7hm45kdrchf8wf4cjyx046"))))
  (build-system python-build-system)
  (propagated-inputs
    `(("python-cryptography" ,python-cryptography)
      ("python-six" ,python-six)))
  (home-page
    "https://github.com/Yubico/python-fido2";)
  (synopsis "Python based FIDO 2.0 library")
  (description "Python based FIDO 2.0 library")
; temporarily false. it's mixed license with bsd, apache, and mit
  (license #f)))
-------------------------------------------------------------------------

Regards,
Antwane


reply via email to

[Prev in Thread] Current Thread [Next in Thread]