mqtt-io
mqtt-io copied to clipboard
pip fails on pyyaml, poetry fails on requests.utils on a raspberry pi zero w
- [x] I have read the README.md file and visited the Documentation to see if the information there helps.
Describe the bug Installation on raspberry pi zero w fails with pip and poetry.
Expected behavior pip should install mqtt-io.
Error messages and traceback
~/mqtt-io $ pip install mqtt-io
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting mqtt-io
Downloading https://www.piwheels.org/simple/mqtt-io/mqtt_io-2.2.9-py3-none-any.whl (81 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 81.5/81.5 kB 409.6 kB/s eta 0:00:00
Collecting Cerberus<2.0.0,>=1.3.2
Downloading https://www.piwheels.org/simple/cerberus/Cerberus-1.3.5-py3-none-any.whl (30 kB)
Collecting PyYAML<6.0,>=5.4
Downloading PyYAML-5.4.1.tar.gz (175 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 175.1/175.1 kB 358.8 kB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [68 lines of output]
/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/config/setupcfg.py:293: _DeprecatedConfig: Deprecated config in `setup.cfg`
!!
********************************************************************************
The license_file parameter is deprecated, use license_files instead.
By 2023-Oct-30, you need to update your project and remove deprecated calls
or your builds will no longer be supported.
See https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for details.
********************************************************************************
!!
parsed = self.parsers.get(option_name, lambda x: x)(value)
running egg_info
writing lib3/PyYAML.egg-info/PKG-INFO
writing dependency_links to lib3/PyYAML.egg-info/dependency_links.txt
writing top-level names to lib3/PyYAML.egg-info/top_level.txt
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
return hook(config_settings)
^^^^^^^^^^^^^^^^^^^^^
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 355, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=['wheel'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 325, in _get_build_requires
self.run_setup()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 341, in run_setup
exec(code, locals())
File "<string>", line 271, in <module>
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/__init__.py", line 103, in setup
return distutils.core.setup(**attrs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 185, in setup
return run_commands(dist)
^^^^^^^^^^^^^^^^^^
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
dist.run_commands()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
self.run_command(cmd)
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 989, in run_command
super().run_command(command)
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
cmd_obj.run()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/command/egg_info.py", line 318, in run
self.find_sources()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/command/egg_info.py", line 326, in find_sources
mm.run()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/command/egg_info.py", line 548, in run
self.add_defaults()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/command/egg_info.py", line 586, in add_defaults
sdist.add_defaults(self)
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/command/sdist.py", line 113, in add_defaults
super().add_defaults()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/sdist.py", line 251, in add_defaults
self._add_defaults_ext()
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/sdist.py", line 336, in _add_defaults_ext
self.filelist.extend(build_ext.get_source_files())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<string>", line 201, in get_source_files
File "/tmp/pip-build-env-ecwtibsm/overlay/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 107, in __getattr__
raise AttributeError(attr)
AttributeError: cython_sources
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
Then found similar: https://github.com/flyte/mqtt-io/issues/324 and related comments here: https://stackoverflow.com/questions/76708329/docker-compose-no-longer-building-image-attributeerror-cython-sources
definition of pyyaml seams ok: https://github.com/flyte/mqtt-io/blob/2bb2f945ea47ed87f99ab4fc966d2dbbd47fc7c7/pyproject.toml#L12
So I downloaded the source and installed with poetry:
Resolving dependencies... (989.9s)Invalid requirement (PyYAML (>=5.4<5.5)) found in fpyutils-1.2.3 dependencies, skipping
Resolving dependencies... (1017.3s)
Package operations: 58 installs, 9 updates, 0 removals
• Installing chardet (4.0.0)
• Downgrading idna (3.4 -> 2.10)
• Installing markupsafe (2.0.1)
• Installing pyparsing (3.0.7)
• Installing pytz (2023.3.post1)
• Downgrading urllib3 (2.0.7 -> 1.26.18)
• Installing alabaster (0.7.13)
• Installing atomicwrites (1.4.1)
• Installing babel (2.11.0)
• Installing docutils (0.18.1)
• Downgrading filelock (3.12.4 -> 3.4.1)
• Installing imagesize (1.4.1)
• Installing jinja2 (2.11.3)
• Installing lazy-object-proxy (1.7.1): Preparing...
• Downgrading packaging (23.2 -> 21.3)
• Installing parse (1.19.1)
• Downgrading platformdirs (3.11.0 -> 2.4.0)
• Installing pygments (2.14.0)
• Downgrading requests (2.31.0 -> 2.25.1)
• Downgrading setuptools (66.1.1 -> 59.6.0)
• Installing six (1.16.0)
• Installing smmap (5.0.0)
• Installing snowballstemmer (2.2.0)
• Installing sphinxcontrib-applehelp (1.0.2)
• Installing sphinxcontrib-devhelp (1.0.2)
• Installing sphinxcontrib-htmlhelp (2.0.0)
• Installing sphinxcontrib-jsmath (1.0.1)
• Installing sphinxcontrib-qthelp (1.0.3)
• Installing sphinxcontrib-serializinghtml (1.1.5)
• Installing wrapt (1.13.3): Failed
ChefBuildError
Backend subprocess exited when trying to invoke build_wheel
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 81, in __getattr__
return next(
^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 82, in <genexpr>
ast.literal_eval(value)
File "/usr/lib/python3.11/ast.py", line 110, in literal_eval
return _convert(node_or_string)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 109, in _convert
return _convert_signed_num(node)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 83, in _convert_signed_num
return _convert_num(node)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 74, in _convert_num
_raise_malformed_node(node)
File "/usr/lib/python3.11/ast.py", line 71, in _raise_malformed_node
raise ValueError(msg + f': {node!r}')
ValueError: malformed node or string on line 2: <ast.Call object at 0xb6132610>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 193, in read_attr
return getattr(StaticModule(module_name, spec), attr_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 87, in __getattr__
raise AttributeError(f"{self.name} has no attribute {attr}") from e
AttributeError: wrapt has no attribute __version__
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
• Downgrading packaging (23.2 -> 21.3)
• Installing parse (1.19.1)
• Downgrading platformdirs (3.11.0 -> 2.4.0)
• Installing pygments (2.14.0)
• Downgrading requests (2.31.0 -> 2.25.1)
• Downgrading setuptools (66.1.1 -> 59.6.0)
• Installing six (1.16.0)
• Installing smmap (5.0.0)
• Installing snowballstemmer (2.2.0)
• Installing sphinxcontrib-applehelp (1.0.2)
• Installing sphinxcontrib-devhelp (1.0.2)
• Installing sphinxcontrib-htmlhelp (2.0.0)
• Installing sphinxcontrib-jsmath (1.0.1)
• Installing sphinxcontrib-qthelp (1.0.3)
• Installing sphinxcontrib-serializinghtml (1.1.5)
• Installing wrapt (1.13.3): Failed
ChefBuildError
Backend subprocess exited when trying to invoke build_wheel
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 81, in __getattr__
return next(
^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 82, in <genexpr>
ast.literal_eval(value)
File "/usr/lib/python3.11/ast.py", line 110, in literal_eval
return _convert(node_or_string)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 109, in _convert
return _convert_signed_num(node)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 83, in _convert_signed_num
return _convert_num(node)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 74, in _convert_num
_raise_malformed_node(node)
File "/usr/lib/python3.11/ast.py", line 71, in _raise_malformed_node
raise ValueError(msg + f': {node!r}')
ValueError: malformed node or string on line 2: <ast.Call object at 0xb6132610>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 193, in read_attr
return getattr(StaticModule(module_name, spec), attr_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 87, in __getattr__
raise AttributeError(f"{self.name} has no attribute {attr}") from e
AttributeError: wrapt has no attribute __version__
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
• Installing lazy-object-proxy (1.7.1): Installing...
• Downgrading packaging (23.2 -> 21.3)
• Installing parse (1.19.1)
• Downgrading platformdirs (3.11.0 -> 2.4.0)
• Installing pygments (2.14.0)
• Downgrading requests (2.31.0 -> 2.25.1)
• Downgrading setuptools (66.1.1 -> 59.6.0)
• Installing six (1.16.0)
• Installing smmap (5.0.0)
• Installing snowballstemmer (2.2.0)
• Installing sphinxcontrib-applehelp (1.0.2)
• Installing sphinxcontrib-devhelp (1.0.2)
• Installing sphinxcontrib-htmlhelp (2.0.0)
• Installing sphinxcontrib-jsmath (1.0.1)
• Installing sphinxcontrib-qthelp (1.0.3)
• Installing sphinxcontrib-serializinghtml (1.1.5)
• Installing wrapt (1.13.3): Failed
ChefBuildError
Backend subprocess exited when trying to invoke build_wheel
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 81, in __getattr__
return next(
^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 82, in <genexpr>
ast.literal_eval(value)
File "/usr/lib/python3.11/ast.py", line 110, in literal_eval
return _convert(node_or_string)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 109, in _convert
return _convert_signed_num(node)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 83, in _convert_signed_num
return _convert_num(node)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 74, in _convert_num
_raise_malformed_node(node)
File "/usr/lib/python3.11/ast.py", line 71, in _raise_malformed_node
raise ValueError(msg + f': {node!r}')
ValueError: malformed node or string on line 2: <ast.Call object at 0xb6132610>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 193, in read_attr
return getattr(StaticModule(module_name, spec), attr_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 87, in __getattr__
raise AttributeError(f"{self.name} has no attribute {attr}") from e
AttributeError: wrapt has no attribute __version__
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
• Downgrading packaging (23.2 -> 21.3)
• Installing parse (1.19.1)
• Downgrading platformdirs (3.11.0 -> 2.4.0)
• Installing pygments (2.14.0)
• Downgrading requests (2.31.0 -> 2.25.1)
• Downgrading setuptools (66.1.1 -> 59.6.0)
• Installing six (1.16.0)
• Installing smmap (5.0.0)
• Installing snowballstemmer (2.2.0)
• Installing sphinxcontrib-applehelp (1.0.2)
• Installing sphinxcontrib-devhelp (1.0.2)
• Installing sphinxcontrib-htmlhelp (2.0.0)
• Installing sphinxcontrib-jsmath (1.0.1)
• Installing sphinxcontrib-qthelp (1.0.3)
• Installing sphinxcontrib-serializinghtml (1.1.5)
• Installing wrapt (1.13.3): Failed
ChefBuildError
Backend subprocess exited when trying to invoke build_wheel
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 81, in __getattr__
return next(
^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 82, in <genexpr>
ast.literal_eval(value)
File "/usr/lib/python3.11/ast.py", line 110, in literal_eval
return _convert(node_or_string)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 109, in _convert
return _convert_signed_num(node)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 83, in _convert_signed_num
return _convert_num(node)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 74, in _convert_num
_raise_malformed_node(node)
File "/usr/lib/python3.11/ast.py", line 71, in _raise_malformed_node
raise ValueError(msg + f': {node!r}')
ValueError: malformed node or string on line 2: <ast.Call object at 0xb6132610>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 193, in read_attr
return getattr(StaticModule(module_name, spec), attr_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 87, in __getattr__
raise AttributeError(f"{self.name} has no attribute {attr}") from e
AttributeError: wrapt has no attribute __version__
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
• Installing lazy-object-proxy (1.7.1)
• Downgrading packaging (23.2 -> 21.3)
• Installing parse (1.19.1)
• Downgrading platformdirs (3.11.0 -> 2.4.0)
• Installing pygments (2.14.0)
• Downgrading requests (2.31.0 -> 2.25.1)
• Downgrading setuptools (66.1.1 -> 59.6.0)
• Installing six (1.16.0)
• Installing smmap (5.0.0)
• Installing snowballstemmer (2.2.0)
• Installing sphinxcontrib-applehelp (1.0.2)
• Installing sphinxcontrib-devhelp (1.0.2)
• Installing sphinxcontrib-htmlhelp (2.0.0)
• Installing sphinxcontrib-jsmath (1.0.1)
• Installing sphinxcontrib-qthelp (1.0.3)
• Installing sphinxcontrib-serializinghtml (1.1.5)
• Installing wrapt (1.13.3): Failed
ChefBuildError
Backend subprocess exited when trying to invoke build_wheel
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 81, in __getattr__
return next(
^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 82, in <genexpr>
ast.literal_eval(value)
File "/usr/lib/python3.11/ast.py", line 110, in literal_eval
return _convert(node_or_string)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 109, in _convert
return _convert_signed_num(node)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 83, in _convert_signed_num
return _convert_num(node)
^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/ast.py", line 74, in _convert_num
_raise_malformed_node(node)
File "/usr/lib/python3.11/ast.py", line 71, in _raise_malformed_node
raise ValueError(msg + f': {node!r}')
ValueError: malformed node or string on line 2: <ast.Call object at 0xb6132610>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 193, in read_attr
return getattr(StaticModule(module_name, spec), attr_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 87, in __getattr__
raise AttributeError(f"{self.name} has no attribute {attr}") from e
AttributeError: wrapt has no attribute __version__
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
main()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory, config_settings,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 434, in build_wheel
return self._build_with_temp_dir(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 419, in _build_with_temp_dir
self.run_setup()
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 507, in run_setup
super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 341, in run_setup
exec(code, locals())
File "<string>", line 41, in <module>
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/__init__.py", line 103, in setup
return distutils.core.setup(**attrs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 159, in setup
dist.parse_config_files()
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/_virtualenv.py", line 23, in parse_config_files
result = old_parse_config_files(self, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/dist.py", line 649, in parse_config_files
setupcfg.parse_configuration(
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 189, in parse_configuration
meta.parse()
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 500, in parse
section_parser_method(section_options)
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 475, in parse_section
self[name] = value
~~~~^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 293, in __setitem__
parsed = self.parsers.get(option_name, lambda x: x)(value)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 606, in _parse_version
return expand.version(self._parse_attr(value, self.package_dir, self.root_dir))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 417, in _parse_attr
return expand.read_attr(attr_desc, package_dir, root_dir)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 196, in read_attr
module = _load_spec(spec, module_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmppwawes5r/.venv/lib/python3.11/site-packages/setuptools/config/expand.py", line 216, in _load_spec
spec.loader.exec_module(module) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/tmp/tmp0g40xfz6/wrapt-1.13.3/src/wrapt/__init__.py", line 10, in <module>
from .decorators import (adapter_factory, AdapterFactory, decorator,
File "/tmp/tmp0g40xfz6/wrapt-1.13.3/src/wrapt/decorators.py", line 34, in <module>
from inspect import ismethod, isclass, formatargspec
ImportError: cannot import name 'formatargspec' from 'inspect' (/usr/lib/python3.11/inspect.py)
at .venv/lib/python3.11/site-packages/poetry/installation/chef.py:147 in _prepare
143│
144│ error = ChefBuildError("\n\n".join(message_parts))
145│
146│ if error is not None:
→ 147│ raise error from None
148│
149│ return path
150│
151│ def _prepare_sdist(self, archive: Path, destination: Path | None = None) -> Path:
Note: This error originates from the build backend, and is likely not a problem with poetry but with wrapt (1.13.3) not supporting PEP 517 builds. You can verify this by running 'pip wheel --use-pep517 "wrapt (==1.13.3)"'.
where wrapt fails...
Installing as recomended with pip wheel --use-pep517 "wrapt (==1.13.3)"
works fine but reinitializing
~/mqtt-io $ poetry install
Throws this:
~/mqtt-io $ poetry install
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/cleo/application.py", line 327, in run
exit_code = self._run(io)
^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/console/application.py", line 188, in _run
self._load_plugins(io)
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/console/application.py", line 354, in _load_plugins
manager.load_plugins()
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/plugins/plugin_manager.py", line 38, in load_plugins
self._load_plugin_entry_point(ep)
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/plugins/plugin_manager.py", line 76, in _load_plugin_entry_point
plugin = ep.load() # type: ignore[no-untyped-call]
^^^^^^^^^
File "/usr/lib/python3.11/importlib/metadata/__init__.py", line 202, in load
module = import_module(match.group('module'))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 940, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry_plugin_export/plugins.py", line 7, in <module>
from poetry_plugin_export.command import ExportCommand
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry_plugin_export/command.py", line 10, in <module>
from poetry_plugin_export.exporter import Exporter
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry_plugin_export/exporter.py", line 11, in <module>
from poetry.repositories.http_repository import HTTPRepository
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/repositories/http_repository.py", line 27, in <module>
from poetry.utils.helpers import download_file
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/utils/helpers.py", line 17, in <module>
from requests.utils import atomic_open
ImportError: cannot import name 'atomic_open' from 'requests.utils' (/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/requests/utils.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/novski/mqtt-io/.venv/bin/poetry", line 8, in <module>
sys.exit(main())
^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/console/application.py", line 405, in main
exit_code: int = Application().run()
^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/cleo/application.py", line 338, in run
self.render_error(e, io)
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/console/application.py", line 180, in render_error
self.set_solution_provider_repository(self._get_solution_provider_repository())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/console/application.py", line 394, in _get_solution_provider_repository
from poetry.mixology.solutions.providers.python_requirement_solution_provider import ( # noqa: E501
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/mixology/solutions/providers/__init__.py", line 3, in <module>
from poetry.mixology.solutions.providers.python_requirement_solution_provider import (
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/mixology/solutions/providers/python_requirement_solution_provider.py", line 9, in <module>
from poetry.puzzle.exceptions import SolverProblemError
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/puzzle/__init__.py", line 3, in <module>
from poetry.puzzle.solver import Solver
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/puzzle/solver.py", line 16, in <module>
from poetry.puzzle.provider import Indicator
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/puzzle/provider.py", line 27, in <module>
from poetry.packages.direct_origin import DirectOrigin
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/packages/direct_origin.py", line 10, in <module>
from poetry.inspection.info import PackageInfo
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/inspection/info.py", line 26, in <module>
from poetry.utils.env import EnvCommandError
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/utils/env/__init__.py", line 9, in <module>
from poetry.utils.env.base_env import Env
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/utils/env/base_env.py", line 18, in <module>
from poetry.utils.env.site_packages import SitePackages
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/utils/env/site_packages.py", line 11, in <module>
from poetry.utils.helpers import is_dir_writable
File "/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/poetry/utils/helpers.py", line 17, in <module>
from requests.utils import atomic_open
ImportError: cannot import name 'atomic_open' from 'requests.utils' (/home/novski/mqtt-io/.venv/lib/python3.11/site-packages/requests/utils.py)
where a reinstallation of pip install utils
does not help and throws the exact same as above again.
Here i got stuck...
Config
not yet done.
Hardware
- Platform: raspberry pi zero w
- Connected hardware: none System:
- OS: Raspbian lite 32bit
- Python version: 3.11.2
- Pip version: 23.0.1
- User you're running as: my_personal_user
- Using a virtualenv?: yes
Additional context Add any other context about the problem here.
found some more hints:
poetry 1.6 has a bug that didn't got fixed with its pullrequest to 1.6.1: https://github.com/python-poetry/poetry/pull/8336
so to get over the atomic_open import fail which is because requests <2.26 I reinstalled it with:
pip install --force-reinstall -v "requests==2.31"`
and got this funny warning:
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
poetry 1.6.1 requires platformdirs<4.0.0,>=3.0.0, but you have platformdirs 2.4.0 which is incompatible.
then did: pip install --force-reinstall -v "platformdirs==3.11.0"
& pip install --force-reinstall -v "filelock==3.12.4"
as it showed the same error...
I don't know if the pip installation has something to do with the poetry installation, but I leave it up to you to take that in to account...
I'm having the same problem installing on a Raspberry Pi 4 B with the latest Raspberry Pi OS (64 bit). I've only tried installing via pip3 install mqtt-io
I'm having a similar issue RPi 3B+ PRETTY_NAME="Debian GNU/Linux 11 (bullseye)" NAME="Debian GNU/Linux" VERSION_ID="11" VERSION="11 (bullseye)" VERSION_CODENAME=bullseye ID=debian HOME_URL="https://www.debian.org/" SUPPORT_URL="https://www.debian.org/support" BUG_REPORT_URL="https://bugs.debian.org/"
Python 3.11.4 pip 23.3.1
Also ended here with the same Problem
Raspberry Pi 2 Model B Rev 1.1 PRETTY_NAME="Raspbian GNU/Linux 12 (bookworm)" Python 3.11.2 pip 23.3.1
So I believe I found a workaround. Something to do with PyYAML not having a maximum working version of Cython specified, and Cython 3.0 broke something.
Thanks to the "Inline Constraint" on this page.
Follow that link for more details, but here's the short version of what I did:
# create a constraint file that limits the Cython version to one that should work
echo 'Cython < 3.0' > /tmp/constraint.txt
# install PyYAML itself (or other packages that need it); any package requiring Cython will be constrained to `Cython < 3.0`
PIP_CONSTRAINT=/tmp/constraint.txt pip install 'PyYAML==5.4.1'
# install mqtt-io, now that we have a working version of pyyaml
pip install mqtt-io
Many thanks to nitzmahone for the workaround.
I orderd an Pi Zero 2 W to test if it does not fail on more recent architecture (ARMv8) and OS (Raspberrypi OS lite 64bit):
$dmesg
...
[ 0.000000] Linux version 6.1.0-rpi4-rpi-v8 ([email protected]) (gcc-12 (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) #1 SMP PREEMPT Debian 1:6.1.54-1+rpt2 (2023-10-05)
[ 0.000000] random: crng init done
[ 0.000000] Machine model: Raspberry Pi Zero 2 W Rev 1.0
...
That fails as well with the same reasons, but works with the Workaround above Just to let anybody know, that you don't have to order different hardware...
Workaround works for me, too!
I am on DietPi with Debian Bookworm (Python 3.11).
THis seems to be fixed in latest mqtt-io 2.3.0?