Skip to content

[gemini-agent-eval-api] #2001

@manojbejawada

Description

@manojbejawada

Description

When running the gcloud services enable setup script via line-break backslashes (\), an accidental trailing space at the end of a line (specifically after servicenetworking.googleapis.com \ ) causes the shell interpreter to execute the command prematurely.

This results in a blank service string being sent to the Google Cloud API, triggering a SERVICE_CONFIG_NOT_FOUND_OR_PERMISSION_DENIED error, and causes the subsequent line (aiplatform.googleapis.com) to be evaluated as a standalone bash command (resulting in command not found).


Steps to Reproduce

  1. Open Cloud Shell in a Google Cloud project.
  2. Copy and paste the following multi-line command exactly as written (note the trailing space after the backslash on the servicenetworking line):
gcloud services enable \
  alloydb.googleapis.com \
  bigquery.googleapis.com \
  run.googleapis.com \
  cloudbuild.googleapis.com \
  artifactregistry.googleapis.com \
  iam.googleapis.com \
  secretmanager.googleapis.com \
  compute.googleapis.com \
  servicenetworking.googleapis.com \ 
  aiplatform.googleapis.com
Expected Result
All 10 listed APIs should be enabled successfully.

Actual Result
The command fails with the following errors:

Plaintext
ERROR: (gcloud.services.enable) [...] Not found or permission denied for service(s):  .
...
reason: SERVICE_CONFIG_NOT_FOUND_OR_PERMISSION_DENIED
bash: aiplatform.googleapis.com: command not found
Suggested Fix
Update the Codelab/README documentation to use a clean, single-line string for the setup command to eliminate line-break parsing bugs:

Bash
gcloud services enable alloydb.googleapis.com bigquery.googleapis.com run.googleapis.com cloudbuild.googleapis.com artifactregistry.googleapis.com iam.googleapis.com secretmanager.googleapis.com compute.googleapis.com servicenetworking.googleapis.com aiplatform.googleapis.com

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions