uselotus / lotus

File .deepsource.toml not found in the default branch of the repository root. Please refer to the docs.

Unnecessary use of comprehension PYL-R1721
Performance
Major
a year agoa year old
Unnecessary use of a comprehension, use list(plan_dict.items()) instead.
440                plan_dict[plan_obj["id"]] = set()
441            plan_dict[plan_obj["id"]].add(plan_obj["external_id"])
442
443        lotus_plans = [444            (plan_id, external_plan_ids)
445            for plan_id, external_plan_ids in plan_dict.items()
446        ]
Unnecessary use of a comprehension, use list(grouping_filter.keys()) instead.
 706        elif self.event_type == EVENT_TYPE.DELTA:
 707            last_pre_query_grouped = (
 708                pre_query_all_events.filter(*filter_args, **grouping_filter)
 709                .values(*[x for x in grouping_filter.keys()]) 710                .annotate(last_qty=Sum(Cast(F("property_value"), FloatField())))
 711            )
 712            last_pre_query_actual_events = pre_query_all_events.annotate(