admin管理员组文章数量:1418042
I am trying to create cloud functions using my existing scripts
I run commands as shown below to create a cloud function <my_function>
"gcloud functions deploy <my_function> --no-gen2 --region=us-central1 -
-entry-point=handle_event --memory=256MB --retry --runtime=python310 --
source=gs://<mybucket>/<myfunction.zip> --
timeout=30 --trigger-topic=<my pubsub> --set-env-vars=MYSQL_USER=<myuser>,MYSQL_PASSWORD=<mypass>,MYSQL_DATABASE=<mydb>,INSTANCE_CONNECTION_NAME=<myproject>:us-central1:<mydb>" --build-service-account=<mybuildservice account>
When I run this command I get an error "ERROR: gcloud crashed (TypeError): expected string or bytes-like object, got 'NoneType'"
gcloud does not throw any more information
I am stuck ; please help me resolve this error
I am trying to create cloud functions using my existing scripts
I run commands as shown below to create a cloud function <my_function>
"gcloud functions deploy <my_function> --no-gen2 --region=us-central1 -
-entry-point=handle_event --memory=256MB --retry --runtime=python310 --
source=gs://<mybucket>/<myfunction.zip> --
timeout=30 --trigger-topic=<my pubsub> --set-env-vars=MYSQL_USER=<myuser>,MYSQL_PASSWORD=<mypass>,MYSQL_DATABASE=<mydb>,INSTANCE_CONNECTION_NAME=<myproject>:us-central1:<mydb>" --build-service-account=<mybuildservice account>
When I run this command I get an error "ERROR: gcloud crashed (TypeError): expected string or bytes-like object, got 'NoneType'"
gcloud does not throw any more information
I am stuck ; please help me resolve this error
Share Improve this question asked Jan 31 at 7:34 Yogesh DeviYogesh Devi 70914 silver badges35 bronze badges1 Answer
Reset to default 0I ran the same command with verbosity set to debug as follows
enter code here
"gcloud functions deploy <my_function> --no-gen2 --region=us-central1 -
-entry-point=handle_event --memory=256MB --retry --runtime=python310 --
source=gs://<mybucket>/<myfunction.zip> --
timeout=30 --trigger-topic=<my pubsub> --set-env-vars=MYSQL_USER=
<myuser>,MYSQL_PASSWORD=<mypass>,MYSQL_DATABASE=
<mydb>,INSTANCE_CONNECTION_NAME=<myproject>:us-central1:<mydb>" --build-service-account=<mybuildservice account> --verbosity=debug
And that gave me a exact problem behind error "please provide the build service account in the format projects/[project_id]/serviceaccounts/[service_account_email]
]"
I was giving just the service account e-mail
After I corrected that to needed format the error went away
本文标签:
版权声明:本文标题:Google "gcloud functions deploy" command gives error gcloud crashed (TypeError): expected string or bytes-like 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745276211a2651203.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论