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

[doc] What happens when timeout period in Container.exec() elapses? #1131

Closed
sed-i opened this issue Feb 15, 2024 · 4 comments
Closed

[doc] What happens when timeout period in Container.exec() elapses? #1131

sed-i opened this issue Feb 15, 2024 · 4 comments
Assignees
Labels
docs Improvements or additions to documentation small item

Comments

@sed-i
Copy link
Contributor

sed-i commented Feb 15, 2024

ops.model and ops.pebble don't specify what happens when timeout is elapsed.
Context: canonical/alertmanager-k8s-operator#218

operator/ops/model.py

Lines 2711 to 2712 in 1836df5

Raises:
ExecError: if the command exits with a non-zero exit code.

operator/ops/pebble.py

Lines 2526 to 2528 in 1836df5

timeout: Timeout in seconds for the command execution, after which
the process will be terminated. If not specified, the
execution never times out.

@tonyandrewmeyer
Copy link
Contributor

See also #826

@tonyandrewmeyer tonyandrewmeyer added docs Improvements or additions to documentation small item labels Feb 15, 2024
@sed-i
Copy link
Contributor Author

sed-i commented Feb 16, 2024

Also: #867

@sed-i
Copy link
Contributor Author

sed-i commented Mar 21, 2024

Potentially related: container.exec also leaks http.client.RemoteDisconnected, as can be seen here: canonical/cos-lite-bundle#103

@IronCore864
Copy link
Contributor

We decided against putting Raises TimeoutError in these methods, because they really need to go in all of them, so there's the note in the class docstring instead.

See discussion here.

Close now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to documentation small item
Projects
None yet
Development

No branches or pull requests

3 participants