个人博客:https://mmmmmm.me

源码:https://github.com/dataiyangu/dataiyangu.github.io

发布文章遇到:

Unhandled rejection Template render error: (unknown path) [Line 265, Column 814]
  unexpected token: .
    at Object._prettifyError (/Users/leesin/Desktop/blog/node_modules/nunjucks/src/lib.js:36:11)
    at Template.render (/Users/leesin/Desktop/blog/node_modules/nunjucks/src/environment.js:524:21)
    at Environment.renderString (/Users/leesin/Desktop/blog/node_modules/nunjucks/src/environment.js:362:17)
    at Promise (/Users/leesin/Desktop/blog/node_modules/hexo/lib/extend/tag.js:66:9)
    at Promise._execute (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/debuggability.js:313:9)
    at Promise._resolveFromExecutor (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:483:18)
    at new Promise (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:79:10)
    at Tag.render (/Users/leesin/Desktop/blog/node_modules/hexo/lib/extend/tag.js:64:10)
    at Object.tagFilter [as onRenderEnd] (/Users/leesin/Desktop/blog/node_modules/hexo/lib/hexo/post.js:230:16)
    at Promise.then.then.result (/Users/leesin/Desktop/blog/node_modules/hexo/lib/hexo/render.js:65:19)
    at tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:512:31)
    at Promise._settlePromise (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:569:18)
    at Promise._settlePromise0 (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:614:10)
    at Promise._settlePromises (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:694:18)
    at _drainQueueStep (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:138:12)
    at _drainQueue (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:131:9)
    at Async._drainQueues (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:147:5)
    at Immediate.Async.drainQueues [as _onImmediate] (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:17:14)
    at runCallback (timers.js:810:20)
    at tryOnImmediate (timers.js:768:5)
    at processImmediate [as _immediateCallback] (timers.js:745:5)

一般是markdown合适不对,找到对应的文件(上面不显示,可以通过二分法进行删除排除法,找到错误的),删除,google说是/{/{/}/}不能在{}中包{}

发布文章的时候出现错误:

Template render error: (unknown path) [Line 7, Column 23]
Error: Unable to call the return value of (posts["first"])["updated"]["toISOString"], which is undefined or falsey
at Object.exports.prettifyError (D:\itxuye\node_modules\nunjucks\src\lib.js:34:15)
at D:\itxuye\node_modules\nunjucks\src\environment.js:485:31
at root [as rootRenderFunc](eval at %28D:itxuyenode_modulesnunjuckssrcenvironment.js:564:24%29, :161:3)
at Obj.extend.render (D:\itxuye\node_modules\nunjucks\src\environment.js:478:15)
at Hexo.module.exports (D:\itxuye\node_modules\hexo-generator-feed\lib\generator.js:28:22)
at Hexo.tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at Hexo. (D:\itxuye\node_modules\bluebird\js\release\method.js:15:34)
at D:\itxuye\node_modules\hexo\lib\hexo\index.js:337:24
at tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at MappingPromiseArray._promiseFulfilled (D:\itxuye\node_modules\bluebird\js\release\map.js:57:38)
at MappingPromiseArray.PromiseArray._iterate (D:\itxuye\node_modules\bluebird\js\release\promise_array.js:113:31)

_posts文件中不能一篇文章都没有,可能是我上面的二分法给全部删除文章了出现问题。

代码推送到github,hexo g -d 半天推送不上去

停留在这里不动

[master d43a5a4] Site updated: 2019-01-27 19:19:34
 146 files changed, 168 insertions(+), 168 deletions(-)

家里的网络平常上github有时候都成问题,所以之前就出现过,到公司,用公司的网就没问题了。

记录一次hexo+coding hexo s本都没问题,hexo g -d 样式并未改变的问题。

问题背景:

昨天晚上,将hexo相关的改变push到了coding上,本来我也知道push上去是有一定的反应时间的,不能马上改变,过了一晚上还是不行,第二天通过问客服,得到了解决的办法。

解决方法:

将coding pages停止服务重新开启,重新拉取代码,重新配置域名。

另外,修改代码,白天push上去改变的比晚上快很多,具体原因不详~

