visualcurrent / Notion-2-Obsidan

Conversion routines to convert all Notion .md exports to full Obsidian compatibility
262 stars 47 forks source link

Fixed an Unhandled exception due to long Windows file path #36

Open pradyumnac opened 1 year ago

pradyumnac commented 1 year ago

The original issue. This is due to windows long path limitation This fix addresses an unhandled "FileNotFound" exception in the situation that the temporary extract file path length is too long for windows and was silently not getting extracted

Solution: To ignore such error but keep a track of such files separately and print out these error at the end The ProblemFiles.MD mechanism captures these unhandled filepaths in the log

scr 1662279011 scr 1662278892

A. Modification to N2O.py to handle a file open where fil was not being found. This is due to windows long path limitation B. Also added pip requirements.txt file for easy virtyual env suport C. Modified Gitignore

  1. pycache folder should be fully gitignored safely. Otherwise, the .pyc cache file for each new python version will be pulled into repo scr 1662281196
  2. Added virtual env folder to gitignore
pradyumnac commented 1 year ago

33 A follow up fix for This PR