Dependabot uv job times out and tries to update workspace members

Offen
#7,457 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 3 Tagen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
45/100
Issue-Typ
Bug
Klarheit
Größtenteils klar
Aktivitätsstatus
Aktiv
Tech-Stack
github-actions, python, yaml
Bereich
build-system, devops

Rechercherichtung

Start by reading .github/dependabot.yml and the root pyproject.toml workspace configuration; the linked Dependabot run shows the failure and timeout. Compare the two proposed approaches: renaming internal distributions or generating and validating the ignore list. Done means Dependabot skips workspace members and the weekly uv update completes without timing out.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

The weekly Dependabot uv update for / has been timing out or failing since early November (e.g. https://github.com/mozilla/bugbug/network/updates/1694419512).

Two causes:

  1. Dependabot treats uv workspace members as PyPI packages. testrail-client exists on PyPI (0.1.2), so Dependabot tries to "update" our 0.1.0 workspace member and fails with dependency_file_not_resolvable. Same for agent-tools. Dependabot does not honor { workspace = true } sources, even when declared in the root pyproject.toml.
  2. The job is right at the ~55 min timeout. Each check re-resolves the whole workspace (~16s each) and a run does 200-250 checks; ~30 of those are on workspace members, which we never want updated.

Ignoring the workspace members in .github/dependabot.yml fixes both, but an explicit list of names would have to be kept in sync manually as members are added. Options to avoid that:

Option 1: rename internal packages under a common prefix

Most members are already hackbot-*. Rename the remaining ones (agent-tools, autowebcompat-tools, bugzilla-client, lando-client, phabricator-client, phabricator-proxy, testrail-client) to e.g. hackbot-agent-tools, hackbot-testrail-client, ... so the ignore block becomes a fixed pair of wildcards:

ignore:
  - dependency-name: "hackbot-*"
  - dependency-name: "bugbug*"

Only distribution names change (pyproject.toml files and uv.lock); import names like testrail_client stay the same. It also removes a dependency-confusion risk: anything installing these outside the workspace (Docker builds, plain pip install) could currently pull an unrelated package from PyPI.

Option 2: generate the ignore list automatically

Add a pre-commit hook that reads the workspace member names and rewrites (or validates) the ignore block in dependabot.yml. No renames needed, but it adds a script to maintain and the PyPI name collisions remain.

Vorherrschende Sprache
Python
Sterne
579
Forks
369
Ø Merge
3 T. 5 Std.
Gemergte PRs (30 T.)
139

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus mozilla/bugbug

Alle Issues in mozilla/bugbug

Ähnliche Issues

Weitere Issues zu Python

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.