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
Does the tf-next 1.0.0 canary5 supports middleware from Next 12.2? It has been changed because from developer perspective, now we are using file middleware.ts at the root of the app instead _middleware.ts in pages.
After my investigation I noticed that tf-next 1.0.0 canary 5 has a trouble it while using command tf-next build. The error that appears is the following.
info - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules
info - Linting and checking validity of types
info - Disabled SWC as replacement for Babel because of custom Babel configuration ".babelrc" https://nextjs.org/docs/messages/swc-disabled
info - Using external babel configuration from /private/var/folders/ky/64jxxk4n7k1bmhzcbz0zn2740000gn/T/tmp-15280-zg5kTWAsNr1g/.babelrc
info - Creating an optimized production build
info - Compiled successfully
info - Collecting page data
info - Generating static pages (13/13)
info - Finalizing page optimization
> Build error occurred
[Error: ENOENT: no such file or directory, open '/private/var/folders/ky/64jxxk4n7k1bmhzcbz0zn2740000gn/T/tmp-11918-8LTrk8VsTpg2/.next/server/edge-runtime-webpack.js'] {
errno: -2,
code: 'ENOENT',
syscall: 'open',
path: '/private/var/folders/ky/64jxxk4n7k1bmhzcbz0zn2740000gn/T/tmp-11918-8LTrk8VsTpg2/.next/server/edge-runtime-webpack.js'
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Build failed:
NowBuildError: Command "yarn run build" exited with 1
at ChildProcess.<anonymous> (/Users/kamilmastalerz/.nvm/versions/node/v16.15.1/lib/node_modules/tf-next/node_modules/@vercel/build-utils/dist/index.js:33545:20)
at ChildProcess.emit (node:events:527:28)
at ChildProcess.emit (node:domain:475:12)
at maybeClose (node:internal/child_process:1092:16)
at Process.ChildProcess._handle.onexit (node:internal/child_process:302:5) {
hideStackTrace: true,
code: 'BUILD_UTILS_SPAWN_1',
link: undefined,
action: undefined
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
I have used before yarn build and everything is fine. Does anyone has a tips how to workaround it. Please fix it because it seems to be an issue on library site
The text was updated successfully, but these errors were encountered:
MastalerzKamil
changed the title
Error while using middleware from Next 12.2
[Bug] Error while using middleware from Next 12.2
Oct 9, 2022
Middleware is not supported with Lambda and Lambda@Edge, as mentioned both in the top of README and in this issue: #273 (comment)
I would love for middleware support myself, but this seems to be a limitation with AWS, according to both the author of this projects and other projects (serverless-nextjs).
This, coupled with lack of support for redirects in getServerSideProps, means i am currently unable to use this project for any real-world usage.
Does the
tf-next 1.0.0 canary5
supports middleware fromNext 12.2
? It has been changed because from developer perspective, now we are using filemiddleware.ts
at the root of the app instead_middleware.ts
in pages.After my investigation I noticed that
tf-next 1.0.0 canary 5
has a trouble it while using commandtf-next build
. The error that appears is the following.I have used before
yarn build
and everything is fine. Does anyone has a tips how to workaround it. Please fix it because it seems to be an issue on library siteThe text was updated successfully, but these errors were encountered: