Error when updating lock file for PDM (pep621) dev dependencies #22440
How are you running Renovate?Self-hosted If you're self-hosting Renovate, tell us what version of Renovate you run.35.102.2 If you're self-hosting Renovate, select which platform you are using.GitLab self-hosted If you're self-hosting Renovate, tell us what version of the platform you run.GitLab 15.10.7 Was this something which used to work for you, and then stopped?I never saw this working Wanted end result.Lock file is updated 😃 As per PDM's documentation, to update a non-default dependency, one has to specify the group of the dependency. So (in this exact case) instead of running: pdm update pytest pytest-asyncio ruffIt should be: pdm update -G tests pytest pytest-asyncio
pdm update -G lint ruffWhat you tried so far.I've disabled lock file updates by setting Relevant debug logsLogspyproject.toml[project]
dependencies = [
"fastapi~=0.95.2",
"uvicorn~=0.22.0"
]
[project.optional-dependencies]
lint = [
"ruff>=0.0.269",
]
tests = [
"pytest>=7.3.0",
"pytest-asyncio>=0.20.3"
] |
Replies: 5 comments 16 replies
|
Hi there, Get your issue fixed faster by creating a minimal reproduction. This means a repository dedicated to reproducing this issue with the minimal dependencies and config possible. Before we start working on your issue we need to know exactly what's causing the current behavior. A minimal reproduction helps us with this. To get started, please read our guide on creating a minimal reproduction. We may close the issue if you, or someone else, haven't created a minimal reproduction within two weeks. If you need more time, or are stuck, please ask for help or more time in a comment. Good luck, The Renovate team |
|
While trying to create a minimal reproduction on GitHub, I have encountered another error: aleksul/renovate-reproduction-dev-deps-pdm#5 Command failed: docker run --rm --name=renovate_sidecar --label=renovate_child -v "/mnt/renovate/gh/aleksul/renovate-reproduction-pdm-dev-deps":"/mnt/renovate/gh/aleksul/renovate-reproduction-pdm-dev-deps" -v "/tmp/renovate-cache":"/tmp/renovate-cache" -v "/tmp/containerbase":"/tmp/containerbase" -e BUILDPACK_CACHE_DIR -e CONTAINERBASE_CACHE_DIR -w "/mnt/renovate/gh/aleksul/renovate-reproduction-pdm-dev-deps" ghcr.io/containerbase/sidecar bash -l -c "install-tool pdm 2.6.1 && pdm update ruff pytest pytest-asyncio"
No python defined - aborting |
|
I have re-runned the reproduction example on the I have also managed to reproduce the initial "does not exist in default dependencies" error, please see aleksul/renovate-reproduction-dev-deps-pdm repo and PR #3 as one of the examples. |
|
Just to add to this issue, I've reproduced an additional issue over https://github.com/mkniewallner/renovate-pdm-groups-issue, where the project contains multiple mkniewallner/renovate-pdm-groups-issue#2 fails to update a dependency that is located in Command failed: docker run --rm --name=renovate_sidecar --label=renovate_child -v "/mnt/renovate/gh/mkniewallner/renovate-pdm-groups-issue":"/mnt/renovate/gh/mkniewallner/renovate-pdm-groups-issue" -v "/tmp/renovate-cache":"/tmp/renovate-cache" -v "/tmp/containerbase":"/tmp/containerbase" -e BUILDPACK_CACHE_DIR -e CONTAINERBASE_CACHE_DIR -w "/mnt/renovate/gh/mkniewallner/renovate-pdm-groups-issue" ghcr.io/containerbase/sidecar bash -l -c "install-tool python 3.11.3 && install-tool pdm 2.6.1 && pdm update httpx"
[ProjectError]: httpx does not exist in default dependencies.The real project that the reproduction is based on used to rely on Poetry, where dependencies correctly got updated, so I believe that this issue is specific to PDM. PDM provides a way to specify the path to a project through pdm update --project sub_directory httpx |
#22489