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

GADS_SSI error #166

Open
jbrs360 opened this issue May 15, 2024 · 27 comments · Fixed by #169
Open

GADS_SSI error #166

jbrs360 opened this issue May 15, 2024 · 27 comments · Fixed by #169
Assignees

Comments

@jbrs360
Copy link

jbrs360 commented May 15, 2024

I've configured a 1PD Scheduler through the interface using GADS SSI.

  • Data source: Big Query
  • Data destination: Google Ads SSI

There is access to both platforms as I've used the same credentials/configurations in a Python project before trying with Tightlock.

To limit errors:

  • I've validated my BigQuery data to what the code expects (Data schema). I've tried with limited columns and limited data to limit errors
  • I've run multiple tests with different data sets, and different data types.

When running the 1PD Scheduler connection I get 1 error: "INVALID_ARGUMENT" Count: 1. I have no idea how to proceed. I've narrowed everything down where I can't change anything anymore and the error message doesn't help me.
image
image

@caiotomazelli caiotomazelli self-assigned this Jun 4, 2024
@caiotomazelli
Copy link
Collaborator

Hi @jbrs360, sorry for the delay coming back to you.

Can you provide the smallest set of columns that allow you to reproduce this error?

I will investigate the issue and get back to you by the end of this week.

@jbrs360
Copy link
Author

jbrs360 commented Jun 4, 2024 via email

@caiotomazelli
Copy link
Collaborator

Hi Jacob, I was able to reproduce.

In my case, the error was related to SSI not being allowed in the target account:

>, <_InactiveRpcError of RPC that terminated with:
	status = StatusCode.INVALID_ARGUMENT
	details = "Request contains an invalid argument."
	debug_error_string = "UNKNOWN:Error received from peer ipv4:173.194.212.95:443 {grpc_message:"Request contains an invalid argument.", grpc_status:3, created_time:"2024-06-04T16:35:47.152425085+00:00"}"
>, errors {
  error_code {
    offline_user_data_job_error: NOT_ON_ALLOWLIST_FOR_STORE_SALES_DIRECT
  }

Notice how Tightlock was exposing only the StatusCode ("invalid argument"). I sent PR #169 to better expose the error message.

As SSI requires a manual register step to be allowed, make sure you followed these steps for the target account: https://support.google.com/google-ads/answer/9995886?sjid=9733441823520280530-SA#eligibility

In case your account is already allow-listed, you can retry with the new version (once the PR mentioned above is merged) to see the specific error message you're getting in your case.

Hope this helps!

@jbrs360
Copy link
Author

jbrs360 commented Jun 5, 2024 via email

@caiotomazelli
Copy link
Collaborator

Hey Jacob,

If you already tested before, this might be something else.

I just merged the changes, so the proper error should be exposed now. Please redeploy and test again and feel free to reopen the issue if you still can't figure it out with the improved error message.

@jbrs360
Copy link
Author

jbrs360 commented Jun 12, 2024

Hi Caio,

I've started from scratch and created a new connection with a new data source and destination. I'm still getting the INVALID_ARGUMENT error when running the connection.

I don't see any new or improved error message.

@caiotomazelli
Copy link
Collaborator

Hi Jacob,

Just confirming: Have you redeployed your Tightlock backend with the latest version (merged on June 5)?

The change we made to the SSI connector (Line 120) should show you a more detailed version. So either your version is not updated or the API is not providing a detailed description of the problem.

Unfortunately I'm not able to debug the problem directly with your account, so I'll wait for your confirmation before investigating further.

@caiotomazelli caiotomazelli reopened this Jun 12, 2024
@jbrs360
Copy link
Author

jbrs360 commented Jun 18, 2024

Hi Caio,

We've redeployed the Tighlock backend and more detailed error messages are now available. We got a bit further but now I'm experiencing "The required field was not present."

Below you'll find some dummy data from our BQ table. All required fields should be present.
image

@caiotomazelli
Copy link
Collaborator

Hey Jacob,

Looks like the only thing that is missing now is at least one user identifier. Even though there is no single identifier that is required, you need to provide at least one of: email, telephone or address.

@jbrs360
Copy link
Author

jbrs360 commented Jun 20, 2024

Of course.

I've added multiple but it still fails unfortunately.
image

@caiotomazelli
Copy link
Collaborator

Thanks for confirming,

I'm trying to reproduce and see if I can investigate this in some other way, I'll keep you posted.

In the meantime, if I were to implement a custom debug version to investigate this issue, would you be willing to deploy it? Since I'm struggling to get access to an account that is enabled to use SSI, I might rely on your testing to get this fixed, if you are interested in helping out.

@jbrs360
Copy link
Author

jbrs360 commented Jun 20, 2024 via email

@caiotomazelli
Copy link
Collaborator

Hi Jacob,

I was able to get access to an SSI enabled account and I was able to send conversions through with this minimal example:

id,customer_id,conversion_action_id,conversion_date_time,conversion_micro_value,email
1,XXXXX,YYYYYY,2024-06-18 11:00:00-10:00,10000,[email protected]
2,XXXXX,YYYYYY,2024-06-18 11:00:00-11:00,20000,[email protected]

I found a bug in the way related to the optional custom_key parameter (PR #175 ).

That said, this parameter is only optional if you have not set it up in your Ads account.

All that being said, can you provide additional information about the error you're getting, since I was not able to reproduce? If you can also provide redacted information about the setup of your destination (i.e. if you are providing all the required fields in the UI) that would be great.

I'm still trying to find a good way to debug remotely...one option would be for you to temporarily invite me ([email protected]) to your Ads account, so that I can try sending a test hit and see if I can reproduce the problem.

@jbrs360
Copy link
Author

jbrs360 commented Jun 25, 2024 via email

@caiotomazelli
Copy link
Collaborator

Hey Jacob, I can't see the images when they come from email attachments. Can you post them directly in Github? Thanks!

@jbrs360
Copy link
Author

jbrs360 commented Jun 26, 2024

My bad.

image
image

@caiotomazelli
Copy link
Collaborator

Hi Jacob,

Can you send me the full error log you are getting? I'm trying to query the log database for "The required field was not present." with no luck, so it would be good to have more details.

@jbrs360
Copy link
Author

jbrs360 commented Jun 28, 2024

How do I get the full error log? The interface does not return any.

@caiotomazelli
Copy link
Collaborator

If you can provide a screenshot of the error you're getting in the interface (the "The required field was not present." that you mentioned) that would already be useful.

If you want to have the full log, you can:

  1. Go to "Compute Engine" in your cloud project and SSH into the tightlock deployed machine (might require relaxing our default SSH restrictions. You can allow port 22 to 0.0.0.0/0 following the firewall rules update instructions here: https://cloud.google.com/firewall/docs/using-firewalls#updating_firewall_rules)

  2. Once you are connected to the instance, you can go to /mnt/disks/tightlock/Tightlock/logs and all execution logs will be in this folder

I understand that these troubleshooting steps are complicated, but for now there is no other way to see them unfortunately. Simplifying this flow is currently in our roadmap though.

@jbrs360
Copy link
Author

jbrs360 commented Jul 4, 2024

I had a more technical colleague look into the error log with the guide you sent me. Thanks for the steps! He said it looked like something went wrong with the email column, which made me look further into the data we sent. Some rows were missing an email but had phone numbers and other personal information. Removing the rows with no email made the connection run successfully.

To improve the UI it would be nice to know what went wrong with the imported data. E.g. some of the rows were missing an email although it's not set to be required in the GitHub table.
image

@caiotomazelli
Copy link
Collaborator

Thanks for the update Jacob!

This is definitely a bug. I'll keep this issue open as I investigate.

Thanks again for your patience here and for the help while troubleshooting the issue.

@jbrs360
Copy link
Author

jbrs360 commented Jul 4, 2024

No problem Caio!

It would be a nice feature to get a "Successful run"-message with a webhook to e.g. Slack, to follow the different connections and to react as fast as possible if something went wrong.

@jbrs360
Copy link
Author

jbrs360 commented Jul 8, 2024

Hi Caio,

I got two questions:

  1. Could you make the Run log descending? Having the newest runs in the top would be a better overview.
  2. The token I've created keeps expiring: "invalid_grant: Token has been expired or revoked." Any workaround for that?

@caiotomazelli
Copy link
Collaborator

Hi Jacob, sorry, missed your questions here.

Answers below:

  1. I'll look into having that as an option, thanks for pointing that out.
  2. In this link, you can find common reasons for premature token expiration (normally, refresh_token should only expire after 6 months of inactivity). The most common cause of this problem is having your GCP OAuth project with "Testing" publishing status, which causes the token to expire after 7 days. If that's not the case, this could also be related to org specific policies in your GCP project.

@jbrs360
Copy link
Author

jbrs360 commented Jul 30, 2024 via email

@jbrs360
Copy link
Author

jbrs360 commented Aug 14, 2024 via email

@caiotomazelli
Copy link
Collaborator

Hey @jbrs360 sorry for the delay.

Unfortunately there are many reasons why you're not seeing the data. Normally, when there are no errors, this is unrelated to Tightlock.

I would advise following the steps in the comment above for checking the logs again and see what is the raw response from the API in the success cases and share here if you still can't find the reason.

Cheers,
Caio

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants