From b39eb6c71dbe4e1ce8153e82644f54cdc943457d Mon Sep 17 00:00:00 2001 From: Danyal-Faheem Date: Fri, 12 Jan 2024 13:09:08 +0500 Subject: [PATCH] fix: change NoneType to str for type-checking --- tutor/plugins/v1.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutor/plugins/v1.py b/tutor/plugins/v1.py index 3d440ce588..fa640fb0db 100644 --- a/tutor/plugins/v1.py +++ b/tutor/plugins/v1.py @@ -68,7 +68,7 @@ def discover_package(entrypoint: EntryPoint) -> None: # Add plugin information if entrypoint.dist is None: raise ValueError(f"Could not read plugin version: {name}") - dist_version = entrypoint.dist.version if entrypoint.dist else None + dist_version = entrypoint.dist.version if entrypoint.dist else "Unknown" hooks.Filters.PLUGINS_INFO.add_item((name, dist_version)) # Import module on enable