question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

fastify.next is not a function

See original GitHub issue

You have already researched for similar issues?

Yes. I searched in the issue list and could n’t find any.

Are you sure this is an issue with the fastify or are you just looking for some help?

The issue seem to be in fastify-nextjs plugin.

Steps to reproduce.

  1. clone https://github.com/fastify/fastify-nextjs.git
  2. cd fastify-nextjs && npm install
  3. run npm run dev

node version: v12.16.1 npm : 6.13.4

Error: image

If you have issues with the fastify.io site, please open an issue here.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
puvi034commented, May 23, 2020

This issue seem to be a timeout issue and by default fastify wait for 10 secs. Changed timeout period and it started working.

1reaction
wolfejw86commented, Jul 7, 2021

For what it’s worth I’m not seeing this as related to a timeout. I get this behavior immediately when setting NODE_ENV=production. Has anyone come across this / figured out a way to solve it?

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: fastify.next is not a function · Issue #384 - GitHub
I found that the plugin was not executed after preparation. app.prepare().then(()=>{ // Not performed }). Steps to Reproduce. package.json.
Read more >
TypeError : next() is not a function - node.js - Stack Overflow
I have two functions with the exact code but they check for different schemas. My first function runs without any exception. However, when...
Read more >
Server - Fastify
serverFactory is a function that takes a handler parameter, which takes the request and response objects as parameters, and an options object, which...
Read more >
@fastify/nextjs - npm
js framework. This library is for letting an existing Fastify server utilize NextJS, not for replacing NextJS' internal webserver with Fastify.
Read more >
Building a Full-stack App with Next.js - Arctype
By default, Next.js does not use Fastify as its server. To use Fastify to serve our Next.js app, edit the scripts field in...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found