Skip to content

Commit

Permalink
Update return variables.
Browse files Browse the repository at this point in the history
  • Loading branch information
CYarros10 committed Oct 15, 2024
1 parent 2d8a3be commit f361d02
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -904,7 +904,7 @@ def execute(self, context: Context):
impersonation_chain=self.impersonation_chain,
)

response = self.hook.create_cached_content(
cached_content_name = self.hook.create_cached_content(
project_id=self.project_id,
location=self.location,
model_name=self.model_name,
Expand All @@ -914,9 +914,9 @@ def execute(self, context: Context):
display_name=self.display_name,
)

self.log.info("Cached Content Name: %s", response)
self.log.info("Cached Content Name: %s", cached_content_name)

return response
return cached_content_name


class GenerateFromCachedContentOperator(GoogleCloudBaseOperator):
Expand Down Expand Up @@ -978,7 +978,7 @@ def execute(self, context: Context):
gcp_conn_id=self.gcp_conn_id,
impersonation_chain=self.impersonation_chain,
)
response = self.hook.generate_from_cached_content(
cached_content_text = self.hook.generate_from_cached_content(
project_id=self.project_id,
location=self.location,
cached_content_name=self.cached_content_name,
Expand All @@ -987,6 +987,6 @@ def execute(self, context: Context):
safety_settings=self.safety_settings,
)

self.log.info("Cached Content Response: %s", response)
self.log.info("Cached Content Response: %s", cached_content_text)

return response
return cached_content_text

0 comments on commit f361d02

Please sign in to comment.