You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've got running locally within an instance of Docusaurus. Everything works perfectly (and looks great), however when I commit to GitLab, then try to deploy on GitLab pages I get the following error from the CI runner:
[2/4] Fetching packages...
warning [email protected]: Invalid bin entry for "sha.js" (in "sha.js").
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
...
warning " > [email protected]" has incorrect peer dependency "styled-components@^4.1.1".
warning "redoc > swagger2openapi > [email protected]" has unmet peer dependency "[email protected] - 6".
warning " > [email protected]" has unmet peer dependency "react-is@>= 16.8.0".
[4/4] Building fresh packages...
success Saved lockfile.
Done in 47.63s.
$ yarn build
yarn run v1.21.1
$ docusaurus build
Creating an optimized production build...
[info] [webpackbar] Compiling Client
[info] [webpackbar] Compiling Server
[success] [webpackbar] Client: Compiled successfully in 50.81s
[success] [webpackbar] Server: Compiled with some errors in 54.03s
(undefined) ReferenceError: Buffer is not defined
at Object.<anonymous> (main:11393:20)
at __webpack_require__ (main:21:30)
at Object.<anonymous> (main:22525:26)
at __webpack_require__ (main:21:30)
at Object.<anonymous> (main:69961:30)
at __webpack_require__ (main:21:30)
at Object.<anonymous> (main:32476:18)
at __webpack_require__ (main:29216:30)
at Object.<anonymous> (main:32247:14)
at Object.<anonymous> (main:32470:30)
Error: Failed to compile with errors.
at /builds/tripdocs/visitor-platform/node_modules/@docusaurus/core/lib/commands/build.js:37:24
at finalCallback (/builds/tripdocs/visitor-platform/node_modules/webpack/lib/MultiCompiler.js:254:12)
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/MultiCompiler.js:277:6
at done (/builds/tripdocs/visitor-platform/node_modules/neo-async/async.js:2931:13)
at runCompilers (/builds/tripdocs/visitor-platform/node_modules/webpack/lib/MultiCompiler.js:181:48)
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/MultiCompiler.js:188:7
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/MultiCompiler.js:270:7
at finalCallback (/builds/tripdocs/visitor-platform/node_modules/webpack/lib/Compiler.js:257:39)
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/Compiler.js:273:13
at AsyncSeriesHook.eval [as callAsync] (eval at create (/builds/tripdocs/visitor-platform/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:42:1)
at AsyncSeriesHook.lazyCompileHook (/builds/tripdocs/visitor-platform/node_modules/tapable/lib/Hook.js:154:20)
at onCompiled (/builds/tripdocs/visitor-platform/node_modules/webpack/lib/Compiler.js:271:21)
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/Compiler.js:681:15
at AsyncSeriesHook.eval [as callAsync] (eval at create (/builds/tripdocs/visitor-platform/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
at AsyncSeriesHook.lazyCompileHook (/builds/tripdocs/visitor-platform/node_modules/tapable/lib/Hook.js:154:20)
at /builds/tripdocs/visitor-platform/node_modules/webpack/lib/Compiler.js:678:31
**ReferenceError: Buffer is not defined**
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
ERROR: Job failed: command terminated with exit code 1
Any help would be greatly appreciated!
The text was updated successfully, but these errors were encountered:
I have exactly the same issue. After adding ReDoc to docusaurus v2 I get this issue and builds fail.
The solution that worked for me was using the ProviderPlugin as mentioned webpack/changelog-v5#10
Hello,
I've got running locally within an instance of Docusaurus. Everything works perfectly (and looks great), however when I commit to GitLab, then try to deploy on GitLab pages I get the following error from the CI runner:
Any help would be greatly appreciated!
The text was updated successfully, but these errors were encountered: