Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions codeflash/optimization/function_optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -1461,14 +1461,14 @@ def process_review(

if raise_pr or staging_review:
data["root_dir"] = git_root_dir()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this condition now required?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that's from the original code, it's still required

try:
# modify argument of staging vs pr based on the impact
opt_impact_response = self.aiservice_client.get_optimization_impact(**data)
if opt_impact_response == "low":
raise_pr = False
staging_review = True
except Exception as e:
logger.debug(f"optimization impact response failed, investigate {e}")
# try:
# # modify argument of staging vs pr based on the impact
# opt_impact_response = self.aiservice_client.get_optimization_impact(**data)
# if opt_impact_response == "low":
# raise_pr = False
# staging_review = True
# except Exception as e:
# logger.debug(f"optimization impact response failed, investigate {e}")
if raise_pr and not staging_review:
data["git_remote"] = self.args.git_remote
check_create_pr(**data)
Expand Down
Loading