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

Dashboard: build fails with NODE_ENV=development #448

Closed
jamiehewitt15 opened this issue May 15, 2024 · 0 comments
Closed

Dashboard: build fails with NODE_ENV=development #448

jamiehewitt15 opened this issue May 15, 2024 · 0 comments
Assignees
Labels
Type: Bug Something isn't working

Comments

@jamiehewitt15
Copy link
Member

See logs below for details:

root@Alex-desktop-ryzen:/repos/ocean/ocean-node# export NODE_ENV=development
root@Alex-desktop-ryzen:/repos/ocean/ocean-node# npm run build
> [email protected] build
> npm run clean && npm run build:tsc && npm run build:dashboard
> [email protected] clean
> rm -rf ./dist/ ./doc/ ./.nyc_output
> [email protected] build:tsc
> tsc --sourceMap
> [email protected] build:dashboard
> cd dashboard && npm install && npx next build
up to date, audited 1301 packages in 2s
210 packages are looking for funding
  run `npm fund` for details
2 vulnerabilities (1 moderate, 1 high)
To address issues that do not require attention, run:
  npm audit fix
To address all issues, run:
  npm audit fix --force
Run `npm audit` for details.
 ⚠ You are using a non-standard "NODE_ENV" value in your environment. This creates inconsistencies in the project and is strongly advised against. Read more: https://nextjs.org/docs/messages/non-standard-node-env
   Linting and checking validity of types  ...
 ⚠ The Next.js plugin was not detected in your ESLint configuration. See https://nextjs.org/docs/basic-features/eslint#migrating-existing-config
 ✓ Linting and checking validity of types
   ▲ Next.js 14.0.4
 ✓ Creating an optimized production build
 ✓ Compiled successfully
 ✓ Collecting page data
   Generating static pages (0/3)  [   =]Error: <Html> should not be imported outside of pages/_document.
Read more: https://nextjs.org/docs/messages/no-document-import-in-page
    at ed (/repos/ocean/ocean-node/dashboard/node_modules/next/dist/compiled/next-server/pages.runtime.prod.js:16:5484)
    at y (/repos/ocean/ocean-node/dashboard/.next/server/chunks/859.js:6:1299)
    at renderWithHooks (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5658:16)
    at renderIndeterminateComponent (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5731:15)
    at renderElement (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5946:7)
    at renderNodeDestructiveImpl (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6104:11)
    at renderNodeDestructive (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6076:14)
    at renderIndeterminateComponent (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5785:7)
    at renderElement (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5946:7)
    at renderNodeDestructiveImpl (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6104:11)
Error occurred prerendering page "/404". Read more: https://nextjs.org/docs/messages/prerender-error
Error: <Html> should not be imported outside of pages/_document.
Read more: https://nextjs.org/docs/messages/no-document-import-in-page
    at ed (/repos/ocean/ocean-node/dashboard/node_modules/next/dist/compiled/next-server/pages.runtime.prod.js:16:5484)
    at y (/repos/ocean/ocean-node/dashboard/.next/server/chunks/859.js:6:1299)
    at renderWithHooks (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5658:16)
    at renderIndeterminateComponent (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5731:15)
    at renderElement (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5946:7)
    at renderNodeDestructiveImpl (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6104:11)
    at renderNodeDestructive (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6076:14)
    at renderIndeterminateComponent (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5785:7)
    at renderElement (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:5946:7)
    at renderNodeDestructiveImpl (/repos/ocean/ocean-node/dashboard/node_modules/react-dom/cjs/react-dom-server.browser.development.js:6104:11)
Error: <Html> should not be imported outside of pages/_document.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants