-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Spacemacs ignores url-proxy-services #4807
Comments
EDIT: Actually, it works for me if I do emacs --insecure. I'm having the same problem. I'm using ubuntu 14.04. For now, I took all the ipv6 lines out of /etc/hosts (I read that was a possible issue). These are the lines I've put into init.el at the top.
In messages, I see these lines:
I'm not sure what else to try |
I have this problem on Mac OS X as well. I get around the update problem by launching emacs from the terminal (where I have http[s]_proxy set) when I want to do updates. When it's launched as an app, it seems to ignore system proxy settings. |
I am having the same issue on Windows, using spacemacs-0.105.9. The proxy settings seem to be ignored when running the app. Passing the |
The only way I can use spacemacs behind our proxy at work is to install cntlm. Then putting my proxy settings on the first line of my .emacs.d/init.el.
We could do with a dotspacemacs proxy variable which comes into play before emacs contacts for updates layers etc. I'm not quite sure where this would be, but I am guessing before the dotspacemacs-configuration-layers, so that we do not have to mess with the .emacs.d/init.el. System win 7, emacs 24.5.1, spacemacs-0.105.9 |
For me this issue is actually related to the emacs for mac build. When I use the official emacs build everything works as normal (except for the known problems with spacemacs + official build for macs) |
Do you all have your Emacs should pickup the proxy settings automatically if those variables are set. |
I have the same problem on linux where I connect to the internet through a proxy. The http_proxy and https_proxy is set. However installing spacemacs is only possible if i specify the --insecure flag. After restarting emacs, I get the same error messages as above and it does not matter if --insecure is specified or not when emacs is invoked. |
@syl20bnr Yes, those variables are exported in my .zprofile. When I run from the terminal, it works fine. It's only when launched as an app (from spotlight actually) that the problem happens. |
Is there any progress on this? I am having the same problem (Windows system using cntlm as a proxy). Using the +1 for some means of setting proxy values in the spacemacs config (preferably on a per-system basis, so that I can share my config across machines and only have the proxy enabled on the machine that uses it). |
... ah, I see that |
@xoltar It makes sense as your .zprofile always applies to your terminal, not the gui version. I don't think anybody picked up on what sylv20bnr said. You need to make sure those env variables are set. To do so, evaluate this in emacs: If you wish to set an env variable from within emacs: |
Your config is just a bunch of functions that can execute arbitrary code, so there's nothing preventing you from using conditionals to set variables. They don't have to be constant values. |
Looks like there might be an issue with HTTPS on Windows. From https://melpa.org/#/getting-started:
So, to summarise:
Hopefully, this is of some use to others encountering this issue (on Windows, at least). |
Well, yes and no. Things like |
I think it's fairly obvious that you have to set it in the same function where it's being set in the template. In the template, |
I'm confused. But I need to learn the basics before over-complicating things. At the moment, I've only just got spacemacs installed for the first time (the install broke because of the proxy issues) so it's a bit early for me to be looking at complex config. Emacs always feels a bit like that to me, though - basic behaviour doesn't quite work, so before I know what's happened, I'm writing complicated elisp rather than actually doing the editing I planned on :-) |
For user code running just after |
Right, sorry. It does say that. Anyway it won't stop you. :-P |
The challenge is when you are in a Windows context and you install spacemacs from behind an authenticated proxy.
Now things should proceed correctly. I think the correct solution is to have spacemacs:
|
@taqtiqa-mark, thank you. you save my life. |
Closing this, I'm no longer behind a proxy at work so I have no way to test or verify that this is still occuring. |
I think @hackrole and other reports here confirm this is still an issue. Is there a PR or commit that might indicate the issue has been resolved? |
+1 behind a corporate proxy and I'm seeing this. Spacemacs launched from terminal with --insecure flag works, but when launched as a desktop app it doesn't work. Running on Ubuntu 18. My http_proxy and https_proxy are set on the os |
(setq url-proxy-services |
I am reopening this issue as people are still affected. Let's leave it open until workaround or fix is found. @taqtiqa-mark can you please try the suggestion made by @TBusen ? |
@d12frosted, I believe @TBusen repeats some part of what I describe here. I gave an begin-to-end description that worked for me and the others voting thumbs up. Have I misunderstood what you want me to try? |
@taqtiqa-mark my bad, I missed that you are the author of that long comment describing a work around. |
I don't know if this will be of any help but on the off chance: Git on Windows works for me from behind a proxy. For the AUTHENTICATION to work seamlessly and securely (not clear text passwords) the environment variable "GIT_credential_helper" is set to 'wincred' In cmd.exe this would look like this (before running Git):
or for PowerShell
If someone were trying to provide a full fix, taking a look at the Git code might be useful. |
@HerbM my understanding: the issue here is to configure spacemacs such that spacemacs package installs and updates 'just-work'. The Are you saying that by setting |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid! |
Yes. @taqtiqa-mark (apologies, this went stale and old, my fault for not answering but for completeness here it is.) Yes, if "git clone" just works (proving the paths and credentials are correct then it would be very nice if spaceemacs did this same. Better if it read or used the .gitconfig that made the rest work (or a better method) but even having to configure the settings again in spaceemacs would be "good enough". Thanks. |
There is a bug in See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=42422, fixed in Emacs 28.1 apparently. With orgmode.org/elpa and melpa changing to https only, this problem became more visible. As a workaround till 28.1 arrives, override the function with fixed version:
|
Hello!
I used to use Spacemacs behind a proxy however recently it's stopped using my proxy settings. I used to keep the proxy in user-init however it would try to check the various repositories (melpa,elpa,gnu) before user-init seemed to run.
I added my proxy settings to init.el however spacemacs still ignores them when contacting the repos. I have tried using emacs --insecure and issue persists. I verified that it's completely ignoring the proxy settings by leaving the proxy set but connecting to another network with no proxy on it and Spacemacs installed. (it should have timed out looking for the proxy)
I can provide any additional info requested. Thanks for reading and thanks for making Spacemacs!
EDIT: I am running OSX
The text was updated successfully, but these errors were encountered: