File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 2020)
2121from sqlalchemy .orm import sessionmaker
2222import logging
23- from google .cloud import tasks_v2
2423
2524from shared .common .logging_utils import get_env_logging_level
2625
@@ -127,6 +126,7 @@ def create_refresh_materialized_view_task():
127126 """
128127 from google .protobuf import timestamp_pb2
129128 from datetime import datetime , timedelta
129+ from google .cloud import tasks_v2
130130
131131 try :
132132 logging .info ("Creating materialized view refresh task." )
@@ -210,8 +210,10 @@ def create_http_task_with_name(
210210 queue_name : str ,
211211 task_name : str ,
212212 task_time : str ,
213- http_method : tasks_v2 . HttpMethod ,
213+ http_method ,
214214):
215+ from google .cloud import tasks_v2
216+
215217 """Creates a GCP Cloud Task."""
216218
217219 token = (tasks_v2 .OidcToken (service_account_email = os .getenv ("SERVICE_ACCOUNT_EMAIL" )),)
You can’t perform that action at this time.
0 commit comments