Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #197393

Re: Pip installs to unexpected place

Path csiph.com!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail
From Keith Thompson <Keith.S.Thompson+u@gmail.com>
Newsgroups comp.lang.python
Subject Re: Pip installs to unexpected place
Date Mon, 14 Apr 2025 15:20:13 -0700
Organization None to speak of
Lines 24
Message-ID <87lds22xnm.fsf@nosuchdomain.example.com> (permalink)
References <CAApdmf2J69WgkR159sBSkxN0=mYoNmHZYboBmpPi+LdA-YBNpg@mail.gmail.com> <020e0ef5-3d53-4f9c-acb5-842a1a971b10@tompassin.net> <CAApdmf0+91Br19ZTa5sh0CLywWhD6wyL5Ou9118cF8D==edJBg@mail.gmail.com> <45c52b56-eb57-4d54-9f91-bee30280d16f@tompassin.net> <mailman.3.1744659206.3008.python-list@python.org>
MIME-Version 1.0
Content-Type text/plain
Injection-Date Tue, 15 Apr 2025 00:20:14 +0200 (CEST)
Injection-Info dont-email.me; posting-host="a2350407d780bb528cb106f4e5e26372"; logging-data="2296845"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/Jzlm2ZdY0ZWMcWge4d0th"
User-Agent Gnus/5.13 (Gnus v5.13)
Cancel-Lock sha1:vLfAtVC5EyyOpDiMrcGOC4tIZUo= sha1:KOJAGcDZGgNF0VC/rplH9VsWAD8=
Xref csiph.com comp.lang.python:197393

Show key headers only | View raw


Thomas Passin <list1@tompassin.net> writes:
[...]
> To activate a venv, you have to source its activate script, which is
> in the venv. First you have to mark it as executable.  Then you source
> it -
>
> source ~/venv/gf4/bin/activate
[...]

No, you don't have to (and probably shouldn't) mark the script as
executable.

Making a script executable (chmod +x) is required before *executing* it,
but when you *source* a script (using "source" or "."), your current
shell reads it and evaluates its content.

Making the active script executable introdues the risk that you'll
accidentally execute it rather than sourcing it.  If you do that, it
will probably set up the environment in a new shell process which then
immediately terminates.

-- 
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
void Void(void) { Void(); } /* The recursive call of the void */

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Re: Pip installs to unexpected place Thomas Passin <list1@tompassin.net> - 2025-04-14 09:55 -0400
  Re: Pip installs to unexpected place rbowman <bowman@montana.com> - 2025-04-14 21:56 +0000
    Re: Pip installs to unexpected place Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2025-04-14 15:31 -0700
  Re: Pip installs to unexpected place Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2025-04-14 15:20 -0700
    Re: Pip installs to unexpected place rbowman <bowman@montana.com> - 2025-04-15 01:12 +0000
    Re: Pip installs to unexpected place Thomas Passin <list1@tompassin.net> - 2025-04-14 23:11 -0400
    Re: Pip installs to unexpected place Thomas Passin <list1@tompassin.net> - 2025-04-14 21:51 -0400

csiph-web