Skip to content

bug(deploy): backend requirements declare openpyxl and python-pptx twice with different floors, so pip aborts provisioning #14228

Closed

Description

@mrveiss

Hit on a live /opt/autobot provisioning run, immediately after #14226 unblocked the SSH task.

The failure

TASK [backend : Install filtered backend requirements] ***
fatal: [node_00_SLM_Manager]: FAILED! =>
  ERROR: Double requirement given: openpyxl>=3.1.5
  (from -r /opt/autobot/code_source/requirements.txt (line 25))
  (already in openpyxl>=3.1.0 (from -r /tmp/requirements-filtered.txt (line 30)), name='openpyxl')

Root cause

autobot-backend/requirements.txt declares two packages that the root requirements.txt also declares, with different floors — and it pulls the root file in at line 62 via -r ../requirements.txt:

package autobot-backend/requirements.txt root requirements.txt
openpyxl >=3.1.0 (line 31) >=3.1.5 (line 25)
python-pptx >=0.6.23 (line 32) >=1.0.2 (line 26)

pip refuses when the same distribution arrives twice with different specifiers.

Why it surfaced now rather than earlier

scripts/build-filtered-requirements.sh rewrites the relative -r ../requirements.txt to an absolute code_source path so the include actually resolves (#11134, #11117, #11135). Before that rewrite the include did not resolve, so the root file's pins never reached pip and the duplicate never materialised. The include fix is correct; it exposed a latent conflict rather than causing one.

The next failure is already queued behind this one

pip reports only the first duplicate. Enumerating both files by parsing them:

packages declared in BOTH files: 6
  same spec   aiosqlite     backend:22   >=0.22.1          root:48  >=0.22.1
  same spec   defusedxml    backend:117  >=0.7.1           root:52  >=0.7.1
  DIFFERENT   openpyxl      backend:31   >=3.1.0           root:25  >=3.1.5
  same spec   protobuf      backend:39   >=7.35.1,<8.0.0   root:12  >=7.35.1,<8.0.0
  same spec   python-docx   backend:26   >=1.2.0           root:24  >=1.2.0
  DIFFERENT   python-pptx   backend:32   >=0.6.23          root:26  >=1.0.2

So fixing openpyxl alone moves the failure to python-pptx on the next run. Both must go in one change, or the deploy fails twice.

The four identical duplicates are tolerated by pip — aiosqlite (backend line 22) precedes openpyxl (line 31) and did not error, which is what establishes that pip only rejects differing specifiers. They are redundant but not breaking, and are deliberately left alone here.

Suggested fix

Drop the two weaker declarations from autobot-backend/requirements.txt. The root file is included anyway and carries the stricter floor in both cases, so the dependency is preserved and the constraint tightens rather than loosens.

Acceptance criteria

  • openpyxl and python-pptx are declared once across the two files
  • A guard detects a package declared in both with differing specifiers, mutation-verified by reintroducing one
  • Evidence is a provisioning run reaching past Install filtered backend requirements, not a diff — this is host behaviour

Related

Activity

  1. github-actions commented on Aug 14, 2026

    @github-actions
    Contributor

    PR #14230 (merged to Dev_new_gui) references this issue with a close keyword.

    fix(deploy): drop the two conflicting requirement pins that abort pip on provisioning (#14228)

    If this issue is fully resolved, close it manually. If work remains, no action is needed.

  2. mrveiss commented on Aug 15, 2026

    @mrveiss
    OwnerAuthor

    Closing — verified on the live host

    PR #14230 merged and applied; code_source is at 4a5044764.

    Host evidence:

    code_source/autobot-backend/requirements.txt   openpyxl/python-pptx declarations: 0
    autobot-backend                                 active
    backend venv site-packages: openpyxl installed, pptx installed
    

    Both packages are present, so removing the duplicate declarations tightened rather than loosened
    the constraint — the root file's floors (openpyxl>=3.1.5, python-pptx>=1.0.2) are what applies,
    and the OneDrive connector's parsers still install.

    The abort this issue was filed for:

    ERROR: Double requirement given: openpyxl>=3.1.5 ... (already in openpyxl>=3.1.0 ...)
    

    required the same distribution to arrive twice with differing specifiers. It does not any more,
    and check_requirements_no_conflicting_dupes.py guards the whole include closure rather than
    adjacent file pairs — the narrower version would not have seen a conflict two hops apart, which is
    the shape requirements-dev.txt already has.

    Worth recording

    pip reports only the first conflict, so fixing openpyxl alone would have moved the failure to
    python-pptx on the next run. Both were removed together for that reason, and the guard reports
    all of them at once.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions