From 69af2a71929c60f31f629b36b180a86df5ca0564 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Mon, 3 Jan 2022 13:02:49 -0500 Subject: refactor: no need to special-case spec.origin == "namespace" Namespace packages used to have this value, but that was changed in 3.7: https://bugs.python.org/issue32305 --- coverage/inorout.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'coverage') diff --git a/coverage/inorout.py b/coverage/inorout.py index 2ab7d493..25943cb1 100644 --- a/coverage/inorout.py +++ b/coverage/inorout.py @@ -124,8 +124,7 @@ def file_and_path_for_module(modulename): pass else: if spec is not None: - if spec.origin != "namespace": - filename = spec.origin + filename = spec.origin path = list(spec.submodule_search_locations or ()) return filename, path -- cgit v1.2.1