Giter Site home page Giter Site logo

Update reqwest to 0.12 about cynic HOT 5 CLOSED

russellbanks avatar russellbanks commented on September 17, 2024
Update reqwest to 0.12

from cynic.

Comments (5)

obmarg avatar obmarg commented on September 17, 2024 1

There are things I'm considering to make this less of an issue in the meantime though. Either:

  1. I could probably add reqwest version specific features. Like if reqwest 0.13 came out next week maybe I'd add that as a separate reqwest-13 feature rather than just breaking everything.
  2. I have also been considering moving the http integrations out of cynic and into a separate library. I'd maybe be less hesitant to bump the major version of that theoretical library when faced with a reqwest version bump, since it'd be closer to the core of the library.

Can't guarantee 2 will happen anytime soon - but I'll at least try to remember 1 next time there's a reqwest bump.

from cynic.

obmarg avatar obmarg commented on September 17, 2024

Unfortunate limitation of 0.x versions this. I'll upgrade when I get a minute, should be easy.

Though you're welcome to make a PR in the meantime if you're up for it.

from cynic.

amnn avatar amnn commented on September 17, 2024

Heads up -- I ran into an issue where the same code seemed to hit this issue (run_graphql method not found in 'RequestBuilder') in one project, but not in another, and it was due to this change by introduced as part of a patch release of cynic.

If you have a Cargo.toml like this:

[dependencies]
cynic = { version = "3.4.3", features = ["http-reqwest"] }
reqwest = "0.11"

and a lock file is generated from it prior to this change, then it will continue to work after #875 lands, because cynic has been resolved to 3.4.3 and won't pick up the bump to cynic's dependency on reqwest.

If I use the same set of dependencies in a new project, it will fail because the version bound on cynic will be resolved to 3.7.3 implicitly on lock file generation (including #875), while the same thing doesn't happen to the patch version of reqwest because it's pre 1.0.

It seems like the version bump on reqwest should be treated as a breaking change (gated by a major version bump) for cynic?

from cynic.

obmarg avatar obmarg commented on September 17, 2024

Yeah, sorry for the hassle @amnn - but my policy is generally to do a minor bump when bumping public dependencies by a minor version.

Which is what happened - this was released in 3.5.0 not a patch release.

I can see the argument for it being a breaking change, but I'm not really happy tying my major versions into the minor versions of an optional dependency. Hopefully reqwest hits v1 sometime and this might become less of a problem.

from cynic.

amnn avatar amnn commented on September 17, 2024

No worries, either of those options seem reasonable to me -- main thing is avoiding the confusing interaction between Cargo's default behaviour in accepting patch/minor bumps and the implications of a minor bump on a pre-1.0 version!

from cynic.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.