Closed cole31415 closed 3 years ago
@cole31415 请问你更新了哪部分代码呢? 通过报错信息,可以大概看出,是配置项 algolia_search 出问题了,你看下 Stun 的 _config.yml 文件中,搜索 algolia_search,看看能不能搜到?
另外,如果要启用 algolia 搜索,请务必阅读文档:https://liuyib.github.io/hexo-theme-stun/zh-CN/advanced/third-part.html#algolia-%E6%90%9C%E7%B4%A2
可以搜索到algolia_search,我就是想更新下stun的_config.yml文件的,没有启用algolia搜索功能
我删除了原来的主题,重新拉取主题还是有这个问题,有点懵逼了
@cole31415 麻烦发一下你的 hexo 和 stun 配置(为了保护你的配置安全,如果配置中有私钥的话,私钥不用发)
Hexo _config.yml:
Stun _config.yml:
@cole31415 请问,你之前用的时候正常吗?怎么样之后开始报的错(安装某某插件、还是仅仅改了某个配置)?
之前正常,就昨天git pull主题的配置文件,然后拉取到了之前我的改动代码,我就放弃了所有更改(vscode),然后又突然点击了master源代码分支的同步更改,再继续运行就这样了
@cole31415 我暂时还是定位不到问题。感觉你拉取到的代码中有冲突,然后你放弃更改的时候冲突是没法回退的。请你检查下,代码里有没有冲突呢? 如果你检查后,没有冲突,能否把你博客现在的源码推到 github 上,让我看下。或者加 stun 交流 q 群,把你的博客源码发给我。
ok的,群号是多少
@cole31415 我用你提供的环境信息,安装了一遍试了试,没有复现问题。现在基本可以断定和环境,原来的代码无关。通过你的描述,应该是你操作失误,使得某些文件的变动超出了你的控制范围导致的。 加群吧,帮你看下出啥问题了,issue 就关了。
ok的,群号是多少
1019013440
I want to create a new issue
Environment Information
Stun Version:
Hexo Version: 5.1.1
Platform: Windows 10
Browser: Chrome 83
Node.js and NPM Information: node: v12.18.3, npm: 6.14.6
Package dependencies Information: hexo-site@0.0.0 C:\Users\Mechrevo\Desktop\hexo +-- hexo@5.1.1 +-- hexo-deployer-git@2.1.0 +-- hexo-generator-archive@1.0.0 +-- hexo-generator-category@1.0.0 +-- hexo-generator-feed@3.0.0 +-- hexo-generator-index-pin-top@0.2.2 +-- hexo-generator-tag@1.0.0 +-- hexo-renderer-ejs@1.0.0 +-- hexo-renderer-marked@3.2.0 +-- hexo-renderer-pug@1.0.0 +-- hexo-renderer-stylus@2.0.1 +-- hexo-server@2.0.0 `-- hexo-wordcount@6.0.1
Hexo Configuration:
Stun Configuration:
Expected behaviour
Actual behaviour
Steps to reproduce the behaviour
运行 hexo s点击本地地址时
Unhandled rejection TypeError: C:\Users\Mechrevo\Desktop\hexo\themes\stun\layout_partials\config.pug:1
Cannot read property 'enable' of undefined at eval (eval at wrap (C:\Users\Mechrevo\Desktop\hexo\node_modules\pug-runtime\wrap.js:6:10),:409:25):5884:72)
at _View._compiled (C:\Users\Mechrevo\Desktop\hexo\node_modules\hexo\lib\theme\view.js:136:50)
at _View.render (C:\Users\Mechrevo\Desktop\hexo\node_modules\hexo\lib\theme\view.js:39:17)
at C:\Users\Mechrevo\Desktop\hexo\node_modules\hexo\lib\hexo\index.js:64:21
at tryCatcher (C:\Users\Mechrevo\Desktop\hexo\node_modules\bluebird\js\release\util.js:16:23)
at C:\Users\Mechrevo\Desktop\hexo\node_modules\bluebird\js\release\method.js:15:34
at RouteStream._read (C:\Users\Mechrevo\Desktop\hexo\node_modules\hexo\lib\hexo\router.js:30:5)
at RouteStream.Readable.read (_streamreadable.js:467:10)
at resume (_stream_readable.js:981:12)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
at template (eval at wrap (C:\Users\Mechrevo\Desktop\hexo\node_modules\pug-runtime\wrap.js:6:10),
Other Information