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

Hexo 3.2.0-beta.2 test result report #1627

Closed
Xuanwo opened this Issue Dec 6, 2015 · 16 comments

Comments

9 participants
@Xuanwo
Contributor

Xuanwo commented Dec 6, 2015

ref: https://travis-ci.org/Xuanwo/xuanwo.github.io/builds/95182069

build 400, historic time

I meet a TypeError: Cannot set property 'lastIndex' of undefined error, and error message as below

41.76s$ hexo g
INFO  Start processing
FATAL Something's wrong. Maybe you can find the solution here: http://hexo.io/docs/troubleshooting.html
TypeError: Cannot set property 'lastIndex' of undefined
    at highlight (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:460:35)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:513:21
    at Array.forEach (native)
    at Object.highlightAuto (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:509:20)
    at highlight (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo-util/lib/highlight.js:98:19)
    at module.exports (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo-util/lib/highlight.js:21:14)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:49:15
    at String.replace (native)
    at Hexo.backtickCodeBlock (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:15:31)
    at Hexo.tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Hexo.<anonymous> (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/method.js:15:34)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/extend/filter.js:68:35
    at tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Object.gotValue (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/reduce.js:145:18)
    at Object.gotAccum (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/reduce.js:134:25)
    at Object.tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Promise._settlePromiseFromHandler (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:489:31)
    at Promise._settlePromise (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:546:18)
    at Promise._settlePromiseCtx (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:583:10)
    at Async._drainQueue (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:134:12)
    at Async._drainQueues (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:139:10)
    at Immediate.Async.drainQueues [as _onImmediate] (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:16:14)
    at processImmediate [as _immediateCallback] (timers.js:383:17)
The command "hexo g" exited with 1.
60.72s$ hexo d
INFO  Start processing
FATAL Something's wrong. Maybe you can find the solution here: http://hexo.io/docs/troubleshooting.html
TypeError: Cannot set property 'lastIndex' of undefined
    at highlight (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:460:35)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:513:21
    at Array.forEach (native)
    at Object.highlightAuto (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/highlight.js/lib/highlight.js:509:20)
    at highlight (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo-util/lib/highlight.js:98:19)
    at module.exports (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo-util/lib/highlight.js:21:14)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:49:15
    at String.replace (native)
    at Hexo.backtickCodeBlock (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/plugins/filter/before_post_render/backtick_code_block.js:15:31)
    at Hexo.tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Hexo.<anonymous> (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/method.js:15:34)
    at /home/travis/build/Xuanwo/xuanwo.github.io/node_modules/hexo/lib/extend/filter.js:68:35
    at tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Object.gotValue (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/reduce.js:145:18)
    at Object.gotAccum (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/reduce.js:134:25)
    at Object.tryCatcher (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/util.js:11:23)
    at Promise._settlePromiseFromHandler (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:489:31)
    at Promise._settlePromise (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:546:18)
    at Promise._settlePromiseCtx (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/promise.js:583:10)
    at Async._drainQueue (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:134:12)
    at Async._drainQueues (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:139:10)
    at Immediate.Async.drainQueues [as _onImmediate] (/home/travis/build/Xuanwo/xuanwo.github.io/node_modules/bluebird/js/release/async.js:16:14)
    at processImmediate [as _immediateCallback] (timers.js:383:17)
The command "hexo d" exited with 1.

@tommy351

@Xuanwo Xuanwo added the bug label Dec 6, 2015

@Xuanwo

This comment has been minimized.

Show comment
Hide comment
@Xuanwo

Xuanwo Dec 6, 2015

Contributor

set auto_detect to false fixed.

and test results are as below:
before(3.1.1):

INFO  Files loaded in 41 s
INFO  731 files generated in 24 s
Elapsed time 2 min 6 sec

after(3.2.0-beta.2):

INFO  Files loaded in 6.54 s
INFO  731 files generated in 25 s
Elapsed time 1 min 20 sec

This is the cold start time, as the cache added, hot start will be quicker.

Contributor

Xuanwo commented Dec 6, 2015

set auto_detect to false fixed.

and test results are as below:
before(3.1.1):

INFO  Files loaded in 41 s
INFO  731 files generated in 24 s
Elapsed time 2 min 6 sec

after(3.2.0-beta.2):

INFO  Files loaded in 6.54 s
INFO  731 files generated in 25 s
Elapsed time 1 min 20 sec

This is the cold start time, as the cache added, hot start will be quicker.

@Xuanwo Xuanwo added discussion and removed bug labels Dec 6, 2015

@Xuanwo Xuanwo changed the title from Hexo 3.2.0-beta.2 error report to Hexo 3.2.0-beta.2 test result report Dec 6, 2015

@leesei

This comment has been minimized.

Show comment
Hide comment
@leesei

leesei Dec 8, 2015

Member

I think we should recommend setting highlight.js's auto detect to false in the document.
It is causing quite a lot of issues.

Member

leesei commented Dec 8, 2015

I think we should recommend setting highlight.js's auto detect to false in the document.
It is causing quite a lot of issues.

@Xuanwo

This comment has been minimized.

Show comment
Hide comment
@Xuanwo

Xuanwo Dec 8, 2015

