今天发现obsidian0.14.2的一个疑似bug。创建日记时使用了第三方模板,创建日记时会得到下图显示的文件,模板代码没有被执行。本日记创建借助obsidian自带的日记
和 liamcain/obsidian-calendar-plugin
实现,模板使用了Templater
。
A suspected bug of obsidian 0.14.2 was found today. A third-party template was used when creating a daily note. When creating a journal, you would get the content in the following figure, while the template codes were not executed. This diary creation is implemented with the help of obsidian’s own ‘diary’ and ‘liamcain/obsidian-calendar-plugin’, and the template takes advantage of ‘Templater’.
因为我的obsidian是在0.13版上升级过来的。经过排查,发现是0.14版的
user script functions
导致的。如下图所示:My obsidian was upgraded on version 0.13. After investigation, it was found that it was caused by ‘user script functions’ for obsidian 0.14. As is shown in the following figure:
因为我的这些脚本还处于测试阶段,不能成功运行,obsidian依旧检测了它们。它告诉我们
parsing error
,但是必须明白,这些代码我并没有实际调用。这是不应该的。通过将上图中的第5个位置处的做法,日记恢复正常创建,如下图所示。
Because these scripts were still at testing and couldn’t run successfully, obsidian still checked them. It tells us ‘parsing error’, but it must be understood that I did not actually call the js code.s The checking is unnecessary. As is shown at location 5 in the above figure when the templater folder was cancelled,
the daily note was created again, as shown in the following figure.
Hopefully to get an answer, thank you!