hexo 问题记录:hexo server的时候报Template render error : (unknown path) [Line 7, Column 23

emplate render error: (unknown path) [Line 7, Column 23]
Error: Unable to call the return value of (posts["first"])["updated"]["toISOString"], which is undefined or falsey
at Object.exports.prettifyError (D:\itxuye\node_modules\nunjucks\src\lib.js:34:15)
at D:\itxuye\node_modules\nunjucks\src\environment.js:485:31
at root [as rootRenderFunc](eval at %28D:itxuyenode_modulesnunjuckssrcenvironment.js:564:24%29, :161:3)
at Obj.extend.render (D:\itxuye\node_modules\nunjucks\src\environment.js:478:15)
at Hexo.module.exports (D:\itxuye\node_modules\hexo-generator-feed\lib\generator.js:28:22)
at Hexo.tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at Hexo. (D:\itxuye\node_modules\bluebird\js\release\method.js:15:34)
at D:\itxuye\node_modules\hexo\lib\hexo\index.js:337:24
at tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at MappingPromiseArray._promiseFulfilled (D:\itxuye\node_modules\bluebird\js\release\map.js:57:38)
at MappingPromiseArray.PromiseArray._iterate (D:\itxuye\node_modules\bluebird\js\release\promise_array.js:113:31)
at MappingPromiseArray.init (D:\itxuye\node_modules\bluebird\js\release\promise_array.js:77:10)
at new MappingPromiseArray (D:\itxuye\node_modules\bluebird\js\release\map.js:25:10)
at map (D:\itxuye\node_modules\bluebird\js\release\map.js:152:12)
at Function.Promise.map (D:\itxuye\node_modules\bluebird\js\release\map.js:160:12)
at D:\itxuye\node_modules\hexo\lib\hexo\index.js:334:20
at tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at Promise._settlePromiseFromHandler (D:\itxuye\node_modules\bluebird\js\release\promise.js:504:31)
at Promise._settlePromise (D:\itxuye\node_modules\bluebird\js\release\promise.js:561:18)
at Promise._settlePromise0 (D:\itxuye\node_modules\bluebird\js\release\promise.js:606:10)
at Promise._settlePromises (D:\itxuye\node_modules\bluebird\js\release\promise.js:685:18)
at Async._drainQueue (D:\itxuye\node_modules\bluebird\js\release\async.js:138:16)
02:09:00.737 DEBUG Generator: asset
02:09:00.741 DEBUG Database saved
02:09:00.742 FATAL (unknown path) [Line 7, Column 23]
Error: Unable to call the return value of (posts["first"])["updated"]["toISOString"], which is undefined or falsey
Template render error: (unknown path) [Line 7, Column 23]
Error: Unable to call the return value of (posts["first"])["updated"]["toISOString"], which is undefined or falsey
at Object.exports.prettifyError (D:\itxuye\node_modules\nunjucks\src\lib.js:34:15)
at D:\itxuye\node_modules\nunjucks\src\environment.js:485:31
at root [as rootRenderFunc](eval at %28D:itxuyenode_modulesnunjuckssrcenvironment.js:564:24%29, :161:3)
at Obj.extend.render (D:\itxuye\node_modules\nunjucks\src\environment.js:478:15)
at Hexo.module.exports (D:\itxuye\node_modules\hexo-generator-feed\lib\generator.js:28:22)
at Hexo.tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at Hexo. (D:\itxuye\node_modules\bluebird\js\release\method.js:15:34)
at D:\itxuye\node_modules\hexo\lib\hexo\index.js:337:24
at tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at MappingPromiseArray._promiseFulfilled (D:\itxuye\node_modules\bluebird\js\release\map.js:57:38)
at MappingPromiseArray.PromiseArray._iterate (D:\itxuye\node_modules\bluebird\js\release\promise_array.js:113:31)
at MappingPromiseArray.init (D:\itxuye\node_modules\bluebird\js\release\promise_array.js:77:10)
at new MappingPromiseArray (D:\itxuye\node_modules\bluebird\js\release\map.js:25:10)
at map (D:\itxuye\node_modules\bluebird\js\release\map.js:152:12)
at Function.Promise.map (D:\itxuye\node_modules\bluebird\js\release\map.js:160:12)
at D:\itxuye\node_modules\hexo\lib\hexo\index.js:334:20
at tryCatcher (D:\itxuye\node_modules\bluebird\js\release\util.js:16:23)
at Promise._settlePromiseFromHandler (D:\itxuye\node_modules\bluebird\js\release\promise.js:504:31)
at Promise._settlePromise (D:\itxuye\node_modules\bluebird\js\release\promise.js:561:18)
at Promise._settlePromise0 (D:\itxuye\node_modules\bluebird\js\release\promise.js:606:10)
at Promise._settlePromises (D:\itxuye\node_modules\bluebird\js\release\promise.js:685:18)
at Async._drainQueue (D:\itxuye\node_modules\bluebird\js\release\async.js:138:16

可能你删除_posts文件夹下的 hello-world.md文件,_posts文件夹下面不能一个文件都没有。

hexo发布文章报错记录:Unhandled rejection TypeError: Cannot set property ‘lastIndex’ of undefined

错误代码:

Unhandled rejection TypeError: Cannot set property 'lastIndex' of undefined
    at highlight (/Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:511:35)
    at /Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:561:21
    at Array.forEach (<anonymous>)
    at Object.highlightAuto (/Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:560:40)
    at /Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:117:25
    at highlight (/Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:120:7)
    at highlightUtil (/Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:22:14)
    at /Users/leesin/Desktop/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:62:15
    at String.replace (<anonymous>)
    at Hexo.backtickCodeBlock (/Users/leesin/Desktop/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:14:31)
    at Hexo.tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Hexo.<anonymous> (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/method.js:15:34)
    at Promise.each.filter (/Users/leesin/Desktop/blog/node_modules/hexo/lib/extend/filter.js:63:65)
    at tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Object.gotValue (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/reduce.js:155:18)
    at Object.gotAccum (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/reduce.js:144:25)
    at Object.tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:512:31)
    at Promise._settlePromise (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:569:18)
    at Promise._settlePromiseCtx (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:606:10)
    at _drainQueueStep (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:142:12)
    at _drainQueue (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:131:9)

Unhandled rejection TypeError: Cannot set property 'lastIndex' of undefined
    at highlight (/Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:511:35)
    at /Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:561:21
    at Array.forEach (<anonymous>)
    at Object.highlightAuto (/Users/leesin/Desktop/blog/node_modules/highlight.js/lib/highlight.js:560:40)
    at /Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:117:25
    at highlight (/Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:120:7)
    at highlightUtil (/Users/leesin/Desktop/blog/node_modules/hexo-util/lib/highlight.js:22:14)
    at /Users/leesin/Desktop/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:62:15
    at String.replace (<anonymous>)
    at Hexo.backtickCodeBlock (/Users/leesin/Desktop/blog/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:14:31)
    at Hexo.tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Hexo.<anonymous> (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/method.js:15:34)
    at Promise.each.filter (/Users/leesin/Desktop/blog/node_modules/hexo/lib/extend/filter.js:63:65)
    at tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Object.gotValue (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/reduce.js:155:18)
    at Object.gotAccum (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/reduce.js:144:25)
    at Object.tryCatcher (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:512:31)
    at Promise._settlePromise (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:569:18)
    at Promise._settlePromiseCtx (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/promise.js:606:10)
    at _drainQueueStep (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:142:12)
    at _drainQueue (/Users/leesin/Desktop/blog/node_modules/bluebird/js/release/async.js:131:9)

解决:

hexo根目录下面的 auto_detect设置为false

这个配置是用来自动查错的。

原因:

md文章的格式不对,可是字数很多,错误可能是代码块的格式不对,这个时候就把这个配置置为false就行了。

hexo 错误汇总的更多相关文章

  1. Entity Framework学习笔记——错误汇总

    之前的小项目做完了,到了总结经验和更新学习笔记的时间了.开始正题之前先啰嗦一下,对之前的学习目标进行一个调整:“根据代码生成表”与“生成数据库脚本和变更脚本”合并为“Code First模式日常使用篇 ...

  2. 李洪强iOS开发之OC常见错误汇总

    // //  main.m //  16 - 常见错误汇总 // //  Created by vic fan on 16/7/13. //  Copyright © 2016年 李洪强. All r ...

  3. Python常见的错误汇总

    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 错误: [错误分析]第二个参数必须为类,否则会报TypeError,所以正确的应 ...

  4. PHP常见错误汇总

    日常开发和调试的时候,经常会遇到一些错误,光怪陆离的不知所以,所以,特此将错误汇总一下,借鉴!!! 1. 原因分析:  一般可能是该文件出现了问题,检查一下代码和格式,是否出现开始的地方出现了空格,或 ...

  5. Quartus II 中 Verilog 常见警告/错误汇总

    Verilog 常见错误汇总 1.Found clock-sensitive change during active clock edge at time <time> on regis ...

  6. android studio 错误汇总以及解决办法

    android studio 错误汇总以及解决办法  参考 https://www.jianshu.com/p/7c7de6562231 问题1. Error:Execution failed for ...

  7. 编程中易犯错误汇总:一个综合案例.md

    # 11编程中易犯错误汇总:一个综合案例 在上一篇文章中,我们学习了如何区分好的代码与坏的代码,如何写好代码.所谓光说不练假把式,在这篇文章中,我们就做一件事——一起来写代码.首先,我会先列出问题,然 ...

  8. react 报红错误汇总

    react  报红错误汇总 一.Uncaught TypeError: Cannot read property 'value' of undefined 未知类型错:无法读取未定义的属性“value ...

  9. Jmeter工具做性能测试 常见的错误汇总

    在Win机器上用Jmeter做性能测试,汇总下我自身遇到的错误和解决方案 java.net.BindException: Address already in use: JVM_Bind 原因分析:压 ...

随机推荐

  1. shell脚本中关于日期的操作

    一.计算指定日期的前一天的日期 date -d "yesterday 20150401 " +%Y%m%d 二.如果获取当前日期的前一天        date -d " ...

  2. SpringBoot中使用Scheduling执行定时任务

    SpringBoot自带的 Schedule,可以将它看成一个轻量级的Quartz,而且使用起来比Quartz简单许多 以下任务都是在单线程下执行的 第一步 创建SpringBoot项目 第二步 外汇 ...

  3. 泛型(Generic)方法(函数,算法)

    例子: static void Main(string[] args) { int[] a1 = { 1, 2, 3, 4, 5 }; int[] a2 = { 1, 2, 3, 4, 5 }; do ...

  4. 阿里巴巴IPv6应用平台引领下一代互联网

    摘要: 据预测,到2020年底我国IPv6终端设备将达到5亿,正在快速取代IPv4.阿里巴巴网络架构师张先国先生在2018 年GNTC 大会IPv6 专场上分享IPv6应用集团业务(支付宝.淘宝.天猫 ...

  5. bzoj1026题解

    [解题思路] 数位DP.f[i][j]表示以j结尾的i位数中windy数的个数,转移方程f[i][j]=Σf[i-1][k](|j-k|>1). 基于f数组,我们可以统计出1~n内的windy数 ...

  6. Python 让文件代码支持汉字

    默认使用ASCII编码,改成utf8 #!/usr/bin/env python # -*- coding:utf8 -*- #coding:utf-8

  7. python中os模块获取路径的几种方式

    一.代码 import os BASE_DIR = os.path.abspath(os.path.join(os.path.dirname(__file__), "..")) p ...

  8. NX二次开发-NXOPEN_DimensionCollection遍历图纸上的所有标注尺寸

    NX11+VS2013 #include <NXOpen/Drawings_DrawingSheet.hxx> #include <NXOpen/Drawings_DrawingSh ...

  9. Core Text 入门

    本文所涉及的代码你可以在这里下载到 https://github.com/kejinlu/CTTest,包含两个项目,一个Mac的NSTextView的测试项目,一个iOS的Core Text的测试项 ...

  10. LeetCode 1037. Valid Boomerang (有效的回旋镖)

    题目标签:Math 题目给了我们三个点,让我们判断这三个点是否在一条直线上. 利用斜率 k = (y1 - y0) / (x1 - x0) 来判断,如果 三个点 abc, ab 的斜率 = bc 的斜 ...