Closed andylhxu closed 6 years ago
There isn't any support yet but that's indeed a good idea!
It would be nice to have it since I bet a lot of the use cases are inside internal networks.
Hi @andylhxu, I took some time to look a lil deeper at the issue.
hackernews.el
uses url.el
, I believe that setting url-proxy-services
might suffice.
I grabbed the following snippet from a StackOverflow answer:
(setq url-proxy-services '(("no_proxy" . "work\\.com")
("http" . "proxy.work.com:911")))
@clarete Yep, I have the proxy set up because i need to packages from melpa from the internal network. However, it didn't work for the hackernews client.
Tried today with proxies configured. Works for downloading packages from melpa/elpa, but doesn't work for hackernews... web access to news.ycombinator.com is not blocked so I assumed that the backend APIs shouldn't as well?
@andylhxu, let's reopen this bug if your test confirms that it's not enough.
confirmed, the proxy configuration with url-proxy-service
is not sufficient.
OK! Let's reopen the issue and figure out how it could work! Thanks for testing that!
For what it's worth, here are the relevant nodes from the url.el
manual on proxies and gateways in general.
@andylhxu It would be very helpful if you could provide some more information on this. For example, what is your emacs-version
? Have you tried setting url-debug
to t
and inspecting the contents of the *URL-DEBUG*
buffer?
The only differences between package.el
and hackernews.el
in their usage of url.el
are:
package-archives
used to default to HTTP addresses in older versions of Emacs (but not anymore), whereas hackernews.el
always uses HTTPS access points; andpackage.el
defaults to asynchronous retrieval via url-retrieve
, whereas hackernews.el
always does synchronous retrieval via url-retrieve-synchronously
.Re: (1), can you please check whether your package-archives
include any HTTPS addresses? Do other uses of TLS work for you, e.g. M-xeww
REThttps://gnu.org
RET? Newer versions of Emacs have GnuTLS built-in, which makes working with TLS much faster and more reliable from what I gather. If you are on an older Emacs, perhaps it's just a matter of modifying your GnuTLS configuration.
Re: (2), can you try setting package-menu-async
to nil
and see if M-xlist-packages
RET still works for you?
I have a feeling this issue might be caused by GNU Emacs bug#11788, which should be fixed in Emacs 26.
@andylhxu Any chance you can try it out in Emacs 26 and report back?
Either way I'm closing this issue as I don't think there is much hackernews
can do. If the proxy still does not work for you in Emacs 26, please consider filing a bug via M-xreport-emacs-bug
RET.
Ack. Thanks for following this up.
Sorry for not following this up on time. I will definitely try it out and report back asap 👍
Sorry for not following this up on time. I will definitely try it out and report back asap
No worries and good luck. :)
Are there supports for setting up HTTP proxies for the HN emacs client?