-
Notifications
You must be signed in to change notification settings - Fork 18
[tasks/github] Fix uncommitted UPDATE in update_issue_closed_cntrbs_by_repo_id #483
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -128,7 +128,7 @@ def insight_model(repo_git: str,logger,engine) -> None: | |
| AND repo_insights.ri_field = to_delete.ri_field | ||
| """) | ||
|
|
||
| with engine.connect() as conn: | ||
| with engine.begin() as conn: | ||
| result = conn.execute(delete_points_SQL, parameters=dict(repo_id=repo_id, min_date=min_date)) | ||
|
|
||
| # get table values to check for dupes later on | ||
|
|
@@ -561,7 +561,7 @@ def clear_insights(repo_id, new_endpoint, new_field, logger): | |
| AND ri_field = '{}' | ||
| """.format(repo_id, new_endpoint, new_field) | ||
| try: | ||
| with engine.connect() as conn: | ||
| with engine.begin() as conn: | ||
| result = conn.execute(deleteSQL) | ||
| except Exception as e: | ||
| logger.info("Error occured deleting insight slot: {}".format(e)) | ||
|
|
@@ -579,7 +579,7 @@ def clear_insights(repo_id, new_endpoint, new_field, logger): | |
| AND ri_field = '{}' | ||
| """.format(repo_id, new_endpoint, new_field) | ||
| try: | ||
| with engine.connect() as conn: | ||
| with engine.begin() as conn: | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [pylint] reported by reviewdog 🐶 |
||
| result = conn.execute(deleteSQL) | ||
| except Exception as e: | ||
| logger.info("Error occured deleting insight slot: {}".format(e)) | ||
|
|
@@ -622,7 +622,7 @@ def clear_insight(repo_id, new_score, new_metric, new_field, logger): | |
| AND ri_field = '{}' | ||
| """.format(record['repo_id'], record['ri_metric'], record['ri_field']) | ||
| try: | ||
| with engine.connect() as conn: | ||
| with engine.begin() as conn: | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [pylint] reported by reviewdog 🐶 |
||
| result = conn.execute(deleteSQL) | ||
| except Exception as e: | ||
| logger.info("Error occured deleting insight slot: {}".format(e)) | ||
|
|
@@ -676,7 +676,7 @@ def clear_insight(repo_id, new_score, new_metric, new_field, logger): | |
| AND ri_metric = '{}' | ||
| """.format(insight['repo_id'], insight['ri_metric']) | ||
| try: | ||
| with engine.connect() as conn: | ||
| with engine.begin() as conn: | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [pylint] reported by reviewdog 🐶 |
||
| result = conn.execute(deleteSQL) | ||
| except Exception as e: | ||
| logger.info("Error occured deleting insight slot: {}".format(e)) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[pylint] reported by reviewdog 🐶
E0602: Undefined variable 'engine' (undefined-variable)