diff --git a/enterprise/management/commands/monthly_impact_report.py b/enterprise/management/commands/monthly_impact_report.py index eacd7dce0a..1ba85f7912 100644 --- a/enterprise/management/commands/monthly_impact_report.py +++ b/enterprise/management/commands/monthly_impact_report.py @@ -926,8 +926,7 @@ def get_query_results_from_snowflake(self): try: cs.execute(QUERY) rows = cs.fetchall() - for row in rows: - yield row + yield from rows finally: cs.close() ctx.close() diff --git a/enterprise/management/commands/nudge_dormant_enrolled_enterprise_learners.py b/enterprise/management/commands/nudge_dormant_enrolled_enterprise_learners.py index 87f95cbd5c..396bf9fe09 100644 --- a/enterprise/management/commands/nudge_dormant_enrolled_enterprise_learners.py +++ b/enterprise/management/commands/nudge_dormant_enrolled_enterprise_learners.py @@ -145,8 +145,7 @@ def get_query_results_from_snowflake(self): try: cs.execute(QUERY) rows = cs.fetchall() - for row in rows: - yield row + yield from rows finally: cs.close() ctx.close() diff --git a/integrated_channels/integrated_channel/models.py b/integrated_channels/integrated_channel/models.py index 05ddf5c99e..6bdec9b378 100644 --- a/integrated_channels/integrated_channel/models.py +++ b/integrated_channels/integrated_channel/models.py @@ -269,7 +269,7 @@ def fetch_orphaned_content_audits(self): enterprise_customer=self.enterprise_customer, remote_deleted_at__isnull=True, remote_created_at__isnull=False, - ).filter(~non_existent_catalogs_filter | null_catalogs_filter) + ).filter(~non_existent_catalogs_filter | null_catalogs_filter) # pylint: disable=unsupported-binary-operation def update_content_synced_at(self, action_happened_at, was_successful): """