Reduce logging verbosity by downgrading frontmatter and permission warnings to debug level
This commit is contained in:
parent
e171a0dc35
commit
af7d1c0d2e
@ -162,7 +162,7 @@ def parse_markdown_file(raw: str) -> frontmatter.Post:
|
||||
try:
|
||||
return frontmatter.loads(raw)
|
||||
except Exception as exc:
|
||||
logger.warning(f"Invalid frontmatter detected, falling back to plain markdown parsing: {exc}")
|
||||
logger.debug(f"Invalid frontmatter detected, falling back to plain markdown parsing: {exc}")
|
||||
content = raw
|
||||
if raw.startswith("---"):
|
||||
match = re.match(r"^---\s*\r?\n.*?\r?\n---\s*\r?\n?", raw, flags=re.DOTALL)
|
||||
@ -261,8 +261,8 @@ def _scan_vault(vault_name: str, vault_path: str) -> Dict[str, Any]:
|
||||
for tag in tags:
|
||||
tag_counts[tag] = tag_counts.get(tag, 0) + 1
|
||||
|
||||
except PermissionError as e:
|
||||
logger.warning(f"Permission denied, skipping {fpath}: {e}")
|
||||
except PermissionError:
|
||||
logger.debug(f"Permission denied, skipping {fpath}")
|
||||
continue
|
||||
except Exception as e:
|
||||
logger.error(f"Error indexing {fpath}: {e}")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user