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

FunctionIds must start with a lowercase letter #3621

Closed
rswlkr opened this issue Aug 16, 2022 · 3 comments
Closed

FunctionIds must start with a lowercase letter #3621

rswlkr opened this issue Aug 16, 2022 · 3 comments
Assignees
Labels
api: cloudfunctions Issues related to the Cloud Run functions API. samples Issues that are directly related to samples.

Comments

@rswlkr
Copy link

rswlkr commented Aug 16, 2022

Environment details

  • OS: macOS 12.1
  • Node.js version: 16.14.0
  • npm version: 8.3.1
  • @google-cloud/functions version: 2.2.0 (V2)

Steps to reproduce

  1. Try to create a function that has a functionId above 4 characters and starting with a non-lowercase letter or a number i.e 62fbb0ce81ac165156e08914 (with this client lib or the rest API).

This will return:

'Invalid Request. Violations: {Violation in Function.name=Invalid function_id. Can only contain [-_a-zA-Z0-9] and be between 4-63 characters.}'

Irrespective of the reason for the requirement it would useful if there was guidance here to indicate it...updating the regex perhaps..?

@rswlkr rswlkr added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Aug 16, 2022
@product-auto-label product-auto-label bot added the api: cloudfunctions Issues related to the Cloud Run functions API. label Aug 16, 2022
@pattishin pattishin self-assigned this Aug 18, 2022
@pattishin
Copy link
Contributor

Hi @rswlkr,
Thanks so much for creating the issue! Just to make sure we understand the ask,
is the request to have this aired in the README, besides guidance within the comments in the code, like so:
https://github.com/googleapis/nodejs-functions/blob/main/src/v2/function_service_client.ts#L852

@rswlkr
Copy link
Author

rswlkr commented Aug 19, 2022

Hello @pattishin - the comments need updated so that the regex is correct or at least the requirement for starting with a lowercase letter stated.

@sofisl sofisl added samples Issues that are directly related to samples. and removed type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. priority: p2 Moderately-important priority. Fix may not be included in next release. labels Nov 11, 2022
@sofisl sofisl transferred this issue from googleapis/nodejs-functions Nov 12, 2022
@sofisl
Copy link
Contributor

sofisl commented Dec 22, 2022

@pattishin, I will move this over to nodejs-docs-samples, since it seems like the comments are referring to the samples. Let me know if you disagree, we can reopen over here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: cloudfunctions Issues related to the Cloud Run functions API. samples Issues that are directly related to samples.
Projects
None yet
Development

No branches or pull requests

3 participants