Contributor

Yes, It used to save a lot time for don't need to choose language, but at this time, it looks like just resulting more and more problems.

Contributor

Xuanwo commented Dec 8, 2015

Yes, It used to save a lot time for don't need to choose language, but at this time, it looks like just resulting more and more problems.

@tommy351

This comment has been minimized.

Show comment
Hide comment
@tommy351

tommy351 Dec 8, 2015

Member

It's disabled by default in Hexo 3.2.

Member

tommy351 commented Dec 8, 2015

It's disabled by default in Hexo 3.2.

@leesei

This comment has been minimized.

Show comment
Hide comment
@leesei

leesei Dec 8, 2015

Member

@tommy351 do you mean disabling the config?
It's still true in hexo-starter.
https://github.com/hexojs/hexo-starter/blob/master/_config.yml#L43

Member

leesei commented Dec 8, 2015

@tommy351 do you mean disabling the config?
It's still true in hexo-starter.
https://github.com/hexojs/hexo-starter/blob/master/_config.yml#L43

@tommy351

This comment has been minimized.

Show comment
Hide comment
@tommy351

tommy351 Dec 8, 2015

Member

hexo-starter is not updated yet. But it has been disabled in hexo core.
https://github.com/hexojs/hexo/blob/master/lib/hexo/default_config.js#L37

Member

tommy351 commented Dec 8, 2015

hexo-starter is not updated yet. But it has been disabled in hexo core.
https://github.com/hexojs/hexo/blob/master/lib/hexo/default_config.js#L37

@leesei

This comment has been minimized.

Show comment
Hide comment
@leesei

leesei Dec 8, 2015

Member

But the default config will be overwritten by config value, isn't it?
I'll create PR on hexo-starter.

Member

leesei commented Dec 8, 2015

But the default config will be overwritten by config value, isn't it?
I'll create PR on hexo-starter.

@leesei leesei added the highlight label Dec 8, 2015

@Xuanwo

This comment has been minimized.

Show comment
Hide comment
@Xuanwo

Xuanwo Dec 8, 2015

Contributor

I think we can remove the auto-detect option from _config.yml, and educate people form the rule that add specific language for codeblocks.

Contributor

Xuanwo commented Dec 8, 2015

I think we can remove the auto-detect option from _config.yml, and educate people form the rule that add specific language for codeblocks.

@leesei

This comment has been minimized.

Show comment
Hide comment
@leesei

leesei Dec 8, 2015

Member

@Xuanwo I second the idea. We can override the value and state in documentation that it will be hardcoded. Actually we could also set lang to plain if it is missing.

Member

leesei commented Dec 8, 2015

@Xuanwo I second the idea. We can override the value and state in documentation that it will be hardcoded. Actually we could also set lang to plain if it is missing.

mitsuruog added a commit to mitsuruog/blog.mitsuruog.info that referenced this issue Feb 4, 2016

Fix TypeError: Cannot set property 'lastIndex' of undefined
refs Hexo 3.2.0-beta.2 test result report · Issue #1627 · hexojs/hexo hexojs/hexo#1627
@leesei

This comment has been minimized.

Show comment
Hide comment
@leesei

leesei Feb 29, 2016

Member

Track in #1786

Member

leesei commented Feb 29, 2016

Track in #1786

@leesei leesei closed this Feb 29, 2016

@Waydrow

This comment has been minimized.

Show comment
Hide comment
@Waydrow

Waydrow Mar 28, 2016

I meet this problem too. I have been troubled for a whole day. Thanks very much. It's working!!

Waydrow commented Mar 28, 2016

I meet this problem too. I have been troubled for a whole day. Thanks very much. It's working!!

zhaochunqi added a commit to zhaochunqi/zhaochunqi.github.io that referenced this issue Apr 10, 2016

@lovexiaov

This comment has been minimized.

Show comment
Hide comment
@lovexiaov

lovexiaov May 13, 2016

set auto_detect to false solved my problem.

lovexiaov commented May 13, 2016

set auto_detect to false solved my problem.

@cyang812

This comment has been minimized.

Show comment
Hide comment
@cyang812

cyang812 May 21, 2016

set auto_detect to false solved my problem.

cyang812 commented May 21, 2016

set auto_detect to false solved my problem.

@masikkk

This comment has been minimized.

Show comment
Hide comment
@masikkk

masikkk May 29, 2016

met this prob, thank you!

masikkk commented May 29, 2016

met this prob, thank you!

@Mran

This comment has been minimized.

Show comment
Hide comment
@Mran

Mran Jul 14, 2016

i met this issue too.And my problem was due to that i didn't specify language for the code in markdown.so,you should specify your code language.May it can help you.

Mran commented Jul 14, 2016

i met this issue too.And my problem was due to that i didn't specify language for the code in markdown.so,you should specify your code language.May it can help you.

FloatingGuy added a commit to FloatingGuy/fg-Blog that referenced this issue Mar 28, 2017

@yugasun

This comment has been minimized.

Show comment
Hide comment
@yugasun

yugasun Apr 24, 2017

I have solved the problem by changing auto_detect to false too~

yugasun commented Apr 24, 2017

I have solved the problem by changing auto_detect to false too~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment