Skip to content
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

Cannot be packaged with file name in Chinese #217

Closed
heny opened this issue Jan 31, 2021 · 2 comments
Closed

Cannot be packaged with file name in Chinese #217

heny opened this issue Jan 31, 2021 · 2 comments
Labels
bug Something isn't working
Milestone

Comments

@heny
Copy link
Contributor

heny commented Jan 31, 2021

A packaging error occurred while using the Chinese Markdown filename
yarn build

yarn run v1.22.4
$ vitepress build docs
vitepress v0.11.5
vite v2.0.0-beta.60

  • building client + server bundles...Language does not exist: sh
    ✓ building client + server bundles...
  • rendering pages...Error: Cannot find module './%E5%85%B6%E4%BB%96%E7%AC%94%E8%AE%B0.md.js'
    Require stack:
  • E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js
  • E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\render.js
  • E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\build.js
  • E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\index.js
  • E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\cli.js
  • E:\item\vue\vite-build-test\node_modules\vitepress\bin\vitepress.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:982:15)
    at Function.Module._load (internal/modules/cjs/loader.js:864:27)
    at Module.require (internal/modules/cjs/loader.js:1044:19)
    at require (internal/modules/cjs/helpers.js:77:18)
    at E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:1659:12
    at loadPage (E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:75:18)
    at Object.go (E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:68:12)
    at Object.renderPage (E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\render.js:18:12)
    at Object.build (E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\build.js:29:32) {
    code: 'MODULE_NOT_FOUND',
    requireStack: [
    'E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js',
    'E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\render.js',
    'E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\build\build.js',
    'E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\index.js',
    'E:\item\vue\vite-build-test\node_modules\vitepress\dist\node\cli.js',
    'E:\item\vue\vite-build-test\node_modules\vitepress\bin\vitepress.js'
    ]
    }
    ✖ rendering pages...
    build error:
    TypeError: Cannot destructure property 'frontmatter' of 'route.data' as it is null.
    at E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:1318:14
    at ComputedRefImpl.reactiveEffect [as effect] (E:\item\vue\vite-build-test\node_modules@vue\reactivity\dist\reactivity.cjs.prod.js:46:24)
    at ComputedRefImpl.get value [as value] (E:\item\vue\vite-build-test\node_modules@vue\reactivity\dist\reactivity.cjs.prod.js:774:32)
    at E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:1338:36
    at ComputedRefImpl.reactiveEffect [as effect] (E:\item\vue\vite-build-test\node_modules@vue\reactivity\dist\reactivity.cjs.prod.js:46:24)
    at ComputedRefImpl.get value [as value] (E:\item\vue\vite-build-test\node_modules@vue\reactivity\dist\reactivity.cjs.prod.js:774:32)
    at Object.unref (E:\item\vue\vite-build-test\node_modules@vue\reactivity\dist\reactivity.cjs.prod.js:693:29)
    at E:\item\vue\vite-build-test\node_modules\vitepress\dist\client\app\temp\app.js:1347:71
    at renderComponentSubTree (E:\item\vue\vite-build-test\node_modules@vue\server-renderer\dist\server-renderer.cjs.prod.js:208:13)
    at renderComponentVNode (E:\item\vue\vite-build-test\node_modules@vue\server-renderer\dist\server-renderer.cjs.prod.js:174:16)
    error Command failed with exit code 1.
    info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
@heny heny added the bug: pending triage Maybe a bug, waiting for confirmation label Jan 31, 2021
@kiaking
Copy link
Member

kiaking commented Feb 10, 2021

Confirmed. Seems like multi byte file name gets encoded in some special value. Not sure where the root cause is. Need to look into it.

@kiaking kiaking added bug Something isn't working and removed bug: pending triage Maybe a bug, waiting for confirmation labels Feb 10, 2021
YunYouJun pushed a commit to YunYouJun/vitepress that referenced this issue Aug 30, 2021
@kiaking kiaking added this to the v1.0.0 milestone May 27, 2022
@brc-dd
Copy link
Member

brc-dd commented May 30, 2022

Was fixed by your PR #262.

@brc-dd brc-dd closed this as completed May 30, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants