jerryc127 / hexo-theme-butterfly

🦋 A Hexo Theme: Butterfly
https://butterfly.js.org
Apache License 2.0
6.91k stars 1.25k forks source link

[Bug]: 布局与样式无效 #910

Closed spobit closed 2 years ago

spobit commented 2 years ago

使用的 Butterfly 版本? | What version of Butterfly are you use?

commit 6e58f68f0cf0612ebfa1ec898d5fd077888ed702 (HEAD -> master, tag: 4.2.2, origin/master)

使用的瀏覽器? || What browse are you using?

Chrome

使用的系統? || What operating system are you using?

Windows

問題描述 | Describe the bug

参照快速开始,做到安裝插件后, clear; hexo clean; hexo s 所有的布局与样式都无效. image

出現問題網站 | Website

jerryc127 commented 2 years ago

f12 看报错

spobit commented 2 years ago

本来想开箱即用

spobit002@DESKTOP-R4P9TGL MINGW64 ~ $ cd Documents/_github/_xbook/_hexo-blog/

spobit002@DESKTOP-R4P9TGL MINGW64 ~/Documents/_github/_xbook/_hexo-blog (master) $ hexo clean INFO Validating config INFO

  #####  #    # ##### ##### ###### #####  ###### #      #   #
  #    # #    #   #     #   #      #    # #      #       # #
  #####  #    #   #     #   #####  #    # #####  #        #
  #    # #    #   #     #   #      #####  #      #        #
  #    # #    #   #     #   #      #   #  #      #        #
  #####   ####    #     #   ###### #    # #      ######   #

                        4.2.2

=================================================================== INFO Deleted database.

spobit002@DESKTOP-R4P9TGL MINGW64 ~/Documents/_github/_xbook/_hexo-blog (master) $ hexo s INFO Validating config INFO

  #####  #    # ##### ##### ###### #####  ###### #      #   #
  #    # #    #   #     #   #      #    # #      #       # #
  #####  #    #   #     #   #####  #    # #####  #        #
  #    # #    #   #     #   #      #####  #      #        #
  #    # #    #   #     #   #      #   #  #      #        #
  #####   ####    #     #   ###### #    # #      ######   #

                        4.2.2

=================================================================== INFO Start processing [Browsersync] Access URLs:

      UI: http://localhost:3001

UI External: http://localhost:3001

INFO Hexo is running at http://localhost:4000 . Press Ctrl+C to stop. ERROR { err: OperationalError: C:\Users\spobit002\Documents_github_xbook_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33 17| @import '_search/algolia' 18| 19| if hexo-config('local_search') && hexo-config('local_search.enable') 20| @import '_search/index' 21| @import '_search/local-search' ---------------------------------------^ 22|

failed to locate @import file C:\Users\spobit002\Documents_github_xbook_hexo-blog\node_modules\stylus\lib\functions\index.styl

  at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
  ... 20 lines matching cause stack trace ...
  at processImmediate (node:internal/timers:466:21) {
cause: Error: C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33
   17|   @import '_search/algolia'
   18|
   19| if hexo-config('local_search') && hexo-config('local_search.enable')
   20|   @import '_search/index'
   21|   @import '_search/local-search'
---------------------------------------^
   22|

failed to locate @import file C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\functions\index.styl

    at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.visitRoot (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:707:27)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.evaluate (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:247:15)
    at Renderer.render (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\renderer.js:86:26)
    at Hexo.stylusFn (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo-renderer-stylus\lib\renderer.js:59:6)
    at Hexo.tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Hexo.ret (eval at makeNodePromisifiedEval (C:\Users\spobit002\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\bluebird\js\release\promisify.js:184:12), <anonymous>:13:39)
    at C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo\lib\hexo\render.js:75:22
    at tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:729:18)
    at _drainQueueStep (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:93:12)
    at _drainQueue (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:86:9)
    at Async._drainQueues (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:15:14)
    at processImmediate (node:internal/timers:466:21) {
  lineno: 21,
  column: 33,
  filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
  stylusStack: '',
  input: "if hexo-config('css_prefix')\n" +
    "  @import 'nib'\n" +
    '\n' +
    "@import '_third-party/normalize.min.css'\n" +
    '// project\n' +
    "@import 'var'\n" +
    "@import '_global/*'\n" +
    "@import '_highlight/highlight'\n" +
    "@import '_page/*'\n" +
    "@import '_layout/*'\n" +
    "@import '_tags/*'\n" +
    "@import '_mode/*'\n" +
    '\n' +
    '// search\n' +
    "if hexo-config('algolia_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/algolia'\n" +
    '\n' +
    "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/local-search'\n"
},
isOperational: true,
lineno: 21,
column: 33,
filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
stylusStack: '',
input: "if hexo-config('css_prefix')\n" +
  "  @import 'nib'\n" +
  '\n' +
  "@import '_third-party/normalize.min.css'\n" +
  '// project\n' +
  "@import 'var'\n" +
  "@import '_global/*'\n" +
  "@import '_highlight/highlight'\n" +
  "@import '_page/*'\n" +
  "@import '_layout/*'\n" +
  "@import '_tags/*'\n" +
  "@import '_mode/*'\n" +
  '\n' +
  '// search\n' +
  "if hexo-config('algolia_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/algolia'\n" +
  '\n' +
  "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/local-search'\n"

} } Asset render failed: %s css/index.css (node:13864) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency (Use node --trace-warnings ... to show where the warning was created) (node:13864) Warning: Accessing non-existent property 'column' of module exports inside circular dependency (node:13864) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency (node:13864) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency (node:13864) Warning: Accessing non-existent property 'column' of module exports inside circular dependency (node:13864) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency ERROR { err: OperationalError: C:\Users\spobit002\Documents_github_xbook_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33 17| @import '_search/algolia' 18| 19| if hexo-config('local_search') && hexo-config('local_search.enable') 20| @import '_search/index' 21| @import '_search/local-search' ---------------------------------------^ 22|

failed to locate @import file C:\Users\spobit002\Documents_github_xbook_hexo-blog\node_modules\stylus\lib\functions\index.styl

  at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
  ... 20 lines matching cause stack trace ...
  at processImmediate (node:internal/timers:466:21) {
cause: Error: C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33
   17|   @import '_search/algolia'
   18|
   19| if hexo-config('local_search') && hexo-config('local_search.enable')
   20|   @import '_search/index'
   21|   @import '_search/local-search'
---------------------------------------^
   22|

failed to locate @import file C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\functions\index.styl

    at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.visitRoot (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:707:27)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.evaluate (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:247:15)
    at Renderer.render (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\renderer.js:86:26)
    at Hexo.stylusFn (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo-renderer-stylus\lib\renderer.js:59:6)
    at Hexo.tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Hexo.ret (eval at makeNodePromisifiedEval (C:\Users\spobit002\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\bluebird\js\release\promisify.js:184:12), <anonymous>:13:39)
    at C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo\lib\hexo\render.js:75:22
    at tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:729:18)
    at _drainQueueStep (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:93:12)
    at _drainQueue (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:86:9)
    at Async._drainQueues (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:15:14)
    at processImmediate (node:internal/timers:466:21) {
  lineno: 21,
  column: 33,
  filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
  stylusStack: '',
  input: "if hexo-config('css_prefix')\n" +
    "  @import 'nib'\n" +
    '\n' +
    "@import '_third-party/normalize.min.css'\n" +
    '// project\n' +
    "@import 'var'\n" +
    "@import '_global/*'\n" +
    "@import '_highlight/highlight'\n" +
    "@import '_page/*'\n" +
    "@import '_layout/*'\n" +
    "@import '_tags/*'\n" +
    "@import '_mode/*'\n" +
    '\n' +
    '// search\n' +
    "if hexo-config('algolia_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/algolia'\n" +
    '\n' +
    "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/local-search'\n"
},
isOperational: true,
lineno: 21,
column: 33,
filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
stylusStack: '',
input: "if hexo-config('css_prefix')\n" +
  "  @import 'nib'\n" +
  '\n' +
  "@import '_third-party/normalize.min.css'\n" +
  '// project\n' +
  "@import 'var'\n" +
  "@import '_global/*'\n" +
  "@import '_highlight/highlight'\n" +
  "@import '_page/*'\n" +
  "@import '_layout/*'\n" +
  "@import '_tags/*'\n" +
  "@import '_mode/*'\n" +
  '\n' +
  '// search\n' +
  "if hexo-config('algolia_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/algolia'\n" +
  '\n' +
  "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/local-search'\n"

} } Asset render failed: %s css/index.css ERROR { err: OperationalError: C:\Users\spobit002\Documents_github_xbook_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33 17| @import '_search/algolia' 18| 19| if hexo-config('local_search') && hexo-config('local_search.enable') 20| @import '_search/index' 21| @import '_search/local-search' ---------------------------------------^ 22|

failed to locate @import file C:\Users\spobit002\Documents_github_xbook_hexo-blog\node_modules\stylus\lib\functions\index.styl

  at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
  ... 20 lines matching cause stack trace ...
  at processImmediate (node:internal/timers:466:21) {
cause: Error: C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33
   17|   @import '_search/algolia'
   18|
   19| if hexo-config('local_search') && hexo-config('local_search.enable')
   20|   @import '_search/index'
   21|   @import '_search/local-search'
---------------------------------------^
   22|

failed to locate @import file C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\functions\index.styl

    at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.visitRoot (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:707:27)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.evaluate (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:247:15)
    at Renderer.render (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\renderer.js:86:26)
    at Hexo.stylusFn (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo-renderer-stylus\lib\renderer.js:59:6)
    at Hexo.tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Hexo.ret (eval at makeNodePromisifiedEval (C:\Users\spobit002\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\bluebird\js\release\promisify.js:184:12), <anonymous>:13:39)
    at C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo\lib\hexo\render.js:75:22
    at tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:729:18)
    at _drainQueueStep (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:93:12)
    at _drainQueue (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:86:9)
    at Async._drainQueues (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:15:14)
    at processImmediate (node:internal/timers:466:21) {
  lineno: 21,
  column: 33,
  filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
  stylusStack: '',
  input: "if hexo-config('css_prefix')\n" +
    "  @import 'nib'\n" +
    '\n' +
    "@import '_third-party/normalize.min.css'\n" +
    '// project\n' +
    "@import 'var'\n" +
    "@import '_global/*'\n" +
    "@import '_highlight/highlight'\n" +
    "@import '_page/*'\n" +
    "@import '_layout/*'\n" +
    "@import '_tags/*'\n" +
    "@import '_mode/*'\n" +
    '\n' +
    '// search\n' +
    "if hexo-config('algolia_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/algolia'\n" +
    '\n' +
    "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/local-search'\n"
},
isOperational: true,
lineno: 21,
column: 33,
filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
stylusStack: '',
input: "if hexo-config('css_prefix')\n" +
  "  @import 'nib'\n" +
  '\n' +
  "@import '_third-party/normalize.min.css'\n" +
  '// project\n' +
  "@import 'var'\n" +
  "@import '_global/*'\n" +
  "@import '_highlight/highlight'\n" +
  "@import '_page/*'\n" +
  "@import '_layout/*'\n" +
  "@import '_tags/*'\n" +
  "@import '_mode/*'\n" +
  '\n' +
  '// search\n' +
  "if hexo-config('algolia_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/algolia'\n" +
  '\n' +
  "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/local-search'\n"

} } Asset render failed: %s css/index.css ERROR { err: OperationalError: C:\Users\spobit002\Documents_github_xbook_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33 17| @import '_search/algolia' 18| 19| if hexo-config('local_search') && hexo-config('local_search.enable') 20| @import '_search/index' 21| @import '_search/local-search' ---------------------------------------^ 22|

failed to locate @import file C:\Users\spobit002\Documents_github_xbook_hexo-blog\node_modules\stylus\lib\functions\index.styl

  at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
  ... 20 lines matching cause stack trace ...
  at processImmediate (node:internal/timers:466:21) {
cause: Error: C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33
   17|   @import '_search/algolia'
   18|
   19| if hexo-config('local_search') && hexo-config('local_search.enable')
   20|   @import '_search/index'
   21|   @import '_search/local-search'
---------------------------------------^
   22|

failed to locate @import file C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\functions\index.styl

    at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.visitRoot (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:707:27)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.evaluate (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:247:15)
    at Renderer.render (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\renderer.js:86:26)
    at Hexo.stylusFn (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo-renderer-stylus\lib\renderer.js:59:6)
    at Hexo.tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Hexo.ret (eval at makeNodePromisifiedEval (C:\Users\spobit002\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\bluebird\js\release\promisify.js:184:12), <anonymous>:13:39)
    at C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo\lib\hexo\render.js:75:22
    at tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:729:18)
    at _drainQueueStep (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:93:12)
    at _drainQueue (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:86:9)
    at Async._drainQueues (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:15:14)
    at processImmediate (node:internal/timers:466:21) {
  lineno: 21,
  column: 33,
  filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
  stylusStack: '',
  input: "if hexo-config('css_prefix')\n" +
    "  @import 'nib'\n" +
    '\n' +
    "@import '_third-party/normalize.min.css'\n" +
    '// project\n' +
    "@import 'var'\n" +
    "@import '_global/*'\n" +
    "@import '_highlight/highlight'\n" +
    "@import '_page/*'\n" +
    "@import '_layout/*'\n" +
    "@import '_tags/*'\n" +
    "@import '_mode/*'\n" +
    '\n' +
    '// search\n' +
    "if hexo-config('algolia_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/algolia'\n" +
    '\n' +
    "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/local-search'\n"
},
isOperational: true,
lineno: 21,
column: 33,
filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
stylusStack: '',
input: "if hexo-config('css_prefix')\n" +
  "  @import 'nib'\n" +
  '\n' +
  "@import '_third-party/normalize.min.css'\n" +
  '// project\n' +
  "@import 'var'\n" +
  "@import '_global/*'\n" +
  "@import '_highlight/highlight'\n" +
  "@import '_page/*'\n" +
  "@import '_layout/*'\n" +
  "@import '_tags/*'\n" +
  "@import '_mode/*'\n" +
  '\n' +
  '// search\n' +
  "if hexo-config('algolia_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/algolia'\n" +
  '\n' +
  "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/local-search'\n"

} } Asset render failed: %s css/index.css ERROR { err: OperationalError: C:\Users\spobit002\Documents_github_xbook_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33 17| @import '_search/algolia' 18| 19| if hexo-config('local_search') && hexo-config('local_search.enable') 20| @import '_search/index' 21| @import '_search/local-search' ---------------------------------------^ 22|

failed to locate @import file C:\Users\spobit002\Documents_github_xbook_hexo-blog\node_modules\stylus\lib\functions\index.styl

  at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
  ... 20 lines matching cause stack trace ...
  at processImmediate (node:internal/timers:466:21) {
cause: Error: C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\themes\butterfly-4.2.2\source\css\index.styl:21:33
   17|   @import '_search/algolia'
   18|
   19| if hexo-config('local_search') && hexo-config('local_search.enable')
   20|   @import '_search/index'
   21|   @import '_search/local-search'
---------------------------------------^
   22|

failed to locate @import file C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\functions\index.styl

    at Evaluator.visitImport (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:915:21)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.visitRoot (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:707:27)
    at Evaluator.Visitor.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\index.js:28:40)
    at Evaluator.visit (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:160:18)
    at Evaluator.evaluate (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\visitor\evaluator.js:247:15)
    at Renderer.render (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\stylus\lib\renderer.js:86:26)
    at Hexo.stylusFn (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo-renderer-stylus\lib\renderer.js:59:6)
    at Hexo.tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Hexo.ret (eval at makeNodePromisifiedEval (C:\Users\spobit002\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\bluebird\js\release\promisify.js:184:12), <anonymous>:13:39)
    at C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\hexo\lib\hexo\render.js:75:22
    at tryCatcher (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\util.js:16:23)
    at Promise._settlePromiseFromHandler (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:547:31)
    at Promise._settlePromise (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:604:18)
    at Promise._settlePromise0 (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:649:10)
    at Promise._settlePromises (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\promise.js:729:18)
    at _drainQueueStep (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:93:12)
    at _drainQueue (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:86:9)
    at Async._drainQueues (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (C:\Users\spobit002\Documents\_github\_xbook\_hexo-blog\node_modules\bluebird\js\release\async.js:15:14)
    at processImmediate (node:internal/timers:466:21) {
  lineno: 21,
  column: 33,
  filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
  stylusStack: '',
  input: "if hexo-config('css_prefix')\n" +
    "  @import 'nib'\n" +
    '\n' +
    "@import '_third-party/normalize.min.css'\n" +
    '// project\n' +
    "@import 'var'\n" +
    "@import '_global/*'\n" +
    "@import '_highlight/highlight'\n" +
    "@import '_page/*'\n" +
    "@import '_layout/*'\n" +
    "@import '_tags/*'\n" +
    "@import '_mode/*'\n" +
    '\n' +
    '// search\n' +
    "if hexo-config('algolia_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/algolia'\n" +
    '\n' +
    "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
    "  @import '_search/index'\n" +
    "  @import '_search/local-search'\n"
},
isOperational: true,
lineno: 21,
column: 33,
filename: 'C:\\Users\\spobit002\\Documents\\_github\\_xbook\\_hexo-blog\\themes\\butterfly-4.2.2\\source\\css\\index.styl',
stylusStack: '',
input: "if hexo-config('css_prefix')\n" +
  "  @import 'nib'\n" +
  '\n' +
  "@import '_third-party/normalize.min.css'\n" +
  '// project\n' +
  "@import 'var'\n" +
  "@import '_global/*'\n" +
  "@import '_highlight/highlight'\n" +
  "@import '_page/*'\n" +
  "@import '_layout/*'\n" +
  "@import '_tags/*'\n" +
  "@import '_mode/*'\n" +
  '\n' +
  '// search\n' +
  "if hexo-config('algolia_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/algolia'\n" +
  '\n' +
  "if hexo-config('local_search') && hexo-config('local_search.enable')\n" +
  "  @import '_search/index'\n" +
  "  @import '_search/local-search'\n"

} } Asset render failed: %s css/index.css

jerryc127 commented 2 years ago

升级 hexo 到最新版本 把 node_modules 和 package-lock.json 删了 重新npm install

spobit commented 2 years ago

升级 hexo 到最新版本 把 node_modules 和 package-lock.json 删了 重新npm install

成功了,感谢!!!