Skip to content

Apollo + Fastify version conflicts #3554

Open
@roypeled

Description

@roypeled

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

Trying to upgrade nestjs to latest versions I encounter peer deps conflicts.
I am using fastify, so I have @nestjs/platform-fastify installed.
upgraded to v11 it has a peer dep to "fastify": "5.3.0".

I upgraded @nestjs/apollo to 13.1.0.
it has a peer dep to @as-integrations/fastify: 2.1.1

@as-integrations/fastify has not been updated for the past 2 years.
It has a peer dependency to "fastify": "^4.4.0".

Running the server without @as-integrations/fastify breaks with an error The "@as-integrations/fastify" package is missing. Please, make sure to install it to take advantage of GraphQLModule from this line(https://github.com/nestjs/graphql/blob/master/packages/apollo/lib/drivers/apollo-base.driver.ts#L179)

However the @nestjs/apollo documentation doesn't even mention this lib: https://www.npmjs.com/package/@nestjs/apollo instead asking to install apollo-server-fastify which has been deprecated (https://www.npmjs.com/package/apollo-server-fastify)

If there is any alternative, please suggest it, otherwis issue a breaking change to the latest versions describing that apollo no longer supports fastify.

Minimum reproduction code

https://www.npmjs.com/package/apollo-server-fastify

Steps to reproduce

npm i @nestjs/platform-fastify
npm i @nestjs/apollo
npm I fastify
npm i @as-integrations/fastify OR npm i apollo-server-fastify

Expected behavior

either remove @as-integrations/fastify dependency or deprecate fastify

Package version

13.1.0

Graphql version

graphql: 16.10.0
apollo-server-express: NA
apollo-server-fastify: 3.13.0

NestJS version

11.0.16

Node.js version

v20.18.1

In which operating systems have you tested?

  • macOS
  • Windows
  • Linux

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions