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

Incorrect sample for RecaptchaEnterprise #605

Open
saranshdhingra opened this issue Mar 28, 2023 · 3 comments
Open

Incorrect sample for RecaptchaEnterprise #605

saranshdhingra opened this issue Mar 28, 2023 · 3 comments
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. samples Issues that are directly related to samples. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@saranshdhingra
Copy link
Contributor

Original Issue: google-cloud-php link

Hi, the example for recaptcha enterprise account defender related groups feature is non functional, seems the generation of the example just needs a tweak

Example given https://github.com/googleapis/google-cloud-php-recaptcha-
enterprise/blob/main/samples/V1/RecaptchaEnterpriseServiceClient/search_related_account_group_memberships.php#L71

This example uses the function https://github.com/googleapis/google-cloud-php-recaptcha-enterprise/blob/main/src/V1/Gapic/RecaptchaEnterpriseServiceGapicClient.php#L288

This should be a project name and hashed account ID ( passed as an array of optional arguments) as defined here

https://github.com/googleapis/google-cloud-php-recaptcha-enterprise/blob/main/src/V1/Gapic/RecaptchaEnterpriseServiceGapicClient.php#L1120

@saranshdhingra saranshdhingra added 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 Mar 28, 2023
@product-auto-label product-auto-label bot added the samples Issues that are directly related to samples. label Mar 28, 2023
@noahdietz
Copy link
Collaborator

noahdietz commented Mar 28, 2023

The links are main relative so it doesn't point to the exact spot anymore.

@saranshdhingra your comment sheds some light though:

I think that makes sense. The sample and the snippet both use the fomattedParent as projects/{project}/relatedaccountgroups/{relatedaccountgroup} while the method expects projects/{project}.

@noahdietz
Copy link
Collaborator

These links would have been for tag 1.2.6

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p2 Moderately-important priority. Fix may not be included in next release. samples Issues that are directly related to samples. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

3 participants