Skip to content

Failed to resolve this package in environment where pre-releases are not allowed. #4219

Open
@prudnikov

Description

@prudnikov

Describe your environment

OS: MacOS
Python version: 3.11
SDK version: 1.27
API version: 1.27

What happened?

opentelemetry-semantic-conventions package is published with version like 0.48b0, which treated as BETA version.
https://packaging.python.org/en/latest/discussions/versioning/

This package also is a peer dependency from apache-airflow.

As a result, opentelemetry-semantic-conventions package can't be resolved in the environments where pre-release packages are not allowed.

Steps to Reproduce

We use PDM.

pdm init

Add the following section to the pyproject.toml

[tool.pdm.resolution]
allow-prereleases = false

then run

pdm add opentelemetry-semantic-conventions==0.48b0

Expected Result

Package resolved and installed.
This will work if package version will not include b0 suffix, so instead of 0.48b0 it should be 0.48.

Actual Result

❯ pdm add opentelemetry-semantic-conventions==0.48b0
Adding packages to default dependencies: opentelemetry-semantic-conventions==0.48b0
  0:00:00 🔒 Lock failed.  ERROR: Unable to find a resolution for opentelemetry-semantic-conventions
Please make sure the package name is correct.
  0:00:00 🔒 Lock failed.
See /Users/XXXX/Library/Logs/pdm/pdm-lock-58p93c2u.log for detailed debug log.
[ResolutionImpossible]: Unable to find a resolution
WARNING: Add '-v' to see the detailed traceback

Additional context

No response

Would you like to implement a fix?

None

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions