Closed eric-cortes closed 2 years ago
Following up on this, just started happening to us randomly.
This is happening up deploy to vercel
Try adding a random team in WP. Like test or something like that and then rebuild and deploy. Let me know if that helps We did that...
@sloyer @bosconfoona this is likely due to us removing built-in CPTs from our backend headless repos. If your WP install does not register the team
CPT, this may happen on your frontend. We're working on cleaning up this repo (e.g., removing CPT handling from the frontend), but in the meantime, you should be able to fix the issue by removing your local nextjs-wordpress-starter/pages/team
directory.
Thanks for taking the time to file a bug report! Please fill out this form as completely as possible.
If you leave out sections there is a high likelihood it will be moved to our GitHub Discussions.
Describe the bug Error after npm run build
^CMy-User:nextjs-wordpress-starter myuser$ npm run build
info - Loaded env from /Users/myuser/Local Sites/example-page/app/public/wp-content/themes/nextjs-wordpress-starter/.env info - Using webpack 5. Reason: Enabled by default https://nextjs.org/docs/messages/webpack5 (node:11707) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification. (Use
node --trace-warnings ...
to show where the warning was created) info - Checking validity of typesinfo - Using external babel configuration from /Users/myuser/Local Sites/example-page/app/public/wp-content/themes/nextjs-wordpress-starter/.babelrc info - Creating an optimized production build
info - Compiled successfully
npm ERR! A complete log of this run can be found in: npm ERR! /Users/myuser/.npm/_logs/*-debug.log
Steps to reproduce the behavior: npm run build in nextjs-wordpress-starter theme folder
Expected behavior Next standard build in .next folder
Screenshots If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Additional context Add any other context about the problem here.