Skip to content

Installation of packages fails #6571

Closed
Closed
@Jas2Ma

Description

  • I am on the latest stable Poetry version, installed using a recommended method.
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have consulted the FAQ and blog for any relevant entries or release notes.
  • If an exception occurs when executing a command, I executed it again in debug mode (-vvv option) and have included the output below.

Issue

Rerunning my gitlab-ci pipeline it fails since 1.2.1, with 1.2.0 it worked.

Here is the debug -vvv output:

$ poetry -vvv install --no-root
Loading configuration file /root/.config/pypoetry/config.toml
Creating virtualenv curcora in /builds/ja.marx/curvature-and-correlation-analysis/.venv
Using virtualenv: /builds/ja.marx/curvature-and-correlation-analysis/.venv
Installing dependencies from lock file
  Stack trace:
  15  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:329 in run
       327│ 
       328│             try:
     → 329│                 exit_code = self._run(io)
       330│             except Exception as e:
       331│                 if not self._catch_exceptions:
  14  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/console/application.py:185 in _run
       183│         self._load_plugins(io)
       184│ 
     → 185│         exit_code: int = super()._run(io)
       186│         return exit_code
       187│ 
  13  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:423 in _run
       421│             io.input.set_stream(stream)
       422│ 
     → 423│         exit_code = self._run_command(command, io)
       424│         self._running_command = None
       425│ 
  12  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:465 in _run_command
       463│ 
       464│         if error is not None:
     → 465│             raise error
       466│ 
       467│         return event.exit_code
  11  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/application.py:449 in _run_command
       447│ 
       448│             if event.command_should_run():
     → 449│                 exit_code = command.run(io)
       450│             else:
       451│                 exit_code = ConsoleCommandEvent.RETURN_CODE_DISABLED
  10  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/commands/base_command.py:119 in run
       117│         io.input.validate()
       118│ 
     → 119│         status_code = self.execute(io)
       120│ 
       121│         if status_code is None:
   9  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/cleo/commands/command.py:83 in execute
        81│ 
        82│         try:
     →  83│             return self.handle()
        84│         except KeyboardInterrupt:
        85│             return 1
   8  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/console/commands/install.py:145 in handle
       143│         self.installer.verbose(self.io.is_verbose())
       144│ 
     → 145│         return_code = self.installer.run()
       146│ 
       147│         if return_code != 0:
   7  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/installation/installer.py:114 in run
       112│             self._execute_operations = False
       113│ 
     → 114│         return self._do_install()
       115│ 
       116│     def dry_run(self, dry_run: bool = True) -> Installer:
   6  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/installation/installer.py:251 in _do_install
       249│             self._io.write_line("Installing dependencies from lock file")
       250│ 
     → 251│             locked_repository = self._locker.locked_repository()
       252│ 
       253│             if not self._locker.is_fresh():
   5  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/packages/locker.py:199 in locked_repository
       197│ 
       198│                 package.add_dependency(
     → 199│                     Factory.create_dependency(dep_name, constraint, root_dir=root_dir)
       200│                 )
       201│ 
   4  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/core/factory.py:366 in create_dependency
       364│             dependency.source_name = constraint.get("source")
       365│         else:
     → 366│             dependency = Dependency(name, constraint, groups=groups)
       367│ 
       368│         return dependency
   3  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/core/packages/dependency.py:66 in __init__
        64│         self._constraint: VersionConstraint
        65│         self._pretty_constraint: str
     →  66│         self.constraint = constraint  # type: ignore[assignment]
        67│ 
        68│         self._optional = optional
   2  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/core/packages/dependency.py:110 in constraint
       108│     def constraint(self, constraint: str | VersionConstraint) -> None:
       109│         if isinstance(constraint, str):
     → 110│             self._constraint = parse_constraint(constraint)
       111│         else:
       112│             self._constraint = constraint
   1  ~/.local/share/pypoetry/venv/lib/python3.8/site-packages/poetry/core/semver/helpers.py:31 in parse_constraint
        29│         if len(and_constraints) > 1:
        30│             for constraint in and_constraints:
     →  31│                 constraint_objects.append(parse_single_constraint(constraint))
        32│         else:
        33│             constraint_objects.append(parse_single_constraint(and_constraints[0]))
  ParseConstraintError

Metadata

Assignees

No one assigned

    Labels

    area/solverRelated to the dependency resolverkind/questionUser questions (candidates for conversion to discussion)version/1.2.1

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions