Install hook fails to find a match poetry-core

Bug #1993228 reported by DUFOUR Olivier
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Router Charm
Fix Committed
Undecided
DUFOUR Olivier

Bug Description

When building a charm from master branch of mysql-router's charm, we're greeted with an install hook failure on both Focal and Jammy deployments.

This looks identical to #1989327 (Mysql-innodb-cluster charm) and #1989669 (Neutron api OVN plugin charm)

Add poetry-core to the wheelhouse.txt fix the issue as tested on both Focal and Jammy deployment.

Here some logs of the install hook error :
2022-10-18 03:00:42 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Installing build dependencies: finished with status 'done'
2022-10-18 03:00:42 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Getting requirements to build wheel: started
2022-10-18 03:00:43 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Getting requirements to build wheel: finished with status 'done'
2022-10-18 03:00:43 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Preparing metadata (pyproject.toml): started
2022-10-18 03:00:44 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Preparing metadata (pyproject.toml): finished with status 'done'
2022-10-18 03:00:44 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Processing ./wheelhouse/dnspython-2.2.1.tar.gz
2022-10-18 03:00:44 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Installing build dependencies: started
2022-10-18 03:00:45 DEBUG unit.faulty-mysql-router/0.install logger.go:60 Installing build dependencies: finished with status 'error'
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 error: subprocess-exited-with-error
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 × pip subprocess to install build dependencies did not run successfully.
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 │ exit code: 1
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 ╰─> [3 lines of output]
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 Looking in links: wheelhouse
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 ERROR: Could not find a version that satisfies the requirement poetry-core (from versions: none)
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 ERROR: No matching distribution found for poetry-core
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 [end of output]
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 note: This error originates from a subprocess, and is likely not a problem with pip.
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 error: subprocess-exited-with-error
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 × pip subprocess to install build dependencies did not run successfully.
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 │ exit code: 1
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 ╰─> See above for output.
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 note: This error originates from a subprocess, and is likely not a problem with pip.
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 Traceback (most recent call last):
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 File "/var/lib/juju/agents/unit-faulty-mysql-router-0/charm/hooks/install", line 8, in <module>
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 basic.bootstrap_charm_deps()
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 File "/var/lib/juju/agents/unit-faulty-mysql-router-0/charm/lib/charms/layer/basic.py", line 226, in bootstrap_charm_deps
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 check_call([pip, 'install', '-U', reinstall_flag, '--no-index',
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 File "/usr/lib/python3.10/subprocess.py", line 369, in check_call
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 raise CalledProcessError(retcode, cmd)
2022-10-18 03:00:45 WARNING unit.faulty-mysql-router/0.install logger.go:60 subprocess.CalledProcessError: Command '['/var/lib/juju/agents/unit-faulty-mysql-router-0/.venv/bin/pip', 'install', '-U', '--force-reinstall', '--no-index', '--no-cache-dir', '-f', 'wheelhouse', 'flit-core==3.7.1', 'pyparsing==3.0.9', 'charms.reactive==1.5.1', 'netifaces==0.11.0', 'pyaml==21.10.1', 'charms.openstack==0.0.1.dev1', 'PyYAML==5.3.1', 'six==1.16.0', 'tenacity==7.0.0', 'Jinja2==3.1.2', 'tomli==2.0.1', 'mysqlclient==2.1.1', 'psutil==5.9.2', 'packaging==21.3', 'dnspython==2.2.1', 'charmhelpers==1.1.1.dev44', 'pbr==5.10.0', 'netaddr==0.7.19']' returned non-zero exit status 1.
2022-10-18 03:00:45 ERROR juju.worker.uniter.operation runhook.go:140 hook "install" (via explicit, bespoke hook script) failed: exit status 1
2022-10-18 03:00:45 DEBUG juju.machinelock machinelock.go:202 created rotating log file "/var/log/juju/machine-lock.log" with max size 10 MB and max backups 5
2022-10-18 03:00:45 DEBUG juju.machinelock machinelock.go:186 machine lock released for faulty-mysql-router/0 uniter (run install hook)
2022-10-18 03:00:45 DEBUG juju.worker.uniter.operation executor.go:115 lock released for faulty-mysql-router/0
2022-10-18 03:00:45 INFO juju.worker.uniter resolver.go:145 awaiting error resolution for "install" hook
2022-10-18 03:00:45 DEBUG juju.worker.uniter agent.go:20 [AGENT-STATUS] error: hook failed: "install"

Changed in charm-mysql-router:
assignee: nobody → DUFOUR Olivier (odufourc)
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to charm-mysql-router (master)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to charm-mysql-router (master)

Reviewed: https://review.opendev.org/c/openstack/charm-mysql-router/+/861689
Committed: https://opendev.org/openstack/charm-mysql-router/commit/2b73548263317abe3441a1ab559426529fecec04
Submitter: "Zuul (22348)"
Branch: master

commit 2b73548263317abe3441a1ab559426529fecec04
Author: Olivier Dufour-Cuvillier <email address hidden>
Date: Tue Oct 18 12:11:12 2022 +0900

    fix wheelhouse with the addition of poetry-core

    Install hook would fail with pip install dns-python requiring poetry-core
    Closes-Bug: #1993228

    Change-Id: I6ac158c852253fca300f6b2d2cbad7b8b4906d27

Changed in charm-mysql-router:
status: In Progress → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.