Notion-2-Obsidan
Notion-2-Obsidan copied to clipboard
fix :If there is a exception with one file, you can continue to work on the other files.
Why Change:
The tool will be crash when the tool try to read the file/directory that can't be success to read
How to do:
We use syntax try catch
to handle to problems.
I am still getting these
Traceback (most recent call last): File "C:\Users\doe\Projects\Notion-2-Obsidian\N2O.py", line 114, in <module> mdContent, cnt = N2Omodule.N2Omd(mdFile) File "C:\Users\doe\Projects\Notion-2-Obsidian\N2Omodule.py", line 334, in N2Omd line, cnt = internal_link_convert(line) File "C:\Users\doe\Projects\Notion-2-Obsidian\N2Omodule.py", line 292, in internal_link_convert print(line) File "C:\Python310\lib\encodings\cp1252.py", line 19, in encode return codecs.charmap_encode(input,self.errors,encoding_table)[0] UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f4d4' in position 4: character maps to <undefined>
Using Git Bash on windows 11 with an extensive notion backup
Edit 🔽 This issue does not trigger on vscode but another unhandled exception (Long filepath) when running in vscode I am keeping this comment if you want to fix this unhandled exception as well
bash Traceback (most recent call last): File "c:\Users\doe\Projects\Notion-2-Obsidian\N2O.py", line 132, in <module> with open(newfilepath, append_write, encoding='utf-8') as tempFile: FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\chatt\\AppData\\Local\\Temp\\tmp0b2j8trd\\Personal Dashboard\\Liked tweets\\With blockchain, things turn upside down. Finance guys find it extremely hard to understand given technology complexity, and we, techies, find solace finally in some place. Work on your tech skills, start from as basics as JS, there is no easy way out to understand this..md'