# Pkg.add/clone/update doesn't work behind corporate proxy unless run in Juno

**URL:** <https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889>\
**Category:** General Usage\
**Created:** [December 21, 2017, 5:54am UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889 "2017-12-21T05:54:57Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![xiaodai](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/xiaodai/32/15937_2.png) [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Post date:** [December 21, 2017, 5:54am UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/1 "2017-12-21T05:54:57Z")

</div>

I tried to do

```julia
Pkg.update()

```

which works in Juno but not in Julia REPL nor VSCode. This is the message I get.

```julia
ERROR: METADATA cannot be updated. Resolve problems manually in C:\User\usernameA\.julia\v0.6\METADATA.
GitError(Code:ERROR, Class:OS, failed to send request: The server name or address could not be resolved
)

```

R used to have these type of issues years ago and you can fix it by running `setinternet2()` which tells R to use the same proxy as Internet Explorer. Somehow Juno is doing it correctly. Can we please implement the same in VSCode’s Julia extension?

It is extremely important to have this feature to get wider corporate adoption of Julia. For people like us who work behind a corporate proxy we need auto detection etc to enable a smooth experience. Wish I know more and can contribute a solution but “bug” reports like this is the best I can do. Also I don’t understand networking and corporate proxies/firewall enough to give a more precise definition.

---

<div class="post-metadata">

**Author:** ![davidanthoff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/davidanthoff/32/223493_2.png) [@davidanthoff](https://discourse.julialang.org/u/davidanthoff)\
**Post date:** [December 21, 2017, 5:57am UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/2 "2017-12-21T05:57:05Z")

</div>

So we just host the julia REPL in VS Code. I don’t know why this doesn’t work, but the way to fix this is to get it to work in the REPL, and then it should also work in VS Code.

---

<div class="post-metadata">

**Author:** ![amellnik](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/amellnik/32/137_2.png) [@amellnik](https://discourse.julialang.org/u/amellnik)\
**Post date:** [December 21, 2017, 4:26pm UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/3 "2017-12-21T16:26:41Z")

</div>

What julia version are you using? 0.5+ has worked for using just by setting `HTTP_PROXY` and `HTTPS_PROXY` environment variables.

---

<div class="post-metadata">

**Author:** ![xiaodai](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/xiaodai/32/15937_2.png) [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Post date:** [December 21, 2017, 7:57pm UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/4 "2017-12-21T19:57:53Z")

</div>

i tried setting proxy once but it ddin’t support `%winusser%` or such global system variables on Windows. Also can’t these be auto detected like in Juno and in R? Most corporate user won’t know what a proxy is. So removing that friction can only help adoption.

---

<div class="post-metadata">

**Author:** ![pfitzseb](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pfitzseb/32/45566_2.png) [@pfitzseb](https://discourse.julialang.org/u/pfitzseb)\
**Post date:** [December 21, 2017, 8:29pm UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/5 "2017-12-21T20:29:55Z")

</div>

AFAIK Juno doesn’t do anything differently than the REPL or VSCode. You might want to check your environment variables though (compare `ENV` in Juno and the REPL) – Atom is kinda notorious for messing with those.

---

<div class="post-metadata">

**Author:** ![xiaodai](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/xiaodai/32/15937_2.png) [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Post date:** [December 21, 2017, 11:06pm UTC](https://discourse.julialang.org/t/pkg-add-clone-update-doesnt-work-behind-corporate-proxy-unless-run-in-juno/7889/6 "2017-12-21T23:06:18Z")

</div>

it’s actually preferable to mess with it of that’s the case.
