Templater icon indicating copy to clipboard operation
Templater copied to clipboard

Recreating very large files with new file creation trigger on can freeze Obsidian

Open kevboh opened this issue 3 years ago • 2 comments

Plugin informations (please complete the following information):

  • OS: macOS 11.3
  • Templater version: 1.8.1
  • Obsidian version: 0.12.13
  • Templater settings: Trigger Templater on new file creation = true

Describe the bug Creating a very large (my test file is 200k words) file with this setting on can cause Obsidian to freeze. In my specific case, I am able to reliably reproduce by:

  1. Deleting the large file.
  2. Recreating it.

It doesn't seem to matter how the file is created. I first found this by creating it via my plugin, but you can also copy the file into your vault in the system explorer.

Expected behavior Obsidian should continue working.

Additional context My uninformed guess is that trying to read the enormous file is what fails.

kevboh avatar Aug 04 '21 14:08 kevboh

Confirm that, Linux Mint 20.2/Obsidian 0.12.12/Templater 1.8.1.

In addition:

  • exactly the same symptoms here
  • the "enormous" file is 200k words, ~1.4MB.
  • I also have Hotkey for templates set to trigger on new file creation, but that doesn’t effect it.
  • Sadly couldn’t profile it, the profiler got stuck in processing (while the rest of Obsidian hangs).

Moonbase59 avatar Aug 04 '21 14:08 Moonbase59

Further testing shows it’s also not exactly reproducable. I would guess some unhandled or race condition.

Moonbase59 avatar Aug 11 '21 21:08 Moonbase59

should be fixed in 1.14.14

shabegom avatar Oct 29 '22 15:10 shabegom