Open keikoro opened 7 years ago
Looks like a bug indeed. I'll take a look.
Just stumbled across this one after installing the plugin. Any news here?
Not yet. Maybe over the long weekend.
Having an error with the similarity plugin as below. Can someone help?
TaskError - taskid:similarity:output/posts/nlp/nlp-main/index.html.related.json PythonAction Error Traceback (most recent call last): File "/home/randlow/anaconda3/envs/nikola/lib/python3.7/site-packages/doit/action.py", line 424, in execute returned_value = self.py_callable(*self.args, **kwargs) File "/home/randlow/github/blog2/plugins/similarity/similarity.py", line 121, in write_similar with open(path, 'w+') as outf: FileNotFoundError: [Errno 2] No such file or directory: 'output/posts/nlp/nlp-main/index.html.related.json'
I don't know enough about Nikola yet to be able to pinpoint the problem, but the similarity plugin seems to have a problem with the creation of new posts via
nikola new_post
.I first noticed the problem in the log of the window in which I had
nikola auto
running (the log output was suddenly red), but the error is the same even when Nikola doesn't build automatically butnikola build
is called manually. It seems to only apply to the newest post though.Log of when, after I'd stopped
nikola auto
, I created 3 new posts in a row (showing the last 2 here), then rannikola build
:What's also interesting, though possibly not related (?), is that gensim/the plugin seems to check posts that don't actually exist anymore, or whose contents have changed?
I'm not sure what the
matrix with 12 documents
refers to, but the number of posts in my/public/
folder is 6 (1 of which is taggedprivate
), the number of posts in/posts/
is 11 (2 of which are taggedprivate
and 3 of which are taggeddraft
). The words listed at[2017-08-26T23:05:42Z] INFO: gensim.models.lsimodel: topic #0
are from a post that got set todraft
and whose contents (= the words listed by gensim) I replaced (with something completely different).And indeed the log for
nikola auto
(though notnikola build
), starts like this:Looks like
cache
d contents are used?/cache/posts
contains 24 files, 2 per post (one is the.html
, a second ends in.html.dep
), including a post that I'd deleted from/posts/
a while ago. The cached version of the file whose words gensim uses are not the current contents but the old contents.And looking at the locally served version of the blog, it looks broken – the error caused by the plugin seems to stop new posts or changed posts from building... Only disabling the plugin in
conf.py
and then runningnikola build
helped fix it.