New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug report - Dataview significantly slows down link creation #1154
Comments
Can you try doing a similar divide and conquer on dataview versions to see where it started? |
After testing on dataview version, I found that:
Essentially 0.5.0 onwards has this bug |
I don't know whether it's linked to this issue, but I've also noticed significant performance issues with 0.5.x releases - I've downgraded back to 0.4.26 for now. My vault is ~950 notes with ~4500 links. If I remember correctly, it started when the indexing was introduced - the developer console seems to indicate that indexing has been successful, though Edit: I should note: I'm on Linux running Obsidian 0.14.15 with installer 0.14.6 |
By indexing, do you mean the change which added the index caching (for faster startup)? Dataview has always been a data index and has parsed markdown files since the earliest releases. I wonder if that is actually running on the main thread - that would be bad if so. |
@Caffa - I appreciate you including a performance dump; there is definitely something suspicious going on, though it's not immediately obvious from the dump (since plugins+obsidian strip a lot of metadata in production builds). Do you have any other notable plugins in your vault, like Supercharged Links or etc, that could affect link behavior? Dataview does not change this behavior by default, but any plugins that implicitly use the Dataview API might. |
Looking a little more at the performance dump, it seems the specific issue is
So the indexing seems fine; the real issue appears to be that a convenience function I wrote a few months ago is very slow for large files! |
I've fixed the underlying issue, and as a nice side effect, I think everything that uses DataviewJS page queries is suddenly going to become noticably faster. |
I do have supercharged links - that might be the problem. |
Try updating to the latest version to see if the behavior has improved. |
+1 I found this issue looking for ways to improve performance using 4.22. Not sure what was fixed, but my vault seems much faster with 0.5.31. Thanks. |
If you encounter any further slowness, please make issues with performance profiles; they've uncovered several unintentional bugs which made Dataview needlessly slow :) |
What happened?
I found that enabling dataview causes the vault to freeze for several seconds when I try to create a link (type with [[ ) and it works like safe mode when dataview is disabled. I tried reinstalling obsidian but that didn't help.
Here is a video of enabling and disabling dataview + testing for whether the link completion bug is present. https://youtu.be/aMkZpt8hTFw
I have the performance snapshot from developer's tools. https://www.dropbox.com/sh/hr4ny4ikwpa6g6x/AAABwnbdQQIX1e2SHDd1Kjyta?dl=0 Uploaded here. This is only enabling and disabling the dataview plugin.
I am on a M1 Mac Studio 2022. Monterey Version 12.4 (21F79)
EDIT:
Testing on a clean vault with notes and only dataview = no bugs
Dataview works normally in a clean vault (no notes, no plugins other than dataview). It just causes issues in my main vault which has notes when other plugins are enabled. so dataview alone is fine.
Checked by reinstalling latest version from community + restarting obsidian and the bug is still present in main vault with other plugins enabled.
it seems to be that when I type [[ it will freeze, but if I type fast enough [[hi then less lag
Vault has 2560 notes
DQL
No response
JS
No response
Dataview Version
0.5.26
Obsidian Version
0.14.6
OS
MacOS
The text was updated successfully, but these errors were encountered: