From 346cfc03885571fd448f8218a8b9f12836c2fcb2 Mon Sep 17 00:00:00 2001 From: Tomas Uribe Date: Tue, 3 Dec 2024 19:37:39 -0600 Subject: [PATCH] fix: use set instead of list for arcs_executed, fixes poor performance (#1901) Co-authored-by: Ned Batchelder --- coverage/results.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coverage/results.py b/coverage/results.py index 39612a8a7..e61ad5736 100644 --- a/coverage/results.py +++ b/coverage/results.py @@ -178,7 +178,7 @@ def arcs_missing(self) -> list[TArc]: """Returns a sorted list of the un-executed arcs in the code.""" missing = ( p for p in self.arc_possibilities - if p not in self.arcs_executed + if p not in self.arcs_executed_set and p[0] not in self.no_branch and p[1] not in self.excluded )