jiamo commented on PR #22965:
URL: https://github.com/apache/airflow/pull/22965#issuecomment-1125601432
It is strange I don't upgrade airflow and login in the worker pod.
same logic code . just run `python` and paste
```
from operator import attrgetter
from tempfile import NamedTemporaryFile
from typing import Dict, List, Optional, Sequence
from airflow.models import BaseOperator
from airflow.plugins_manager import AirflowPlugin
from airflow.providers.google.ads.hooks.ads import GoogleAdsHook
query = """
SELECT customer.id,
customer.descriptive_name,
campaign.id, campaign.name, ad_group.id, ad_group.name,
geographic_view.country_criterion_id,
segments.date,
metrics.cost_micros, metrics.impressions, metrics.clicks,
metrics.conversions, metrics.ctr
FROM geographic_view
WHERE segments.date=\'2022-05-11\'
"""
service = GoogleAdsHook(gcp_conn_id='onion-16040',
google_ads_conn_id='google_ads_default', api_version="v10")
rows = service.search(client_ids=["xxxxxxxxxxx"], query=query,
page_size=10000)
```
It works fine.
So `GoogleAdsHook` and `search` was fine. So I suspect just execute `pip
install apache-airflow-providers-google==7.0.0rc` don't have a complete upgrade
process.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]