-
Notifications
You must be signed in to change notification settings - Fork 2.4k
fix: Correct help text formatting for adk deploy agent_engine
#1250
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
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The `Args:` section in the docstring of the `cli_deploy_agent_engine` function was causing formatting issues in the help output, with line breaks not being rendered correctly. This commit removes the redundant `Args:` section from the docstring. The help text for options is already comprehensively covered by the `help` attributes in the `@click.option` decorators, and `click` automatically lists the command's arguments. This change ensures that the help output for `adk deploy agent_engine --help` is clean, readable, and correctly formatted, relying on `click`'s standard help generation mechanisms.
Collaborator
Author
|
Click tools doesn't render line break for each line in the docstring. So to add a line break, a new line need to be placed between args. However, we already have help text for each options so we should remove those redundant doc string. Click args, by design or follow unix convention, doesn't have help text and should be documented in the docstring instead. |
adk deploy agent_engineadk deploy agent_engine
Jacksunwei
approved these changes
Jun 9, 2025
copybara-service bot
pushed a commit
that referenced
this pull request
Jun 9, 2025
Merge #1250 The `Args:` section in the docstring of the `cli_deploy_agent_engine` function was causing formatting issues in the help output, with line breaks not being rendered correctly. This commit removes the redundant `Args:` section from the docstring. The help text for options is already comprehensively covered by the `help` attributes in the `@click.option` decorators, and `click` automatically lists the command's arguments. This change ensures that the help output for `adk deploy agent_engine --help` is clean, readable, and correctly formatted, relying on `click`'s standard help generation mechanisms. After the fix: (adk_test234) (base) hangfeilin@Hangfeis-MBP adk-python % adk deploy agent_engine --help Usage: adk deploy agent_engine [OPTIONS] AGENT Deploys an agent to Agent Engine. Args: agent (str): Required. The path to the agent to be deloyed. Example: adk deploy agent_engine --project=[project] --region=[region] --staging_bucket=[staging_bucket] path/to/my_agent Options: --project TEXT Required. Google Cloud project to deploy the agent. --region TEXT Required. Google Cloud region to deploy the agent. --staging_bucket TEXT Required. GCS bucket for staging the deployment artifacts. --trace_to_cloud Optional. Whether to enable Cloud Trace for Agent Engine. --adk_app TEXT Optional. Python file for defining the ADK application (default: a file named agent_engine_app.py) --temp_folder TEXT Optional. Temp folder for the generated Agent Engine source files. If the folder already exists, its contents will be removed. (default: a timestamped folder in the system temp directory). --env_file TEXT Optional. The filepath to the `.env` file for environment variables. (default: the `.env` file in the `agent` directory, if any.) --requirements_file TEXT Optional. The filepath to the `requirements.txt` file to use. (default: the `requirements.txt` file in the `agent` directory, if any.) --help Show this message and exit. COPYBARA_INTEGRATE_REVIEW=#1250 from google:fix-1191-agent-engine-help d2d0e89 PiperOrigin-RevId: 769182740
coder-aditi
pushed a commit
to coder-aditi/adk-python
that referenced
this pull request
Jul 2, 2025
Merge google#1250 The `Args:` section in the docstring of the `cli_deploy_agent_engine` function was causing formatting issues in the help output, with line breaks not being rendered correctly. This commit removes the redundant `Args:` section from the docstring. The help text for options is already comprehensively covered by the `help` attributes in the `@click.option` decorators, and `click` automatically lists the command's arguments. This change ensures that the help output for `adk deploy agent_engine --help` is clean, readable, and correctly formatted, relying on `click`'s standard help generation mechanisms. After the fix: (adk_test234) (base) hangfeilin@Hangfeis-MBP adk-python % adk deploy agent_engine --help Usage: adk deploy agent_engine [OPTIONS] AGENT Deploys an agent to Agent Engine. Args: agent (str): Required. The path to the agent to be deloyed. Example: adk deploy agent_engine --project=[project] --region=[region] --staging_bucket=[staging_bucket] path/to/my_agent Options: --project TEXT Required. Google Cloud project to deploy the agent. --region TEXT Required. Google Cloud region to deploy the agent. --staging_bucket TEXT Required. GCS bucket for staging the deployment artifacts. --trace_to_cloud Optional. Whether to enable Cloud Trace for Agent Engine. --adk_app TEXT Optional. Python file for defining the ADK application (default: a file named agent_engine_app.py) --temp_folder TEXT Optional. Temp folder for the generated Agent Engine source files. If the folder already exists, its contents will be removed. (default: a timestamped folder in the system temp directory). --env_file TEXT Optional. The filepath to the `.env` file for environment variables. (default: the `.env` file in the `agent` directory, if any.) --requirements_file TEXT Optional. The filepath to the `requirements.txt` file to use. (default: the `requirements.txt` file in the `agent` directory, if any.) --help Show this message and exit. COPYBARA_INTEGRATE_REVIEW=google#1250 from google:fix-1191-agent-engine-help d2d0e89 PiperOrigin-RevId: 769182740
seanzhou1023
pushed a commit
to soundTricker/adk-python
that referenced
this pull request
Jul 11, 2025
Merge google#1250 The `Args:` section in the docstring of the `cli_deploy_agent_engine` function was causing formatting issues in the help output, with line breaks not being rendered correctly. This commit removes the redundant `Args:` section from the docstring. The help text for options is already comprehensively covered by the `help` attributes in the `@click.option` decorators, and `click` automatically lists the command's arguments. This change ensures that the help output for `adk deploy agent_engine --help` is clean, readable, and correctly formatted, relying on `click`'s standard help generation mechanisms. After the fix: (adk_test234) (base) hangfeilin@Hangfeis-MBP adk-python % adk deploy agent_engine --help Usage: adk deploy agent_engine [OPTIONS] AGENT Deploys an agent to Agent Engine. Args: agent (str): Required. The path to the agent to be deloyed. Example: adk deploy agent_engine --project=[project] --region=[region] --staging_bucket=[staging_bucket] path/to/my_agent Options: --project TEXT Required. Google Cloud project to deploy the agent. --region TEXT Required. Google Cloud region to deploy the agent. --staging_bucket TEXT Required. GCS bucket for staging the deployment artifacts. --trace_to_cloud Optional. Whether to enable Cloud Trace for Agent Engine. --adk_app TEXT Optional. Python file for defining the ADK application (default: a file named agent_engine_app.py) --temp_folder TEXT Optional. Temp folder for the generated Agent Engine source files. If the folder already exists, its contents will be removed. (default: a timestamped folder in the system temp directory). --env_file TEXT Optional. The filepath to the `.env` file for environment variables. (default: the `.env` file in the `agent` directory, if any.) --requirements_file TEXT Optional. The filepath to the `requirements.txt` file to use. (default: the `requirements.txt` file in the `agent` directory, if any.) --help Show this message and exit. COPYBARA_INTEGRATE_REVIEW=google#1250 from google:fix-1191-agent-engine-help d2d0e89 PiperOrigin-RevId: 769182740
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The
Args:section in the docstring of thecli_deploy_agent_enginefunction was causing formatting issues in the help output, with line breaks not being rendered correctly.This commit removes the redundant
Args:section from the docstring. The help text for options is already comprehensively covered by thehelpattributes in the@click.optiondecorators, andclickautomatically lists the command's arguments.This change ensures that the help output for
adk deploy agent_engine --helpis clean, readable, and correctly formatted, relying onclick's standard help generation mechanisms.After the fix:
(adk_test234) (base) hangfeilin@Hangfeis-MBP adk-python % adk deploy agent_engine --help
Usage: adk deploy agent_engine [OPTIONS] AGENT
Deploys an agent to Agent Engine.
Args: agent (str): Required. The path to the agent to be deloyed.
Example:
Options:
--project TEXT Required. Google Cloud project to deploy the agent.
--region TEXT Required. Google Cloud region to deploy the agent.
--staging_bucket TEXT Required. GCS bucket for staging the deployment artifacts.
--trace_to_cloud Optional. Whether to enable Cloud Trace for Agent Engine.
--adk_app TEXT Optional. Python file for defining the ADK application (default: a file named agent_engine_app.py)
--temp_folder TEXT Optional. Temp folder for the generated Agent Engine source files. If the folder already exists, its
contents will be removed. (default: a timestamped folder in the system temp directory).
--env_file TEXT Optional. The filepath to the
.envfile for environment variables. (default: the.envfile inthe
agentdirectory, if any.)--requirements_file TEXT Optional. The filepath to the
requirements.txtfile to use. (default: therequirements.txtfilein the
agentdirectory, if any.)--help Show this message and exit.