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

docs: add note to set_results about maximum size #1047

Merged
merged 1 commit into from
Oct 15, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions ops/charm.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,11 @@ def set_results(self, results: Dict[str, Any]):
alphanumeric, and can only contain lowercase alphanumeric, hyphens
and periods.

Because results are passed to Juju using the command line, the maximum
size is around 100KB. However, actions results are designed to be
small: a few key-value pairs shown in the Juju CLI. If larger content
is needed, store it in a file and use something like ``juju scp``.

If any exceptions occur whilst the action is being handled, juju will
gather any stdout/stderr data (and the return code) and inject them into the
results object. Thus, the results object might contain the following keys,
Expand Down
Loading