diff --git a/python_payload/st3m/application.py b/python_payload/st3m/application.py index 75edfe398fbb87606aabf80d6c89eaee1a5d8e3e..88246a384aaca9636595b63662bc0c34a931e304 100644 --- a/python_payload/st3m/application.py +++ b/python_payload/st3m/application.py @@ -208,7 +208,7 @@ class BundleMetadata: entry = self._metadata.get("entry", None) if entry is None: return self._load_class("App") - if not isinstance(entry.get("class"), str): + if isinstance(entry.get("class"), str): class_entry = entry["class"] return self._load_class(class_entry) @@ -456,7 +456,7 @@ class BundleManager: toml_cache[dirpath] = metadata toml_cache[dirpath]["_toml_size"] = toml_stat[6] toml_cache[dirpath]["_toml_change"] = toml_stat[8] - print(f"Adding {dirpath} to JSON cache.") + log.info(f"Adding {dirpath} to JSON cache.") try: bundle = BundleMetadata(dirpath, metadata) @@ -485,7 +485,7 @@ class BundleManager: if toml_cache_modified: with open(cache_path, "w") as f: json.dump(toml_cache, f) - print("load time for", path, (time.time_ns() - load_start) / 1000000) + log.info(f"load time for {path}, {(time.time_ns() - load_start) / 1000000}ms") def update(self) -> None: self._discover_at("/flash/sys/apps")