Closed ShrimpyChips closed 1 year ago
What import error are you getting?
Here is what I get:
Network error: 413 Client Error: Payload Too Large for url: https://www.notion.so/api/v3/submitTransaction
Then it retries a number of times, then you get this:
Traceback (most recent call last): File "enex2notion\enex_uploader.py", line 28, in upload_note File "enex2notion\enex_uploader_block.py", line 10, in upload_block File "notion\block.py", line 141, in add_new File "notion\client.py", line 469, in exit File "notion\client.py", line 323, in submit_transaction File "ratelimit\decorators.py", line 113, in wrapper File "ratelimit\decorators.py", line 80, in wrapper File "notion\client.py", line 275, in post File "notion\client.py", line 298, in _post File "requests\models.py", line 1021, in raise_for_status requests.exceptions.HTTPError: 413 Client Error: Payload Too Large for url: https://www.notion.so/api/v3/submitTransaction
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "enex2notion__main.py", line 4, in
Also, the file isn't actually large. It's a web clip. When exported by itself as an ENEX it's only 354kb.
It seems to have linked images that either don't exist or that for whatever reason it shows as broken image links., I've noticed that that seems to cause the same error for a number of web clips.
Export flat patterns from SOLIDWORKS part or assembly components.txt
Here is the ENEX for that one note as a TXT (github wont allow ENEX as an attachment)
This should be fixed now. I also added --skip-failed option to avoid crashes when upload error occurs. You can use --log option to keep track of failed notes.
Suggestion
I have been upload a large notebook and I got one note that keeps causing the same import error. The problem is in order to skip this note I have to go back to Evernote, trim out all the ones that successfully uploaded, delete the failing note (or manually import as it were) and then re export the rest of the notebook again. I've got a bunch of large notebooks to do and this could be tedious if there are errors about.
So I noticed that the done file function just exports what seems to be a hash for each note uploaded. Is there a way to print that hash to the verbose log so that if I want to skip a note all I have to do is manually add it to the done file?