diff --git a/micropip/transaction.py b/micropip/transaction.py index 6686157..73adaee 100644 --- a/micropip/transaction.py +++ b/micropip/transaction.py @@ -48,14 +48,10 @@ async def gather_requirements( self, requirements: list[str] | list[Requirement], ) -> None: - requirement_promises = [] - for requirement in requirements: - requirement_promises.append(self.add_requirement(requirement)) - futures: list[asyncio.Future] = [] try: - for coro in requirement_promises: - futures.append(asyncio.ensure_future(coro)) + for requirement in requirements: + futures.append(asyncio.ensure_future(self.add_requirement(requirement))) await asyncio.gather(*futures) except ValueError: if not self.keep_going: