Code Monkey home page Code Monkey logo

Comments (11)

OmichronAgain avatar OmichronAgain commented on June 14, 2024 1

Yup, seems to work!

I tested various orderings of using proxy/not using proxy (in a Docker container so different tests did not influence each other) and it no longer does the update check every time. Thank you for the hard work!

Now just have to wait for #1531 to land...

from cli.

jkbrzt avatar jkbrzt commented on June 14, 2024

Thanks for the report. This is supposed to happen infrequently. Will fix.

from cli.

tgrushka avatar tgrushka commented on June 14, 2024

Still happening. Very annoying testing a proxy server getting an extra request on every request.

from cli.

OmichronAgain avatar OmichronAgain commented on June 14, 2024

Still happening on the latest version (3.2.2).
While having a periodic update check may be useful, perhaps there could be an option in the config file to disable it entirely?
Either way, the additional request on every invocation makes it significantly harder to use for testing a proxy setup.
Any solution would be appreciated.

from cli.

Ousret avatar Ousret commented on June 14, 2024

I tried to reproduce but without success. Can, everyone in this thread, post the debug output so that we can establish the common factor?

from cli.

thenbe avatar thenbe commented on June 14, 2024

I can reproduce this still on 3.2.2. @Ousret To help you reproduce this, can you share what method you're using to detect the request? (I mentioned a couple of example methods in my original post)

from cli.

OmichronAgain avatar OmichronAgain commented on June 14, 2024

@Ousret running mitmproxy listening on port 8080.

Running HTTPS_PROXY=http://localhost:8080 https --verify=no get example.com once results in
image

Running the same command twice results in
image

No matter what kind of request I make with HTTPie, it always fires off a check to packages.httpie.io every time.

Getting the debug output:
image

Hopefully this is useful.

from cli.

Ousret avatar Ousret commented on June 14, 2024

Found the origin of this situation. A fix is available in #1531
To preview it, run the following pip install "git+https://github.com/Ousret/HTTPie.git@feature-tryout-niquests" -U

from cli.

Ousret avatar Ousret commented on June 14, 2024

Can you test the patch and report back? If it solved your issue or not.

from cli.

OmichronAgain avatar OmichronAgain commented on June 14, 2024

@Ousret well, it's certainly different.
image

It seems that HTTPie is still issuing the requests, but now doesn't trust the proxy's cert (even with --verify=no).

from cli.

Ousret avatar Ousret commented on June 14, 2024

HTTPie initially set verif=False (v3.x) for fetching latest versions information from the server, the given PR let it (cert verif) by default. If you don't use mitmproxy and the request succeed, it will stop doing it.
Nonetheless, I applied an additional measure that (i) consider a failure sufficient to stop trying (ii) forward the verify argument to it.

You can try to install the patch again, it should be OK now.

from cli.

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.