nextra icon indicating copy to clipboard operation
nextra copied to clipboard

Build error when building a Nextra Docs project manually if the path contains Russian characters

Open suprunchuk opened this issue 11 months ago • 2 comments

Bug Report

Description

I'm trying to manually create a new empty project and I'm getting an error. I created a demo folder in a folder called in Russian.

Reproduction Steps

  1. Open the link to manually create a demo project.
  2. Follow the steps outlined in Section 1 under npm installation here to install dependencies and add the required script to the package.json.
  3. Add Next.js Config as per the instructions provided here.
  4. Create Docs Theme Config by referring to the guidelines mentioned here.
  5. Create a test page named index.mdx under the pages directory.
  6. Run your test project using the command npm run dev.

Expected Behavior

The project runs in any folder, regardless of case and language.

Actual Behavior

When I created an intermediate folder and created a project in it, an error appears. ~/Downloads/РусскаяПапка/Demo When I create a project in a folder with English characters in the path, there are no errors. ~/Downloads/Demo

 ✓ Ready in 2.5s
 ○ Compiling / ...
[nextra] Init git repository failed Discover git repo from [C:\Users\Suprunchuk.Pavel.GROUP\Downloads\РусскаяПапка\Demo] failed: could not find repository at 'C:\Users\Suprunchuk.Pavel.GROUP\Downloads\РусскаяПапка\Demo'; class=Repository (6); code=NotFound (-3)
 ⨯ C:UsersSuprunchuk.Pavel.GROUPDownloadsРусскаяПапкаDemo       heme.config.jsx
Module build failed: UnhandledSchemeError: Reading from "C:UsersSuprunchuk.Pavel.GROUPDownloadsРусскаяПапкаDemo heme.config.jsx" is not handled by plugins (Unhandled scheme).
Webpack supports "data:" and "file:" URIs by default.
You may need an additional plugin to handle "c:" URIs.
Import trace for requested module:
C:UsersSuprunchuk.Pavel.GROUPDownloadsРусскаяПапкаDemo  heme.config.jsx

Screenshots/Videos

1

Environment

  • Browser: Google Chrome 122.0.6261.129
  • OS: windows 11 pro.
"next": "^14.1.3",
"nextra": "^2.13.4",
"nextra-theme-docs": "^2.13.4",
"react": "^18.2.0",
"react-dom": "^18.2.0"

Demo project

Create a Russian folder and place it there. Demo.zip

suprunchuk avatar Mar 18 '24 09:03 suprunchuk