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.

SemVer breakage re: NoDeprecatedCustomRule from graphql

See original GitHub issue

The graphql-language-service-interface package, in going from version 2.4.2 to 2.4.3, relies on an export from graphql named NoDeprecatedCustomRule. The graphql package added this export in v15.2.0. Furthermore, codemirror-graphql revved its dependency version on graphql-language-service-interface from 2.4.2 to 2.4.3 (requiring this change) when it went from 0.12.3 to 0.12.4. My dependency on graphiql, which worked fine with my version of graphql at 14.x, on the publish of these new packages, started breaking, with a compiler error stating that 'NoDeprecatedCustomRule' is not exported from 'graphql'. Now my package.json needs to pin both codemirror-graphql to 0.12.3 and graphql-language-service-interface to 2.4.2 so that I can remain compatible with graphql at v14.

… * sigh *

Y’all… this is a mess, and it sucked up a bunch of my time because my builds started failing when I hadn’t changed any code. For already-published packages, there’s not really much you can do, but in the future, can you please be more aware of this kind of thing? In particular, the peerDependencies for graphql-language-service-interface are incorrect, as this package relies on graphql@^15.2.0 (since it needs NoDeprecatedCustomRule introduced at that version) and appears to no longer be compatible with 14.x.

Thanks for your consideration. Let me know if I can provide any more information.

Issue Analytics

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

github_iconTop GitHub Comments

1reaction
floyd-maycommented, Dec 10, 2020

peerDependencies are… fun… Might I suggest a compile against the oldest acceptable version in the peerDependencies somewhere in the CI/CD chain? That would have definitely caught this.

1reaction
floyd-maycommented, Dec 9, 2020

Works for me!

Read more comments on GitHub >

github_iconTop Results From Across the Web

GraphQL: Fixing Breaking Schema Changes
Below, we'll walk through the problem and a clever solution involving rewriting breaking queries in middleware. tldr; if you're using Node JS, ...
Read more >
Versioning fields in GraphQL - LogRocket Blog
Breaking changes are those that remove a type, field, or directive, or modify the signature of an already existing field (or directive), such...
Read more >
semver versioning · Issue #230 - GitHub
Sorry for breaking your build! We should definitely have chosen at least a minor version bump, not just patch. We didn't release a...
Read more >
Semantic Versioning 2.0.0 | Semantic Versioning
In systems with many dependencies, releasing new package versions can quickly become a nightmare. If the dependency specifications are too tight, you are...
Read more >
Best Practices for Versioning REST and GraphQL APIs - Moesif
breaks backward compatibility, z is incremented. If y is incremented, then x is reset to 0 and if z is incremented y and...
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