Skip to content

docs(models): name the step argument the helper actually takes - #8060

Open
lxcxjxhx wants to merge 6 commits into
google:mainfrom
lxcxjxhx:docs/interactions-utils-step-arg
Open

lxcxjxhx wants to merge 6 commits into
google:mainfrom
lxcxjxhx:docs/interactions-utils-step-arg

Conversation

@lxcxjxhx

@lxcxjxhx lxcxjxhx commented Nov 9, 2026

Copy link
Copy Markdown

Link to Issue or Description of Change

1. Link to an existing issue (if applicable):

  • No issue; single-line documentation correction, described below.

2. Or, if no issue exists, describe the change:

Problem:

_convert_interaction_step_to_parts (src/google/adk/models/interactions_utils.py:758) documents a parameter it does not take:

def _convert_interaction_step_to_parts(step: Step) -> list[types.Part]:
  """Convert an interaction output content to a list of types.Part.

  Args:
    output: The interaction output object to convert.

The parameter is step: Step. The Args: entry is left over from a signature that took the interaction output; the body now branches on ModelOutputStep and its content items, so a reader looking for output finds nothing, and the summary's "interaction output content" points at the wrong intermediate type as well.

Solution:

Rename the entry to step and describe what the function actually receives:

  Args:
    step: The interaction step to convert.

One file, +1/−1, no code touched. I left the summary sentence alone: "Convert an interaction output content to a list of types.Part" describes the result accurately enough, and rewording it would make this a two-purpose diff.

Verification:

  • ruff==0.15.17 check on the file: All checks passed!
  • pyink==25.12 --check on the file: 1 file would be left unchanged (this repository formats with pyink; ruff format would reformat the file both before and after this change, so it is not the formatting gate here).
  • No behaviour change, so no test: the diff is one docstring line.

On the CLA: I have read CONTRIBUTING.md; the Google CLA check on this PR will stay pending until the account holder signs it at cla.developers.google.com. Flagging it rather than leaving you to discover it — the code change itself is complete.

Additional context

Found by parsing the tree with ast and comparing every Args: entry against the real signature (positional-only, keyword-only, *args and **kwargs included). In src/google/adk, this is the only remaining entry that names something the signature does not accept — the two others under tools/openapi_tool/ are already the subject of #8026, so I did not touch them.

_convert_interaction_step_to_parts documents an output parameter; the signature takes step: Step and the body branches on ModelOutputStep.
@google-cla

google-cla Bot commented Nov 9, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

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 this pull request may close these issues.

1 participant