Unable to retrieve the package version for git on preview 1.1.0b2
See original GitHub issue- I am on the latest Poetry version.
- I have searched the issues of this repo and believe that this is not a duplicate.
- If an exception occurs when executing a command, I executed it again in debug mode (
-vvv
option).
- OS version and name: Linux 5.7.11-1-MANJARO
- Poetry version: 1.1.0b2
- Link of a Gist with the contents of your pyproject.toml file: https://gist.github.com/serjflint/dfbb4bc8293ebce28b256aa53c22c8ac
Issue
I need the preview build for solving another bug. But now git packages are not working. Works as intended on the latest release 1.0.10.
Stack trace:
9 ~/.poetry/lib/poetry/_vendor/py3.8/clikit/console_application.py:131 in run
129β parsed_args = resolved_command.args
130β
β 131β status_code = command.handle(parsed_args, io)
132β except KeyboardInterrupt:
133β status_code = 1
8 ~/.poetry/lib/poetry/_vendor/py3.8/clikit/api/command/command.py:120 in handle
118β def handle(self, args, io): # type: (Args, IO) -> int
119β try:
β 120β status_code = self._do_handle(args, io)
121β except KeyboardInterrupt:
122β if io.is_debug():
7 ~/.poetry/lib/poetry/_vendor/py3.8/clikit/api/command/command.py:171 in _do_handle
169β handler_method = self._config.handler_method
170β
β 171β return getattr(handler, handler_method)(args, io, self)
172β
173β def __repr__(self): # type: () -> str
6 ~/.poetry/lib/poetry/_vendor/py3.8/cleo/commands/command.py:92 in wrap_handle
90β self._command = command
91β
β 92β return self.handle()
93β
94β def handle(self): # type: () -> Optional[int]
5 ~/.poetry/lib/poetry/console/commands/add.py:101 in handle
99β raise ValueError("Package {} is already present".format(name))
100β
β 101β requirements = self._determine_requirements(
102β packages,
103β allow_prereleases=self.option("allow-prereleases"),
4 ~/.poetry/lib/poetry/console/commands/init.py:296 in _determine_requirements
294β return requires
295β
β 296β requires = self._parse_requirements(requires)
297β result = []
298β for requirement in requires:
3 ~/.poetry/lib/poetry/console/commands/init.py:386 in _parse_requirements
384β pair["extras"] = extras
385β
β 386β package = Provider.get_package_from_vcs(
387β "git", url.url, reference=pair.get("rev")
388β )
2 ~/.poetry/lib/poetry/puzzle/provider.py:209 in get_package_from_vcs
207β revision = git.rev_parse(reference, tmp_dir).strip()
208β
β 209β package = cls.get_package_from_directory(tmp_dir, name=name)
210β
211β package.source_type = "git"
1 ~/.poetry/lib/poetry/puzzle/provider.py:311 in get_package_from_directory
309β cls, directory, name=None
310β ): # type: (Path, Optional[str]) -> Package
β 311β package = PackageInfo.from_directory(
312β path=directory, allow_build=True
313β ).to_package(root_dir=directory)
RuntimeError
Unable to retrieve the package version for triopg
at ~/.poetry/lib/poetry/inspection/info.py:135 in to_package
131β name = name or self.name
132β
133β if not self.version:
134β # The version could not be determined, so we raise an error since it is mandatory.
β 135β raise RuntimeError(
136β "Unable to retrieve the package version for {}".format(name)
137β )
138β
139β package = Package(name=name, version=self.version)
Issue Analytics
- State:
- Created 3 years ago
- Reactions:7
- Comments:9 (6 by maintainers)
Top Results From Across the Web
poetry - PyPI
Poetry: Python packaging and dependency management made easy. Stable Version Pre-release Version Python Versions Download Stats Discord.
Read more >Visual Studio 2019 version 16.0 Release Notes | Microsoft Learn
Get information on the latest release features, bug fixes, and support for Visual Studio 2019 v16.0.
Read more >After upgrade to Big Sur git stopped working - Apple Developer
After upgrade to Big Sur git stopped working and it keeps prompting to install CLT. According to Xcode-select, see output below CLT is...
Read more >Changelog β conan 1.55.0 documentation
Docs here; Feature: Add stdcpp_library to conan.tools.build to get name of C++ ... Docs here; Feature: Update requirements.txt to use distro package version...
Read more >History | Poetry - Python dependency management and ...
Fix an issue where Git dependencies failed to clone when insteadOf was used in ... When displaying the name of packages retrieved from...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Iβm having the same issue and it does not appear resolved by installing
poetry-core
frommaster
:https://gist.github.com/rotu/307020f80998bcb18f9236f4f79aeb87
Sweet! Can confirm my issue is resolved under Poetry master.