I’m trying to install factory on my poetry env but I’m getting this error:
poetry add factory
Using version ^1.2 for factory
Updating dependencies
Resolving dependencies... (3.4s)
Package operations: 1 install, 1 update, 0 removals
- Updating setuptools (75.1.0 -> 75.6.0)
- Installing factory (1.2): Failed
ChefBuildError
Backend subprocess exited when trying to invoke get_requires_for_build_wheel
Traceback (most recent call last):
File "/Users/XXXX/Library/Application Support/pypoetry/venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 389, in <module>
main()
File "/Users/XXXX/Library/Application Support/pypoetry/venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 373, in main
json_out["return_val"] = hook(**hook_input["kwargs"])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/XXXX/Library/Application Support/pypoetry/venv/lib/python3.11/site-packages/pyproject_hooks/_in_process/_in_process.py", line 143, in get_requires_for_build_wheel
return hook(config_settings)
^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/rh/h9myr_6x779dbxhx7fkzrwlh0000gn/T/tmpfdlsqi07/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 334, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=[])
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/private/var/folders/rh/h9myr_6x779dbxhx7fkzrwlh0000gn/T/tmpfdlsqi07/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 304, in _get_build_requires
self.run_setup()
File "/private/var/folders/rh/h9myr_6x779dbxhx7fkzrwlh0000gn/T/tmpfdlsqi07/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 522, in run_setup
super().run_setup(setup_script=setup_script)
File "/private/var/folders/rh/h9myr_6x779dbxhx7fkzrwlh0000gn/T/tmpfdlsqi07/.venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 320, in run_setup
exec(code, locals())
File "<string>", line 11, in <module>
NameError: name 'file' is not defined. Did you mean: 'filter'?
at ~/Library/Application Support/pypoetry/venv/lib/python3.11/site-packages/poetry/installation/chef.py:164 in _prepare
160│
161│ error = ChefBuildError("nn".join(message_parts))
162│
163│ if error is not None:
→ 164│ raise error from None
165│
166│ return path
167│
168│ 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 factory (1.2) not supporting PEP 517 builds. You can verify this by running 'pip wheel --no-cache-dir --use-pep517 "factory (==1.2)"'.
How can I solve this?
I haven’t any issues with any other dependencies and I’m using Python 3.11.
New contributor
Teresa Jimenez is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1