jckleiner / notion-backup

Automatic Notion workspace backup to Google Drive, Dropbox, pCloud, Nextcloud or to your local machine.
86 stars 33 forks source link

Export state in progress to local file, but I can't see any files #17

Closed aratnikovmxmgt closed 5 months ago

aratnikovmxmgt commented 5 months ago

In log I can see

08:46:42.779 [main] INFO com.greydev.notionbackup.NotionBackup - ---------------- Starting Notion Backup ----------------
08:46:43.721 [main] INFO com.greydev.notionbackup.NotionClient - DOWNLOADS_DIRECTORY_PATH is not set. Downloads will be saved to: /downloads 
08:46:43.723 [main] INFO com.greydev.notionbackup.NotionClient - Using export type: markdown
08:46:43.723 [main] INFO com.greydev.notionbackup.NotionClient - Flatten export file tree: false
08:46:43.723 [main] INFO com.greydev.notionbackup.NotionClient - Export comments: true
08:46:44.960 [main] INFO com.greydev.notionbackup.NotionClient - taskId extracted
08:46:51.687 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'in_progress', Pages exported so far: 54

But I can't see files in /downloads with and without volume. Using ghcr.io/jckleiner/notion-backup. But I can see how memory of container increasing. Using DOWNLOADS_DIRECTORY_PATH = /downloads didn't help.

Any guess what should I do?

jckleiner commented 5 months ago

Here is an explanation which might answer your question: https://github.com/jckleiner/notion-backup/issues/16#issuecomment-1951431675 If this won't work, please let me know.

aratnikovmxmgt commented 5 months ago

Right now I've faced this problem:

09:42:53.897 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'in_progress', Pages exported so far: 8452
09:43:00.136 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'in_progress', Pages exported so far: 8452
09:43:06.355 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'in_progress', Pages exported so far: 63
---------SKIP---------
09:44:08.776 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'in_progress', Pages exported so far: 64
09:44:15.002 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'dead', Pages exported so far: 64
09:44:21.218 [main] INFO com.greydev.notionbackup.NotionClient - Notion API workspace export 'state': 'dead', Pages exported so far: 64

I've checked inside the container /downloads and nothing is inside and mount volume - still nothing inside изображение

jckleiner commented 5 months ago

Hmm. The export was started on the Notion servers (the program regularly send requests to Notion to get state of the export, once the export is ready, it will be downloaded) but then the state returned from Notion was dead. I've never encountered that state before, therefore I don't know what might caused it.

That seems like a problem on Notion's side and not something we can fix in this repository. That's why currently I don't know what you can do to solve this. If I find any info related to this, then I'll post it here.

aratnikovmxmgt commented 5 months ago

After conducting some research, I've determined that the issue lies with Notion itself. My Notion workspace is quite large, and attempting to export the entire space often results in failure. To address this, I've developed a simple Python script capable of exporting specific blocks within the space.

We can consider the issue resolved for now, but I suggest introducing an environment variable with an 80-minute timeout to prevent similar problems in the future.

Thank you for your diligent efforts!

jckleiner commented 5 months ago

Thanks for the info. I'll look into what can be improved when I find the time.