Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error in behave setup command: use_2to3 is invalid. #24

Open
Johnlon opened this issue Feb 17, 2024 · 0 comments
Open

error in behave setup command: use_2to3 is invalid. #24

Johnlon opened this issue Feb 17, 2024 · 0 comments

Comments

@Johnlon
Copy link

Johnlon commented Feb 17, 2024

Elsewhere I found this as a fix...

pip install "setuptools<58.0.0"

But then I got a different error - see 2nd listing below.

I then used this hack : https://stackoverflow.com/questions/72659999/chatterbot-module-error-attributeerror-module-collections-has-no-attribute to change the package of HAshtable to .abc.

I use ...
Python 3.10.12
pip 24.0
.. but hacked up as above (Grrrrr python ecosystem, why can't it just work!!!)

=========

(.venv) john@JohnLenovo14Pro:~/work/behave.example$ pip install -r py.requirements/all.txt
Collecting git+https://github.com/behave/[email protected] (from -r py.requirements/basic.txt (line 11))
Cloning https://github.com/behave/behave.git (to revision v1.2.7.dev1) to /tmp/pip-req-build-lse6vqsl
Running command git clone --filter=blob:none --quiet https://github.com/behave/behave.git /tmp/pip-req-build-lse6vqsl
Running command git checkout -q 4e73cabf1b2445b3c1ab6b3aed14424d32d140ac
Resolved https://github.com/behave/behave.git to commit 4e73cabf1b2445b3c1ab6b3aed14424d32d140ac
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [16 lines of output]
/home/john/work/behave.example/.venv/lib/python3.10/site-packages/setuptools/dist.py:472: SetuptoolsDeprecationWarning: Invalid dash-separated options
!!

          ********************************************************************************
          Usage of dash-separated 'upload-dir' will not be supported in future
          versions. Please use the underscore name 'upload_dir' instead.

          By 2024-Sep-26, 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.
          ********************************************************************************

  !!
    opt = self.warn_dash_deprecation(opt, section)
  error in behave setup command: use_2to3 is invalid.
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

======

(.venv) john@JohnLenovo14Pro:~/work/behave.example$ invoke cleanup
Traceback (most recent call last):
File "/home/john/work/behave.example/.venv/bin/invoke", line 8, in
sys.exit(program.run())
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/program.py", line 373, in run
self.parse_collection()
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/program.py", line 465, in parse_collection
self.load_collection()
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/program.py", line 702, in load_collection
self.config.load_project()
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/config.py", line 749, in load_project
self._load_file(prefix="project", merge=merge)
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/config.py", line 888, in _load_file
self._set(data, loader(filepath))
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/config.py", line 908, in _load_yaml
return yaml.load(fd)
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/init.py", line 72, in load
return loader.get_single_data()
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/constructor.py", line 37, in get_single_data
return self.construct_document(node)
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/constructor.py", line 46, in construct_document
for dummy in generator:
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/constructor.py", line 398, in construct_yaml_map
value = self.construct_mapping(node)
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/constructor.py", line 204, in construct_mapping
return super().construct_mapping(node, deep=deep)
File "/home/john/work/behave.example/.venv/lib/python3.10/site-packages/invoke/vendor/yaml3/constructor.py", line 126, in construct_mapping
if not isinstance(key, collections.Hashable):
AttributeError: module 'collections' has no attribute 'Hashable'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant