Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix mysql-operator charm test now that it uses Poetry for deps #987

Closed
benhoyt opened this issue Aug 3, 2023 · 1 comment · Fixed by #1013
Closed

Fix mysql-operator charm test now that it uses Poetry for deps #987

benhoyt opened this issue Aug 3, 2023 · 1 comment · Fixed by #1013
Assignees

Comments

@benhoyt
Copy link
Collaborator

benhoyt commented Aug 3, 2023

The mysql-operator tests are failing since canonical/mysql-operator#192 was merged, which removes the requirements.txt file from that repo and puts dependencies in pyproject.toml. Presumably they'll be doing the same with the other db charms soon too, so we need to find a workaround. Example failure:

> sed -i -e "/^ops[ ><=]/d" -e "/canonical\/operator/d" -e "/#egg=ops/d" requirements.txt
> echo -e "\ngit+$GITHUB_SERVER_URL/$GITHUB_REPOSITORY@$GITHUB_SHA#egg=ops" >> requirements.txt
> shell: /usr/bin/bash -e {0}
sed: can't read requirements.txt: No such file or directory
benhoyt added a commit to benhoyt/operator that referenced this issue Aug 3, 2023
They're failing due to the charm's removal of requirements.txt. See:
canonical#987
@benhoyt
Copy link
Collaborator Author

benhoyt commented Aug 11, 2023

mysql-k8s-operator just started failing for the same reason.

benhoyt added a commit that referenced this issue Aug 16, 2023
@tonyandrewmeyer tonyandrewmeyer self-assigned this Sep 26, 2023
benhoyt pushed a commit that referenced this issue Sep 27, 2023
* Only try to edit `requirements.txt` if it exists
* If `requirements.txt` does not exist, then assume that the requirement is in `pyproject.toml` and edit that instead
* Enable the integration tests with `mysql-operator` and `mysql-k8s-operator` again
* Remove the `static-charm` tox runs from the DB workflow, as none of the DB operators have one defined
* Pin `tox` to anything compatible with 4.2

Fixes #987.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants