Description

The pyproject crawler looks recursively for all pyproject.toml files from a specific root directory. Then for each of them, it tries to update the Python dependencies declared in the [project] table.

Dependencies are read from:

  • [project.dependencies]

  • [project.optional-dependencies] (one manifest per package, per group)

Directories named .venv, pycache, .git, node_modules, .tox, .nox, and .eggs are never walked.

This crawler is enabled by default, so it can be used either automatically by running updatecli diff from a directory containing the files to update, or by providing a manifest. The automatic discovery behavior can be tuned by providing a YAML manifest with a pyproject crawler in top-level directive autodiscovery as explained in the "Autodiscovery" page.

Requirements

The crawler detects the package manager from the lock file sitting next to pyproject.toml. Only uv is supported today, via uv.lock.

The result depends on what Updatecli finds next to each pyproject.toml:

uv.lockuv command on PATHResult

present

yes

Full manifests: a pypi source and a shell target that refreshes uv.lock.

present

no

The pyproject.toml is skipped entirely, with a warning. Updatecli refuses to bump a dependency it cannot re-lock.

absent

-

Source-only manifests. Updatecli reports the latest published version but generates no target, so nothing is modified.

Tip
If a project produces no manifest at all, check that uv is installed and reachable from the environment running Updatecli.

Generated manifests

One manifest is generated per dependency, using the pypi resource as a source and a shell target:

name: 'deps(pypi): bump "requests" for "myproject" project'
sources:
  requests:
    name: 'Get latest "requests" package version'
    kind: 'pypi'
    spec:
      name: 'requests'
      versionfilter:
        kind: 'pep440'
        pattern: '>=2.28'
targets:
  requests:
    name: 'deps(pypi): bump "requests" to {{ source "requests" }}'
    kind: 'shell'
    spec:
      command: 'uv lock --upgrade-package requests=={{ source "requests" }}'
      changedif:
        kind: file/checksum
        spec:
          files:
            - "uv.lock"
      environments:
        - name: PATH
      workdir: '.'
    disablesourceinput: true

workdir points at the directory holding the pyproject.toml, so nested projects are updated in place.

Important
uv lock --upgrade-package only updates uv.lock. The version constraints declared in pyproject.toml are deliberately left untouched, so a dependency is only bumped as far as its own constraint allows. Widening a constraint such as requests>=2.28,<3 remains a manual change.

The shell target only exposes the PATH environment variable to uv. Variables such as UV_INDEX_URL, NETRC, or HOME are not inherited.

Version filtering

If no versionfilter is specified, the crawler falls back to kind: pep440 and reuses each dependency’s own constraint as the pattern, for example >=2.28 for requests>=2.28. Dependencies declared without a constraint get the pattern *.

If a versionfilter is specified, its kind is used for every generated source, and relative semver patterns are resolved against the version currently declared by each dependency. For example kind: semver with pattern: minor generates pattern: '2.x' for requests>=2.28. Explicit constraint patterns such as >=1.0.0 are used as-is.

More details on the "Version Filtering" page.

Limitations

  • Only the [project] table is read. [dependency-groups] (PEP 735), [tool.poetry], [tool.uv], and [build-system].requires are ignored, so Poetry and PDM projects yield no manifest.

  • PEP 508 direct references such as mypkg @ https://…​; or mypkg @ git+https://…​, and local path dependencies, are skipped with a warning.

  • Extras are dropped from the tracked name: black[jupyter]>=24.0 is tracked as black.

  • Environment markers are stripped, not evaluated. pywin32>=300; sys_platform == 'win32' is updated unconditionally.

Manifest

Parameters

NameTypeDescriptionRequired
ageobject

“age” defines the minimum or maximum age of a release to be considered valid.

default:

age:
  minimum: 7d

remark:

  • it accepts a duration string, such as “24h”, “7d”, “3w” or “1y”.
  • it is propagated to the generated pypi sources.
  • the default keeps Updatecli from suggesting a package version published less than seven days ago. An empty “age: {}” disables it.
  • the default doesn’t apply with “indexurl”, as private registries may not report the upload times an age filter needs. On a registry reporting none, an explicit “age” makes the generated sources skip.
  • a version lower than the one uv.lock resolves, or the one pinned with “==” without uv.lock, is never suggested. While every newer release is too recent, the update is skipped. Set “allowdowngrade” to true to fall back to the newest release old enough instead. Kinds other than “pep440” and “semver”, such as “latest”, can’t exclude lower versions. A dependency is skipped, with a warning, when its installed version can’t bound the versionfilter, such as “1.0.post1” with the “semver” kind.
  • security fixes don’t wait for it, see “vulnerability”.
    allowdowngradeboolean

“allowdowngrade” defines whether an update can lower the version in use.

default: false

remark:

  • by default, an update never lowers the version in use. While every newer release is too recent, the update is skipped.
  • when set to true, an update lowers the version in use when it doesn’t match the age filter, to the newest release that does.
  • it only applies with a “minimum” or “maximum” age.
    maximumstring

“maximum” defines the maximum age a release may have to be considered.

remark:

  • accepted units are “d” for days, “w” for weeks, “mo” for months and “y” for years, plus the Go duration units such as “h”, “m” and “s”.
  • a unit is required.
  • a month counts as 1/12 of a year and a year as 365 days.

example:

  • maximum: 6mo
  • maximum: 1y
    minimumstring

“minimum” defines the minimum age a release must have to be considered.

remark:

  • accepted units are “d” for days, “w” for weeks, “mo” for months and “y” for years, plus the Go duration units such as “h”, “m” and “s”.
  • a unit is required.
  • a month counts as 1/12 of a year and a year as 365 days.

example:

  • minimum: 24h
  • minimum: 7d
  • minimum: 3w
groupsarray

“groups” defines dependencies updated together, in one pipeline per group.

default: empty, every dependency follows “groupby”.

remark:

  • “only” uses the same rules as the crawler “only” setting, and narrows it: a group dependency must match both the crawler “only” and the group “only”. A group rule combined with a crawler rule setting the same field to another value matches nothing.
  • a dependency belongs to the first group it matches.
  • dependencies matching no group follow “groupby”.
  • the group name is added to the generated pipeline IDs and action titles, and set as the “updatecli.io/group” label, so “–labels updatecli.io/group:aws” selects them.
  • the name “default” is reserved for the dependencies matching no group.
  • it isn’t supported by WASM plugins.

example:

groups:
  - name: aws
    only:
      - modules:
          "github.com/aws/*": ""
    namestring

“name” identifies the group in the generated pipelines.

remark:

  • it must be unique, start with a letter or a digit, and only contain letters, digits, “.” and “-”.
    onlyarray

“only” defines the rules matching the dependencies of the group.

remark:

  • it accepts the same rules as the crawler “only” setting.
ignorearray

“ignore” defines rules to exclude matching Python dependencies from the autodiscovery.

remark:

  • a Python dependency is ignored when it matches at least one rule.
    dependencygroupsarray

“dependencygroups” defines the PEP 735 “[dependency-groups]” names to match, such as “dev”.

remark:

  • each value is a pattern following the Go filepath.Match syntax, so “*” matches any group.
  • names are compared once normalized as PEP 735 requires, ignoring case and treating runs of “-”, “_” and “.” alike, so “dev-tools” matches a group declared as “Dev_Tools”.
  • patterns are normalized the same way, including inside brackets, so “[_.]” means “[-]”.
  • a group including another one through {include-group = “…”} contains its dependencies too, as PEP 735 defines, so “dev” matches the dependencies “dev” includes from “test”.
  • dependencies from “[project.dependencies]” and “[project.optional-dependencies]” belong to no dependency group, so they never match this field.

example:

only:
  - dependencygroups:
      - dev
    packagesobject

“packages” defines the Python packages to match, keyed by package name.

remark:

  • names are compared once normalized as PEP 503 requires, ignoring case and treating runs of “-”, “_” and “.” alike, so “typing-extensions” matches “Typing_Extensions”.
  • an empty value matches any version.
  • otherwise the value is a PEP 440 version specifier, such as “>=2.0,<3.0”.
  • when the version or the specifier cannot be parsed, the value must equal the version.
    pathstring

“path” defines a “pyproject.toml” path pattern.

remark:

  • the pattern must match the whole path, not just a substring.
  • the pattern follows the Go filepath.Match syntax, such as “*” or “?”.
indexurlstring

“indexurl” defines a custom PyPI index URL used by every generated source.

remark:

  • it carries no credentials: a private registry requires setting the pypi resource “token” field in the generated manifests.
onlyarray

“only” defines rules to restrict the autodiscovery to matching Python dependencies.

remark:

  • a Python dependency is kept only when it matches at least one rule.
    dependencygroupsarray

“dependencygroups” defines the PEP 735 “[dependency-groups]” names to match, such as “dev”.

remark:

  • each value is a pattern following the Go filepath.Match syntax, so “*” matches any group.
  • names are compared once normalized as PEP 735 requires, ignoring case and treating runs of “-”, “_” and “.” alike, so “dev-tools” matches a group declared as “Dev_Tools”.
  • patterns are normalized the same way, including inside brackets, so “[_.]” means “[-]”.
  • a group including another one through {include-group = “…”} contains its dependencies too, as PEP 735 defines, so “dev” matches the dependencies “dev” includes from “test”.
  • dependencies from “[project.dependencies]” and “[project.optional-dependencies]” belong to no dependency group, so they never match this field.

example:

only:
  - dependencygroups:
      - dev
    packagesobject

“packages” defines the Python packages to match, keyed by package name.

remark:

  • names are compared once normalized as PEP 503 requires, ignoring case and treating runs of “-”, “_” and “.” alike, so “typing-extensions” matches “Typing_Extensions”.
  • an empty value matches any version.
  • otherwise the value is a PEP 440 version specifier, such as “>=2.0,<3.0”.
  • when the version or the specifier cannot be parsed, the value must equal the version.
    pathstring

“path” defines a “pyproject.toml” path pattern.

remark:

  • the pattern must match the whole path, not just a substring.
  • the pattern follows the Go filepath.Match syntax, such as “*” or “?”.
pypimirrorsarray

“pypimirrors” defines the registries mirroring pypi.org, such as an Artifactory or Nexus proxy, whose packages are checked against the OSV database by “vulnerability”.

default: empty, so only the packages uv.lock resolves from pypi.org are checked.

remark:

  • it requires “vulnerability”.
  • the OSV database only covers packages published on pypi.org. A package uv.lock resolves from another registry is skipped and reported unless its registry is listed here.
  • only list registries serving pypi.org packages: a private package may only share its name with a public one, and would get its advisories.
  • each value is the registry URL as written in uv.lock, a trailing “/” is ignored.

example:

pypimirrors:
  - https://artifactory.example.com/api/pypi/pypi-remote/simple
rootdirstring

“rootdir” defines the directory where the crawler starts searching for “pyproject.toml” files.

default: the scm directory when “scmid” is set, otherwise the directory relative paths resolve from, by default the working directory.

remark:

  • a relative path is resolved from the default directory.
  • an absolute path is used as is, instead of the scm directory.
tracksarray

“tracks” defines an ordered list of tracks, each one choosing versions its own way. The crawler runs once per track, and each track gets its own pipelines.

default: empty, the crawler runs once with its own settings.

remark:

  • each track requires a “name”, and sets “versionfilter”, “age” or both.
  • a setting used by a track can’t also be set on the crawler, so a track without it uses the crawler default.
  • “age” is only accepted by crawlers supporting it.
  • the name is added to the generated pipeline IDs and action titles, and set as the “updatecli.io/track” label, so “–labels updatecli.io/track:major” selects them.
  • a track waits while an earlier track still has a pending update, so a major update is proposed once no minor update is pending. With “groupby: individual”, it waits for the same dependency. With “groupby: all”, or in a group, the dependencies share one pull request per crawler, so it waits for the whole pull request: one pending minor update holds back every major update of that crawler. An update is pending while its pull request is open or, without an action, while its working branch exists. Tracks are run in the order they are listed.
  • a track with “wait: false” never waits, but later tracks still wait for it.
  • the version filters of the tracks should not overlap, for example “minor” then “majoronly”. Tracks setting only “age” share the crawler version filter, so they overlap: with “allowdowngrade”, one track may undo the updates of another.
  • it isn’t supported by WASM plugins.

example:

tracks:
  - name: minor
    versionfilter:
      kind: semver
      pattern: minor
    age:
      minimum: 3d
  - name: major
    versionfilter:
      kind: semver
      pattern: majoronly
    age:
      minimum: 14d
  - name: lts
    wait: false
    versionfilter:
      kind: regex
      pattern: '^1\.'
    ageobject

“age” defines the release age accepted by the track, as the crawler “age” does.

default: the crawler default age.

remark:

  • it’s only accepted by crawlers supporting “age”.
        allowdowngradeboolean

“allowdowngrade” defines whether an update can lower the version in use.

default: false

remark:

  • by default, an update never lowers the version in use. While every newer release is too recent, the update is skipped.
  • when set to true, an update lowers the version in use when it doesn’t match the age filter, to the newest release that does.
  • it only applies with a “minimum” or “maximum” age.
        maximumstring

“maximum” defines the maximum age a release may have to be considered.

remark:

  • accepted units are “d” for days, “w” for weeks, “mo” for months and “y” for years, plus the Go duration units such as “h”, “m” and “s”.
  • a unit is required.
  • a month counts as 1/12 of a year and a year as 365 days.

example:

  • maximum: 6mo
  • maximum: 1y
        minimumstring

“minimum” defines the minimum age a release must have to be considered.

remark:

  • accepted units are “d” for days, “w” for weeks, “mo” for months and “y” for years, plus the Go duration units such as “h”, “m” and “s”.
  • a unit is required.
  • a month counts as 1/12 of a year and a year as 365 days.

example:

  • minimum: 24h
  • minimum: 7d
  • minimum: 3w
    namestring

“name” identifies the track in the generated pipelines.

remark:

  • it must be unique, start with a letter or a digit, and only contain letters, digits, “.” and “-”.
    versionfilterobject

“versionfilter” defines the version filter used by the track, as the crawler “versionfilter” does.

default: the crawler default version filter.

        kindstring

“kind” defines the versioning scheme used to select a version.

default: latest

remark:

  • accepted values are “latest”, “semver”, “regex”, “regex/semver”, “time”, “regex/time”, “lex” and “pep440”.
  • “latest” returns the last version of the list.
  • “lex” sorts the versions lexicographically and returns the last one.
  • “pep440” follows https://peps.python.org/pep-0440/

example:

  • kind: semver
        patternstring

“pattern” defines the version pattern, according to “kind”.

default:

  • latest: “latest”
  • semver and pep440: “*”
  • regex: “.*”
  • time and regex/time: “2006-01-02”

remark:

  • for “latest”, “latest” returns the last version, any other value must match a version exactly.
  • for “semver” and “regex/semver”, it is a semantic versioning constraint.
  • for “pep440”, it is a pep440 version specifier.
  • for “regex”, it is a regular expression.
  • for “time” and “regex/time”, it is a Go date layout.
  • ignored by “lex”.

example:

  • pattern: ~1.2
  • pattern: “>=1.0.0 <2.0.0”
  • pattern: ^v\d+.\d+.\d+$
        regexstring

“regex” defines the regular expression extracting the version from each entry.

remark:

  • only used by the kinds “regex/semver” and “regex/time”.
  • the value of the first capture group is used as the version.

example:

  • regex: ^v(\d+.\d+.\d+)$
        replaceallobject

“replaceall” applies a regular expression replacement to each version before filtering.

remark:

  • only used by the kinds “regex”, “regex/semver” and “regex/time”.
  • the replacement runs before “pattern” or “regex” is evaluated.

example:

replaceall:
  pattern: "_"
  replacement: "."

turns “curl-8_15_0” into “curl-8.15.0”.

        strictboolean

“strict” enforces strict semantic versioning rules when parsing versions.

default: false

remark:

  • only used by the kinds “semver” and “regex/semver”.
    waitboolean

“wait” defines whether the track waits while an earlier track still has a pending update.

default: true

remark:

  • a track with “wait: false” proposes its updates at once, but later tracks still wait for it.
  • it has no effect on the first track, which never waits.
versionfilterobject

“versionfilter” defines the version filter used by the generated manifests.

default: kind “pep440” with the dependency’s own constraint as pattern, such as “>=2.28” for “requests>=2.28”, or “*” when the dependency is declared without a constraint.

remark:

  • with kind “pep440”, “pattern” accepts a PEP 440 version specifier, such as “>=2.28”, “>=1.0,<3.0” or “*”.
  • with kind “semver”, “pattern” accepts:
    • “prerelease”: the latest prerelease of the current version.
    • “patch”: patch updates only.
    • “minor”: patch and minor updates.
    • “minoronly”: minor updates only.
    • “major”: patch, minor and major updates.
    • “majoronly”: major updates only.
    • a version constraint, such as “>= 1.0.0”.
  • relative patterns such as “minor” are resolved against the version each dependency’s constraint starts from, so “minor” gives the pattern “2.x” for “requests>=2.28,<3”. A dependency whose constraint sets no lower bound, such as “requests<3”, is skipped, unless its installed version is known, as below. With an age filter not allowing a downgrade, they are resolved against the installed version instead: the version uv.lock resolves or, without uv.lock, the version pinned with “==”. “minor” then gives “>=3.1.0, 3.x” when uv.lock resolves requests 3.1.0.
  • with kind “regex”, “pattern” accepts a regular expression.
  • more examples at https://www.updatecli.io/docs/core/versionfilter/

example:

versionfilter:
  kind: pep440
  pattern: ">=2.28"
    kindstring

“kind” defines the versioning scheme used to select a version.

default: latest

remark:

  • accepted values are “latest”, “semver”, “regex”, “regex/semver”, “time”, “regex/time”, “lex” and “pep440”.
  • “latest” returns the last version of the list.
  • “lex” sorts the versions lexicographically and returns the last one.
  • “pep440” follows https://peps.python.org/pep-0440/

example:

  • kind: semver
    patternstring

“pattern” defines the version pattern, according to “kind”.

default:

  • latest: “latest”
  • semver and pep440: “*”
  • regex: “.*”
  • time and regex/time: “2006-01-02”

remark:

  • for “latest”, “latest” returns the last version, any other value must match a version exactly.
  • for “semver” and “regex/semver”, it is a semantic versioning constraint.
  • for “pep440”, it is a pep440 version specifier.
  • for “regex”, it is a regular expression.
  • for “time” and “regex/time”, it is a Go date layout.
  • ignored by “lex”.

example:

  • pattern: ~1.2
  • pattern: “>=1.0.0 <2.0.0”
  • pattern: ^v\d+.\d+.\d+$
    regexstring

“regex” defines the regular expression extracting the version from each entry.

remark:

  • only used by the kinds “regex/semver” and “regex/time”.
  • the value of the first capture group is used as the version.

example:

  • regex: ^v(\d+.\d+.\d+)$
    replaceallobject

“replaceall” applies a regular expression replacement to each version before filtering.

remark:

  • only used by the kinds “regex”, “regex/semver” and “regex/time”.
  • the replacement runs before “pattern” or “regex” is evaluated.

example:

replaceall:
  pattern: "_"
  replacement: "."

turns “curl-8_15_0” into “curl-8.15.0”.

        patternstring

“pattern” defines the regular expression matching the text to replace.

example:

  • pattern: “_”
        replacementstring

“replacement” defines the text replacing each match of “pattern”.

