nexB/aboutcode-toolkit

Cannot configure aboutcode-toolkit-7.2.0 on Mac OS 13.2.1 with Python 3.11.2 installed

DennisClark opened this issue · 2 comments

I am trying to configure aboutcode-toolkit-7.2.0 on Mac OS 13.2.1 with Python 3.11.2 installed. The problem appears to be with pyproject.toml . I get these messages:

@MacBook-Pro-3 ~ % cd aboutcode-toolkit-7.2.0
@MacBook-Pro-3 aboutcode-toolkit-7.2.0 % ./configure --clean

  • Cleaning ...
    @MacBook-Pro-3 aboutcode-toolkit-7.2.0 % ./configure
    % Total % Received % Xferd Average Speed Time Time Time Current
    Dload Upload Total Spent Left Speed
    100 10.3M 100 10.3M 0 0 16.1M 0 --:--:-- --:--:-- --:--:-- 16.2M
    created virtual environment CPython3.11.2.final.0-64 in 1639ms
    creator CPython3Posix(dest=/Users//aboutcode-toolkit-7.2.0/venv, clear=False, no_vcs_ignore=True, global=False)
    seeder PipInvoke(download=False, pip=embed, setuptools=embed, wheel=embed)
    added seed packages: pip==23.0.1, setuptools==67.4.0, wheel==0.38.4
    activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
    Obtaining file:///Users//aboutcode-toolkit-7.2.0
    Checking if build backend supports build_editable ... done
    Preparing editable metadata (pyproject.toml) ... error
    error: subprocess-exited-with-error

    × Preparing editable metadata (pyproject.toml) did not run successfully.
    │ exit code: 1
    ╰─> [43 lines of output]
    Traceback (most recent call last):
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in
    main()
    File "/Users//aboutcode-toolkit-7.2.0/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 "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 181, in prepare_metadata_for_build_editable
    return hook(metadata_directory, config_settings)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 451, in prepare_metadata_for_build_editable
    return self.prepare_metadata_for_build_wheel(
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 377, in prepare_metadata_for_build_wheel
    self.run_setup()
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/build_meta.py", line 335, in run_setup
    exec(code, locals())
    File "", line 6, in
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/init.py", line 108, in setup
    return distutils.core.setup(**attrs)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 159, in setup
    dist.parse_config_files()
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/_virtualenv.py", line 21, in parse_config_files
    result = old_parse_config_files(self, args, **kwargs)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/dist.py", line 881, in parse_config_files
    setupcfg.parse_configuration(
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 163, in parse_configuration
    options.parse()
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 508, in parse
    section_parser_method(section_options)
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 482, in parse_section
    self[name] = value
    ~~~~^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/config/setupcfg.py", line 290, in setitem
    value = parser(value)
    ^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/_vendor/packaging/specifiers.py", line 711, in init
    parsed.add(Specifier(specifier))
    ^^^^^^^^^^^^^^^^^^^^
    File "/Users//aboutcode-toolkit-7.2.0/venv/lib/python3.11/site-packages/setuptools/_vendor/packaging/specifiers.py", line 245, in init
    raise InvalidSpecifier(f"Invalid specifier: '{spec}'")
    setuptools.extern.packaging.specifiers.InvalidSpecifier: Invalid specifier: '>=3.6.
    '
    [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.

per suggestion from @pombredanne I updated line 58 of the file setup.cfg to read
python_requires = >=3.6
instead of the invalid
python_requires = >=3.6.*
and
that resolved the problem. The ./configure ran successfully after I updated the file.
I was also able to run these commands successfully:
source ./venv/bin/activate
and
about -h

I am not the right person to submit the fix for the file, which should be someone familiar with the complete bug-fix process, thanks.

@DennisClark thanks for testing!
I submitted #521 to fix this.