diff --git a/folder-organizer-v3.4.py b/folder-organizer-v3.4.py index 87f730f..d96ca4d 100644 --- a/folder-organizer-v3.4.py +++ b/folder-organizer-v3.4.py @@ -1,6 +1,6 @@ # ================================================================ # AMPP Framelight X — Nested Prefix Folder Organizer -# Production v3.4 — Delimiter: -- +# Production v3.4.1 — Delimiter: -- # # Examples: # "BMG--Videos--File.mp4" → BMG / Videos / (asset linked) @@ -17,8 +17,11 @@ # except), making every hierarchy lookup fail and causing duplicate # folders to be created on every run instead of reusing existing ones. # Also use .get() on hierarchy response to avoid KeyError when the -# path doesn't exist yet. Also replaced bare except with named -# exception so lookup errors are visible in AMPP job logs. +# path doesn't exist yet. +# +# v3.4.1 Fix: Removed logger.log() call (unknown signature caused +# TypeError). Hierarchy lookup failures now fall through silently +# to folder creation, which is the correct recovery path anyway. # ================================================================ import json import urllib.parse @@ -61,8 +64,8 @@ else: hlist = resp.get("hierarchy:list", []) if hlist and len(hlist) > 0: folder_id = str(hlist[-1]["folder:id"]) - except Exception as lookup_ex: - logger.log("Folder hierarchy lookup failed for '" + current_path + "': " + str(lookup_ex)) + except: + # Lookup failed — fall through to folder creation below folder_id = None if not folder_id: