Skip to content

An issue with the Apollo Federation dependency.Β #1782

@NeutronScott12

Description

@NeutronScott12

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

Well, I don't know if I should be bugging Apollo or you guys, but all of a sudden I got this error -

The "@apollo/federation/dist/directives" package is missing. Please, make sure to install this library ($ npm install @apollo/federation/dist/directives) to take advantage of SchemaBuilder

I tried re-installing node_modules, checking for newer versions. I haven't check older versions, but I haven't updated for at least a week, so it's a weird problem.

I suspect either some change happened to your Graphql module or apollo changed something.

"@nestjs/graphql": "^9.0.5"

It could be a yarn workspace issue as well, so many edge cases.

Minimum reproduction code

https://github.com/OGNeutron/TheLastHurrah/tree/master/packages/the-last-hurrah-commence

Steps to reproduce

No response

Expected behavior

Well, I install it and it works. πŸ‘

Package

  • I don't know. Or some 3rd-party package
  • @nestjs/common
  • @nestjs/core
  • @nestjs/microservices
  • @nestjs/platform-express
  • @nestjs/platform-fastify
  • @nestjs/platform-socket.io
  • @nestjs/platform-ws
  • @nestjs/testing
  • @nestjs/websockets
  • Other (see below)

Other package

@nestjs/graphql

NestJS version

8.0.10

Packages versions

"dependencies": {
"@casl/ability": "^5.4.3",
"@casl/prisma": "^1.0.0",
"@nestjs/axios": "^0.0.2",
"@nestjs/common": "^8.0.10",
"@nestjs/config": "^1.0.2",
"@nestjs/core": "^8.0.10",
"@nestjs/graphql": "^9.0.5",
"@nestjs/jwt": "^8.0.0",
"@nestjs/microservices": "^8.0.10",
"@nestjs/passport": "^8.0.1",
"@nestjs/platform-express": "^8.0.10",
"@nestjs/throttler": "^2.0.0",
"@nestjs/typeorm": "^8.0.2",
"@prisma/client": "^3.2.1",
"@thelasthurrah/the-last-hurrah-shared": "^0.0.5",
"apollo-server-cache-redis": "^3.1.0",
"apollo-server-express": "^3.3.0",
"axios": "^0.22.0",
"class-validator": "^0.13.1",
"cross-env": "^7.0.3",
"graphql": "^15.6.1",
"graphql-type-json": "^0.3.2",
"helmet": "^4.6.0",
"ioredis": "^4.27.10",
"joi": "^17.4.2",
"passport": "^0.5.0",
"passport-jwt": "^4.0.0",
"passport-local": "^1.0.0",
"pg": "^8.7.1",
"reflect-metadata": "^0.1.13",
"rimraf": "^3.0.2",
"rxjs": "^7.2.0",
"ts-morph": "^12.0.0",
"typeorm": "^0.2.37",
"yup": "^0.32.9"
},
"devDependencies": {
"@nestjs/cli": "^8.1.2",
"@nestjs/schematics": "^8.0.0",
"@nestjs/testing": "^8.0.10",
"@types/express": "^4.17.13",
"@types/jest": "^27.0.1",
"@types/node": "^16.10.2",
"@types/passport-jwt": "^3.0.6",
"@types/passport-local": "^1.0.34",
"@types/supertest": "^2.0.11",
"@typescript-eslint/eslint-plugin": "^4.33.0",
"@typescript-eslint/parser": "^4.33.0",
"eslint": "^7.30.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-prettier": "^4.0.0",
"jest": "^27.2.4",
"prettier": "^2.3.2",
"prisma": "^3.2.0",
"supertest": "^6.1.3",
"ts-jest": "^27.0.3",
"ts-loader": "^9.2.3",
"ts-node": "^10.0.0",
"tsconfig-paths": "^3.10.1",
"typescript": "^4.3.5"
},

Node.js version

16.8.0

In which operating systems have you tested?

  • macOS
  • Windows
  • Linux

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions