← All tasks
pythonpypa/setuptools-scm #1090Not a task: already works

Unable to install setuptools-scm from source due to tomli project's pyproject.toml

envgap__pypa__setuptools-scm-1090

01 / FAILURE SIGNATURE

As reported upstream

ERROR: Exception:
Not a benchmark task.
  • The project already builds and runs before the fix, so there is nothing to repair.

02 / ENVIRONMENT RECIPE

Base commit
3c145dfd784e41cdb774449a421fe5e17a664786
Manifest
pyproject.toml
Reproduce
Awaiting issue-specific recipe
Run under trace
Awaiting a meaningful runtime command

03 / ORIGINAL ISSUE TEXT

pypa/setuptools-scm #1090 · read the original issue
While installing [bcrypt-4.0.1.tar.gz](https://pypi.org/project/bcrypt/4.0.1/) from source, the dependency chain includes setuptools-scm.



`setuptools-scm` requires tomli, whose pyproject.toml the pre-installed [toml](https://pypi.org/project/toml/) is unable to parse.



Logs:

```

    Collecting setuptools_scm

      Using cached setuptools_scm-8.1.0.tar.gz (76 kB)

      Installing build dependencies: started

      Installing build dependencies: finished with status 'error'

      ERROR: Command errored out with exit status 2:

       command: /home/ubuntu/taws/package/common/venv38/bin/python /home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-zty3bn41/overlay --no-warn-script-location --no-binary :all: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=61' 'tomli; python_version < "3.11"'

           cwd: None

      Complete output (45 lines):

      Collecting setuptools>=61

        Using cached setuptools-75.3.0.tar.gz (1.4 MB)

        Getting requirements to build wheel: started

        Getting requirements to build wheel: finished with status 'done'

          Preparing wheel metadata: started

          Preparing wheel metadata: finished with status 'done'

      Collecting tomli

        Using cached tomli-2.2.1.tar.gz (17 kB)

      ERROR: Exception:

      Traceback (most recent call last):

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/cli/base_command.py", line 186, in _main

          status = self.run(options, args)

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/commands/install.py", line 357, in run

          resolver.resolve(requirement_set)

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 177, in resolve

          discovered_reqs.extend(self._resolve_one(requirement_set, req))

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 333, in _resolve_one

          abstract_dist = self._get_abstract_dist_for(req_to_install)

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/legacy_resolve.py", line 282, in _get_abstract_dist_for

          abstract_dist = self.preparer.prepare_linked_requirement(req)

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/operations/prepare.py", line 515, in prepare_linked_requirement

          abstract_dist = _get_prepared_distribution(

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/operations/prepare.py", line 95, in _get_prepared_distribution

          abstract_dist.prepare_distribution_metadata(finder, build_isolation)

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/distributions/sdist.py", line 33, in prepare_distribution_metadata

          self.req.load_pyproject_toml()

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/req/req_install.py", line 512, in load_pyproject_toml

          pyproject_toml_data = load_pyproject_toml(

        File "/home/ubuntu/taws/package/common/venv38/lib/python3.8/site-packages/pip/_internal/pyproject.py", line 77, in load_pyproject_toml

          pp_toml = toml.load(f)

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 134, in load

          return loads(f.read(), _dict, decoder)

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 455, in loads

          ret = decoder.load_line(line, currentlevel, multikey,

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 725, in load_line

          value, vtype = self.load_value(pair[1], strictly_valid)

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 802, in load_value

          return (self.load_array(v), "array")

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 938, in load_array

          nval, ntype = self.load_value(a[i])

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 802, in load_value

          return (self.load_array(v), "array")

        File "/usr/share/python-wheels/toml-0.10.0-py2.py3-none-any.whl/toml/decoder.py", line 914, in load_array

          a[b] = a[b] + ',' + a[b + 1]

      IndexError: list index out of range

```
Continue on GitHub ↗

04 / LABELS

Labels from the report text only; not yet run

No supported category has been assigned.

Label rules and the text that matched
[]