remark:

  • capture groups can be referenced with $1, $2, and so on.

example:

  • replacement: “.”
    strictboolean

“strict” enforces strict semantic versioning rules when parsing versions.

default: false

remark:

  • only used by the kinds “semver” and “regex/semver”.
vulnerabilityobject

“vulnerability” switches the autodiscovery to security updates, based on the OSV database (https://osv.dev).

A package is only updated when its current version has known vulnerabilities, to the lowest version without any.

remark:

  • only security updates are generated, routine updates require a separate manifest.
  • it cannot be combined with:
    • “age”, as a fixed version is suggested as soon as it is known. The default age doesn’t apply either.
    • “versionfilter”, as the version is the lowest one without known vulnerabilities.
    • “indexurl”, as the OSV database only covers packages published on pypi.org.
  • the current version is the version resolved in the uv.lock of the pyproject.toml or, without one, the version pinned with “==” in pyproject.toml. With a uv.lock, a package it doesn’t resolve has no current version, even when pinned. Packages without an identifiable current version are ignored, as are packages uv.lock resolves from a workspace, a path or a git repository rather than from a registry.
  • packages uv.lock resolves from a registry other than pypi.org are skipped and reported, unless the registry is listed under “pypimirrors”.
  • “only” and “ignore” version rules match the current version.
  • a package listed in several groups at the same version gives a single manifest.
  • pyproject.toml is never modified: when the fixed version falls outside the declared version constraint, the uv target fails until the constraint is widened.
  • without uv.lock, nothing is modified and the manifests only report the vulnerable packages.
  • labels, such as “security”, are set on the action used by the manifest.

example:

vulnerability:
  minseverity: high
  ignore:
    - CVE-2024-56201
    ignorearray

“ignore” defines the vulnerability IDs or aliases to disregard.

example:

ignore:
  - GO-2025-3503
  - GHSA-cpwx-vrp4-4pq7
  - CVE-2025-27516
    minseveritystring

“minseverity” defines the minimum severity of the vulnerabilities to account for.

remark:

  • accepted values are “LOW”, “MODERATE”, “HIGH” and “CRITICAL”, in any case.
  • “MEDIUM” is accepted as an alias of “MODERATE”.
  • the severity comes from GitHub advisories. Vulnerabilities without one are always accounted for.

example:

  • minseverity: HIGH
    strategystring

“strategy” defines the version a vulnerable dependency is updated to.

default: lowest

remark:

  • the only accepted value is “lowest”: the lowest version without known vulnerabilities.
  • the value is case insensitive.
    urlstring

“url” defines the OSV API URL.

default: https://api.osv.dev

⚠ This table is generated from the Updatecli codebase and may contain inaccurate data. Feel free to report them on github.com/updatecli/updatecli
Note
Within a single only/ignore rule, path and packages must both match (AND); separate rules are combined with OR. A package version in a rule is a PEP 440 specifier evaluated against the version number extracted from the dependency’s constraint, for example 2.28 for requests>=2.28. An empty value matches any version.

Example

Basic Example

# updatecli.d/pyproject.yaml
autodiscovery:
  crawlers:
    pyproject:
      rootdir: "."
      versionfilter:
        kind: semver
        pattern: minor

Filter to Specific Packages

# updatecli.d/pyproject-only.yaml
autodiscovery:
  crawlers:
    pyproject:
      only:
        - packages:
            "requests": ""
            "flask": ""

Private PyPI Registry

# updatecli.d/pyproject-private.yaml
autodiscovery:
  crawlers:
    pyproject:
      rootdir: "."
      # Custom PyPI index URL propagated to all generated pypi source specs
      indexurl: "https://pypi.example.com/"
Note
The indexurl parameter is propagated as the url field of every generated pypi source, allowing consistent registry configuration across all discovered dependencies. It does not carry credentials: the crawler has no token parameter, so an authenticated registry requires adding the pypi resource token field to the generated manifests by hand. The uv lock target relies on `uv’s own index configuration.
Note
The alias python/uv can also be used instead of pyproject.