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

retries hide legitimate errors in Model.connect() #452

Closed
samuelallan72 opened this issue Jun 25, 2024 · 1 comment · Fixed by #531
Closed

retries hide legitimate errors in Model.connect() #452

samuelallan72 opened this issue Jun 25, 2024 · 1 comment · Fixed by #531

Comments

@samuelallan72
Copy link
Contributor

I had an issue with cou hanging on connect. I removed the retry logic and then it crashed with this error:

juju.errors.JujuConnectionError: juju server-version 3.4.2 not supported

We shouldn't retry on these kind of hard errors.

@samuelallan72
Copy link
Contributor Author

Note a concrete example is that currently running cou plan with a model deployed with an incompatible juju version results in a generic connection error:

$ cou plan
Full execution log: '/home/ubuntu/.local/share/cou/log/cou-20240625053441.log'
Connecting to 'admin/openstack' model... ✖
The connection was lost. Check your connection or increase the timeout.

But removing the retry logic results in a more useful error like:

2024-06-25 05:35:21 [ERROR] Error occurred in Juju's Python library.
2024-06-25 05:35:21 [ERROR] juju server-version 3.4.2 not supported

Perhaps this is a separate issue, but cou really should output a better error when running against an incompatible juju version.

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

Successfully merging a pull request may close this issue.

1 participant