Re: magic-wormhole 0.19.0

2025-06-01 Thread MyMilestone Card via Python-list
Thanks for sharing the update, Meejah! Great to see the addition of the status feedback API and improved Dilation handling, those changes should definitely enhance usability and performance. Also appreciate the move to pytest and the clearer packaging per PEP 625. Solid work! -- https://mail.py

Re: magic-wormhole 0.19.2

2025-05-30 Thread meejah
There were a couple of minor problems with 0.19.0 and so I have yanked 0.19.0 and 0.19.1 -- everyone should use 0.19.2. The main issue (and reason for pulling those versions) is that although the release notes say words about requiring Python 3.10, the metadata didn't say that. The metadata is

Re: Python tutor mailing list?

2025-05-28 Thread Marc Nicole via Python-list
Being a user of that list i've also noticed that only recently. hope that this list is good enough to take on all python questions. Are there any other alternative lists? Thx On Wed, 28 May 2025, 01:35 Alan Gauld via Python-list, < python-list@python.org> wrote: > I am the moderator of the python

Re: Searching for a file

2025-05-28 Thread Mats Wichmann
On 5/28/25 03:29, Peter J. Holzer wrote: On 2025-05-28 10:59:16 +0300, Roland Mueller via Python-list wrote: ke 28.5.2025 klo 1.45 Thomas Passin (li...@tompassin.net) kirjoitti: On 5/27/2025 10:41 AM, Roland Mueller via Python-list wrote: To get a list of files in a given directory one can use

Re: Python tutor mailing list?

2025-05-28 Thread Mats Wichmann
On 5/27/25 18:00, Alan Gauld via Python-list wrote: On 28/05/2025 00:32, Alan Gauld via Python-list wrote: The archives are still there and the sign-up page seems to work, but it doesn't recognise me. I tried signing up as a new member with a different address and that seems to work(ie no error

Re: Searching for a file

2025-05-28 Thread Peter J. Holzer
On 2025-05-28 10:59:16 +0300, Roland Mueller via Python-list wrote: > ke 28.5.2025 klo 1.45 Thomas Passin (li...@tompassin.net) kirjoitti: > > On 5/27/2025 10:41 AM, Roland Mueller via Python-list wrote: > > > To get a list of files in a given directory one can use glob.glob and > > > > The OP had

Re: Searching for a file

2025-05-28 Thread Roland Mueller via Python-list
ke 28.5.2025 klo 1.45 Thomas Passin (li...@tompassin.net) kirjoitti: > On 5/27/2025 10:41 AM, Roland Mueller via Python-list wrote: > > To get a list of files in a given directory one can use glob.glob and > > The OP had a different problem. He wanted to find a config file of > known name that co

Re: Python tutor mailing list?

2025-05-27 Thread dn via Python-list
Message received! Hope you enjoyed your holiday... On 28/05/25 12:00, Alan Gauld via Python-list wrote: On 28/05/2025 00:32, Alan Gauld via Python-list wrote: The archives are still there and the sign-up page seems to work, but it doesn't recognise me. I tried signing up as a new member with

Re: Python tutor mailing list?

2025-05-27 Thread Alan Gauld via Python-list
On 28/05/2025 00:32, Alan Gauld via Python-list wrote: > The archives are still there and the sign-up page seems to > work, but it doesn't recognise me. I tried signing up as > a new member with a different address and that seems to work(ie no > errors) but I still don;t see any list activity. I

Re: Searching for a file

2025-05-27 Thread Thomas Passin
On 5/27/2025 10:41 AM, Roland Mueller via Python-list wrote: To get a list of files in a given directory one can use glob.glob and The OP had a different problem. He wanted to find a config file of known name that could be in one of several locations. os.path.isfile from os.path import i

Re: Searching for a file

2025-05-27 Thread Peter J. Holzer
On 2025-05-24 17:18:11 -0600, Mats Wichmann wrote: > On 5/23/25 16:05, Rob Cliffe via Python-list wrote: > > On 23/05/2025 18:55, Mats Wichmann wrote: > > > On 5/22/25 21:04, Rob Cliffe via Python-list wrote: > > > > It occurs to me that it might be useful if Python provided a > > > > function to s

Re: Searching for a file

2025-05-27 Thread Roland Mueller via Python-list
When answering I saw only the post from Peter. Everything else was in SPAM folder. GMail was so kind to move the "junk" mails to my Inbox after pressing SENT :-) My code works in Linux but with a small change it should work in Windows too. ti 27.5.2025 klo 17.41 Roland Mueller (roland.em0...@goog

Re: Searching for a file

2025-05-27 Thread Roland Mueller via Python-list
To get a list of files in a given directory one can use glob.glob and os.path.isfile >>> from os.path import isfile >>> from glob import glob >>> files_in_var_tmp = [f for f in glob('/var/tmp/*') if isfile(f) ] For several directories iterate over the dirs and add the resulting list of files. >>

Re: Searching for a file

2025-05-24 Thread Chris Angelico via Python-list
On Sun, 25 May 2025 at 10:05, Rob Cliffe via Python-list wrote: > Yes, but if I understand correctly, they all start from a single > directory (and work downwards if required). > My suggestion involved searching a *list* (possibly multiple lists) of > directories. for dir in dirs: try: open(d

Re: Searching for a file

2025-05-24 Thread Rob Cliffe via Python-list
On 25/05/2025 00:18, Mats Wichmann wrote: On 5/23/25 16:05, Rob Cliffe via Python-list wrote: On 23/05/2025 18:55, Mats Wichmann wrote: On 5/22/25 21:04, Rob Cliffe via Python-list wrote: It occurs to me that it might be useful if Python provided a function to search for a file with a give

Re: Searching for a file

2025-05-24 Thread Mats Wichmann
On 5/23/25 16:05, Rob Cliffe via Python-list wrote: On 23/05/2025 18:55, Mats Wichmann wrote: On 5/22/25 21:04, Rob Cliffe via Python-list wrote: It occurs to me that it might be useful if Python provided a function to search for a file with a given name in various directories (much as the i

Re: Best practice for config files?

2025-05-24 Thread Michael F. Stemper via Python-list
On 22/05/2025 15.27, Stefan Ram wrote: "Michael F. Stemper" wrote or quoted: Should I specify the location of the config file with a command-line option, or is requiring the program to be executed in the directory containing the configuration file considered acceptable practice? It was me

Re: Best practice for config files?

2025-05-24 Thread Mats Wichmann
On 5/23/25 07:35, Chuck Rhode wrote: On Thu, 22 May 2025 14:59:28 -0500 "Michael F. Stemper" wrote: Is requiring the program to be executed in the directory containing the configuration file considered acceptable practice? Freedesktop.org proposes a specification for where such things ought

Re: Best practice for config files?

2025-05-24 Thread Jason H via Python-list
On 22/05/2025 20:59, Michael F. Stemper wrote: I recently wrote a program to do some record-keeping for me. I found myself hard-coding a bunch of different values into it. This didn't seem right, so I made my first use of configparser.ConfigParser(). Created the configuration file and everything

Re: Best practice for config files? (Posting On Python-List Prohibited)

2025-05-23 Thread rbowman
On Fri, 23 May 2025 22:22:36 - (UTC), Lawrence D'Oliveiro wrote: > On 23 May 2025 19:18:23 GMT, Stefan Ram wrote: > >> Coincidentally, I just read: >> >> |When IDLE first starts, it attempts to read user |configuration files >> in ~/.idlerc/ (~ is one's home |directory). > > Apps should be

Re: Best practice for config files?

2025-05-23 Thread Chuck Rhode
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, 22 May 2025 14:59:28 -0500 "Michael F. Stemper" wrote: > Is requiring the program to be executed in the directory containing > the configuration file considered acceptable practice? Freedesktop.org proposes a specification for where such thi

Re: Searching for a file

2025-05-23 Thread Rob Cliffe via Python-list
On 23/05/2025 18:55, Mats Wichmann wrote: On 5/22/25 21:04, Rob Cliffe via Python-list wrote: It occurs to me that it might be useful if Python provided a function to search for a file with a given name in various directories (much as the import.import_lib function searches for a module in th

Re: Searching for a file

2025-05-23 Thread Mats Wichmann
On 5/22/25 21:04, Rob Cliffe via Python-list wrote: It occurs to me that it might be useful if Python provided a function to search for a file with a given name in various directories (much as the import.import_lib function searches for a module in the directories in sys.path). This function w

Re: Best practice for config files?

2025-05-23 Thread c . buhtz
Hello Michael, thank you for your important question. On GNU/Linux (and maybe for POSIX?) systems there is a standard about it. Look for $XDG_CONFIG_HOME. To drive it further, you might distinguish between config data (related and

Re: Best practice for config files?

2025-05-22 Thread Grant Edwards via Python-list
On 2025-05-23, Thomas Passin wrote: >> Alternatively look at the PATH envronment variable, which >> contains a list of directories separated by semicolons and which you can >> access as os.environ['PATH'] . > > There is really no reason for a config file to be on the system > path. On Unix/Lin

Re: Best practice for config files?

2025-05-22 Thread Thomas Passin
On 5/22/2025 7:09 PM, Rob Cliffe via Python-list wrote: On 22/05/2025 23:45, Mats Wichmann wrote: On 5/22/25 13:59, Michael F. Stemper via Python-list wrote: I recently wrote a program to do some record-keeping for me. I found myself hard-coding a bunch of different values into it. This didn'

Re: Best practice for config files?

2025-05-22 Thread Rob Cliffe via Python-list
On 22/05/2025 23:45, Mats Wichmann wrote: On 5/22/25 13:59, Michael F. Stemper via Python-list wrote: I recently wrote a program to do some record-keeping for me. I found myself hard-coding a bunch of different values into it. This didn't seem right, so I made my first use of configparser.Conf

Re: Best practice for config files?

2025-05-22 Thread Mats Wichmann
On 5/22/25 13:59, Michael F. Stemper via Python-list wrote: I recently wrote a program to do some record-keeping for me. I found myself hard-coding a bunch of different values into it. This didn't seem right, so I made my first use of configparser.ConfigParser(). Created the configuration file an

Re: Dynamic classes

2025-05-20 Thread Left Right via Python-list
> I have created a dynamic class using the type() function: > x = type('MyFlags', (), {'Flag1': 1, 'Flag2': 2, 'Flag3: 4, ' '__init__' : > __init__}) I find that it's generally more convenient to do this using similar code: def constructor(flag1, flag2): class _Hidden: def __init__(se

Re: Dynamic classes

2025-05-19 Thread Greg Ewing via Python-list
On 20/05/25 4:33 am, Stefan Ram wrote: So, the reason you're getting that TypeError is your __init__ function isn't actually hooked up right when you build your class with "type". You got to set up your init before you call "type", and then drop it into the class dictionary as a /f

Re: Dynamic classes

2025-05-19 Thread Rob Cliffe via Python-list
On 19/05/2025 23:11, Thomas Passin via Python-list wrote: On 5/19/2025 5:49 PM, Mats Wichmann via Python-list wrote: On 5/19/25 09:51, Jonathan Gossage via Python-list wrote: I have created a dynamic class using the type() function: x = type('MyFlags', (), {'Flag1': 1, 'Flag2': 2, 'Flag3: 4,

Re: Dynamic classes

2025-05-19 Thread Thomas Passin via Python-list
On 5/19/2025 5:49 PM, Mats Wichmann via Python-list wrote: On 5/19/25 09:51, Jonathan Gossage via Python-list wrote: I have created a dynamic class using the type() function: x = type('MyFlags', (), {'Flag1': 1, 'Flag2': 2, 'Flag3: 4, ' '__init__' : __init__}) The new class is there, and the c

Re: Dynamic classes

2025-05-19 Thread Mats Wichmann via Python-list
On 5/19/25 09:51, Jonathan Gossage via Python-list wrote: I have created a dynamic class using the type() function: x = type('MyFlags', (), {'Flag1': 1, 'Flag2': 2, 'Flag3: 4, ' '__init__' : __init__}) The new class is there, and the class variables, Flag1, Flag2, and Flag3, are present correctly

Re: Trailer for upcoming Python documentary

2025-05-19 Thread Christian Buhtz via Python-list
Am 18.05.2025 22:16 schrieb Larry Martell via Python-list: https://youtu.be/pqBqdNIPrbo?si=P2ukSXnDj3qy3HBJ Awesome! Which release channels will be used? How can we pay? -- https://mail.python.org/mailman/listinfo/python-list

Re: Trailer for upcoming Python documentary

2025-05-18 Thread Tim Daneliuk via Python-list
On 5/18/25 15:16, Larry Martell wrote: https://youtu.be/pqBqdNIPrbo?si=P2ukSXnDj3qy3HBJ Get ready Guido: "I'd like to thank the Academy ..." -- https://mail.python.org/mailman/listinfo/python-list

Re: WG: dont use C:\Windows as working directory when installed using microsoft store

2025-05-18 Thread Mats Wichmann via Python-list
On 5/18/25 08:39, Mike Dewhirst via Python-list wrote: Apologies for top-posting. It's my phone's fault.Since  no-one appears to have responded, I'll stir up some aggro and offer my opinion based on ~45 years experience with Microsoft.Uninstall python/idle etc completely and download from pyth

RE: WG: dont use C:\Windows as working directory when installed using microsoft store

2025-05-18 Thread Mike Dewhirst via Python-list
Apologies for top-posting. It's my phone's fault.Since  no-one appears to have responded, I'll stir up some aggro and offer my opinion based on ~45 years experience with Microsoft.Uninstall python/idle etc completely and download from python.org instead. I would advise ignoring recommendations a

Re: [egenix-info] ANN: eGenix Antispam Bot for Telegram 0.7.1

2025-05-14 Thread Marc-Andre Lemburg via Python-list
Hi Schimon, thanks for reaching out. Our bot is TG-only, since we built it for our user group chat group running on TG. But I suppose you can make use of the types of challenges we use for XMPP and IRC as well. The strategies are working quite well for us, even though they are not perfect.

Re: [egenix-info] ANN: eGenix Antispam Bot for Telegram 0.7.1

2025-05-14 Thread Schimon Jehudah via Python-list
Marc-Andre. Good evening. Thank you for your respond. I will definitely explore your project. The XMPP modules are atomized in a single directory /interface/xmpp/ in order to make it extendible to other interfaces (i.e. protocols). I do consider to transform the directory of XMPP modules into a

Re: ANN: eGenix Antispam Bot for Telegram 0.7.1

2025-05-14 Thread Schimon Jehudah via Python-list
Good evening. Is this service also available for XMPP? I am working on a similar project which is called KaikOut, and I will be glad to collaborate. https://git.xmpp-it.net/sch/KaikOut Moderation service for XMPP Currently, it supports XMPP, and in future it would also support IRC. Kind regard

Re: backslash in triple quoted string

2025-05-13 Thread Thomas Passin via Python-list
On 5/8/2025 2:05 AM, Left Right via Python-list wrote: Also, it appears that the change linked above is a lie: https://docs.python.org/3/reference/lexical_analysis.html#grammar-token-python-grammar-longstringitem According to the grammar, any character can follow backslash in a valid Python pro

Re: backslash in triple quoted string

2025-05-12 Thread Greg Ewing via Python-list
On 13/05/25 6:28 am, Left Right wrote: Read the associate release note. I take it you're referring to this: In a future Python version, SyntaxError will eventually be raised, instead of SyntaxWarning. (Contributed by Victor Stinner in gh-98401.) That doesn't contradict what I said. Currentl

Re: backslash in triple quoted string

2025-05-12 Thread Keith Thompson via Python-list
Left Right writes: >> Second, the word "lie" is far more harsh than what I presume >> you meant to say. For me, and I think for most people, the word >> "lie" implies a deliberate intent to deceive. > > No, it doesn't. Consider Joseph Conrand's Heart of Darkness, No, thank you. I am trying to h

Re: backslash in triple quoted string

2025-05-12 Thread Ethan Furman via Python-list
Chris and Oleg (sp?), please control your tempers; your latter posts added nothing useful to the conversation. (Apologies for the late reply, I was out of town.) -- ~Ethan~ Moderator -- https://mail.python.org/mailman/listinfo/python-list

Re: backslash in triple quoted string

2025-05-12 Thread Left Right via Python-list
> Second, the word "lie" is far more harsh than what I presume > you meant to say. For me, and I think for most people, the word > "lie" implies a deliberate intent to deceive. No, it doesn't. Consider Joseph Conrand's Heart of Darkness, the final episode where Marlow comes to Kurtz' widow and te

Re: backslash in triple quoted string

2025-05-12 Thread Left Right via Python-list
> But the message doesn't say it's an error. It uses the word "warning", > not "error". You're tilting at a straw horse here. Read the associate release note. -- https://mail.python.org/mailman/listinfo/python-list

Re: backslash in triple quoted string

2025-05-12 Thread Keith Thompson via Python-list
Left Right writes: > Then it just means that the grammar lies. The two claims are mutually > exclusive, so either one is a lie or the other or both. [...] A couple of points. First, the convention in this and most other Usenet newsgroups is to write new text *below* any quoted text. This is kno

Re: backslash in triple quoted string

2025-05-11 Thread Greg Ewing via Python-list
On 12/05/25 3:21 am, Left Right wrote: The point is that the error is wrong. It cannot be a syntax error and at the same time the program compiles. But the message doesn't say it's an error. It uses the word "warning", not "error". You're tilting at a straw horse here. -- Greg -- https://mai

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
Why of all people would I respect you? What did you ever do other than insult me? :) Now you are acting surprised? On Sun, May 11, 2025 at 7:38 PM Chris Angelico wrote: > > On Mon, 12 May 2025 at 03:35, Left Right wrote: > > > > https://gitlab.com/doodles-archive/protopy/-/blob/master/cris-angel

Re: backslash in triple quoted string

2025-05-11 Thread Chris Angelico via Python-list
On Mon, 12 May 2025 at 03:35, Left Right wrote: > > https://gitlab.com/doodles-archive/protopy/-/blob/master/cris-angelico-is-a-moron.org?ref_type=heads > Here's a proof that I have commit rights to this repo > I didn't ask for that, and you don't even have the respect to spell my name correctly.

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
https://gitlab.com/doodles-archive/protopy/-/blob/master/protopy/lib/protopy.y?ref_type=heads Here's one. It's not great, not awful. https://gitlab.com/doodles-archive/protopy/-/blob/master/cris-angelico-is-a-moron.org?ref_type=heads Here's a proof that I have commit rights to this repo On Sun,

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
Oh, so this is where 4chan relocated after they were hacked? What a refined discussion! On Sun, May 11, 2025 at 5:28 PM Chris Angelico wrote: > > On Mon, 12 May 2025 at 01:24, Left Right via Python-list > wrote: > > > > But, sure, go ahead, foam at the mouth, if it > > makes you feel better abo

Re: backslash in triple quoted string

2025-05-11 Thread Chris Angelico via Python-list
On Mon, 12 May 2025 at 01:24, Left Right via Python-list wrote: > > But, sure, go ahead, foam at the mouth, if it > makes you feel better about it. Projecting, much? ChrisA -- https://mail.python.org/mailman/listinfo/python-list

Re: backslash in triple quoted string

2025-05-11 Thread Chris Angelico via Python-list
On Mon, 12 May 2025 at 01:19, Left Right wrote: > > > Have you ever built a language parser? > > I've lost count by now. Probably fewer than hundred times though. Show me then. Prove it. You're all hot air and opinions and bluster. Show some actual code, and show that you can do right what you're

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
Hahah... what a pile of rubbish. The point is that the error is wrong. It cannot be a syntax error and at the same time the program compiles. You need to choose one. But, sure, go ahead, foam at the mouth, if it makes you feel better about it. -- https://mail.python.org/mailman/listinfo/python-lis

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
> Have you ever built a language parser? I've lost count by now. Probably fewer than hundred times though. -- https://mail.python.org/mailman/listinfo/python-list

Re: backslash in triple quoted string

2025-05-11 Thread Peter J. Holzer via Python-list
On 2025-05-11 12:36:31 +0200, Left Right via Python-list wrote: > Then it just means that the grammar lies. No, because the parser accepts the sequence. And it produces exactly what the description says. The program #!/usr/bin/python3 print("start") for i in range(3): print("\copy") print("

Re: backslash in triple quoted string

2025-05-11 Thread Richard Damon via Python-list
On 05/11/2025 6:36 AM EDT Left Right via Python-list <[1]python-list@python.org> wrote: Then it just means that the grammar lies. The two claims are mutually exclusive, so either one is a lie or the other or both. No, it more points out that not all errors are grammat

Re: backslash in triple quoted string

2025-05-11 Thread Chris Angelico via Python-list
On Sun, 11 May 2025 at 20:38, Left Right via Python-list wrote: > > My comment was more of an irony really. It's plenty obvious that the > grammar is a lie. The reason is that it's tedious to put the actual > intender rules into the grammar, and so whoever wrote the grammar > decided to cut corner

Re: backslash in triple quoted string

2025-05-11 Thread Left Right via Python-list
Then it just means that the grammar lies. The two claims are mutually exclusive, so either one is a lie or the other or both. My comment was more of an irony really. It's plenty obvious that the grammar is a lie. The reason is that it's tedious to put the actual intender rules into the grammar, an

Re: backslash in triple quoted string

2025-05-11 Thread Peter J. Holzer via Python-list
On 2025-05-08 08:05:54 +0200, Left Right via Python-list wrote: > Also, it appears that the change linked above is a lie: Such strong words ... > https://docs.python.org/3/reference/lexical_analysis.html#grammar-token-python-grammar-longstringitem > > According to the grammar, any character can

Re: backslash in triple quoted string

2025-05-07 Thread Left Right via Python-list
Also, it appears that the change linked above is a lie: https://docs.python.org/3/reference/lexical_analysis.html#grammar-token-python-grammar-longstringitem According to the grammar, any character can follow backslash in a valid Python program. The warning / error raised by this code should not

Re: backslash in triple quoted string

2025-05-07 Thread Left Right via Python-list
I think it could be this: A backslash-character pair that is not a valid escape sequence now generates a SyntaxWarning, instead of DeprecationWarning. For example, re.compile("\d+\.\d+") now emits a SyntaxWarning ("\d" is an invalid escape sequence, use raw strings for regular expression: re.compi

RE: Module urljoin does not appear to work with scheme Gemini

2025-04-24 Thread Anders Munch via Python-list
Henry S. Thompson wrote: > Some approach to support future-proofing in general would seem to be in > order. > Given some other precedents, adding a boolean argument called either 'strict' > or 'lax' would be my preference. An alternative would be to refactor urllib.parse to use strategy objects

Re: Module urljoin does not appear to work with scheme Gemini

2025-04-23 Thread Henry S. Thompson via Python-list
Schimon Jehudah writes: > Is there an "ignore" option for "urljoin" to allow schemes that are not > included in the registry of the interpreter of the Python computer > language? Some approach to support future-proofing in general would seem to be in order. Given some other precedents, adding a

Re: Module urljoin does not appear to work with scheme Gemini

2025-04-22 Thread Schimon Jehudah via Python-list
Is there an "ignore" option for "urljoin" to allow schemes that are not included in the registry of the interpreter of the Python computer language? I think that it is needed to have, even if it is not registered, as there are ongoing attempts to try to censor Gemini and Gopher. gemini://woodpeck

Re: Module urljoin does not appear to work with scheme Gemini

2025-04-22 Thread Henry S. Thompson via Python-list
Schimon Jehudah via Python-list writes: > Yesterday, I have added support for a new syndication format, Gemini > feed. I note that 'gemini' is not (yet?) a registered URI scheme: https://www.iana.org/assignments/uri-schemes/uri-schemes.xhtml ht -- Henry S. Thompson, School of Informat

Re: Pip installs to unexpected place

2025-04-21 Thread rbowman via Python-list
On Sat, 19 Apr 2025 15:56:16 -0400, Thomas Passin wrote: > My problem with venvs, especially if I have more than one, is that I > eventually forget what they were for and what is different about each > one. If there's only one and it's used for all non-system work, that's > OK but beyond that and

Re: Pip installs to unexpected place

2025-04-21 Thread songbird via Python-list
Peter J. Holzer wrote: > On 2025-04-18 13:08:36 -0400, Thomas Passin via Python-list wrote: ... >> When the system launches its application the PYTHONPATH will start with >> system site directories; local user site directories will be on the >> PYTHONPATH but since they come later, the python will

Re: Pip installs to unexpected place

2025-04-19 Thread Thomas Passin via Python-list
On 4/19/2025 4:56 AM, Peter J. Holzer via Python-list wrote: On 2025-04-18 13:08:36 -0400, Thomas Passin via Python-list wrote: On 4/18/2025 11:38 AM, Peter J. Holzer via Python-list wrote: On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: On 18/04/25 9:41 am, Mats Wichmann wrote

Re: Pip installs to unexpected place

2025-04-19 Thread Peter J. Holzer via Python-list
On 2025-04-18 13:08:36 -0400, Thomas Passin via Python-list wrote: > On 4/18/2025 11:38 AM, Peter J. Holzer via Python-list wrote: > > On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: > > > On 18/04/25 9:41 am, Mats Wichmann wrote: > > > > There's just not a really great answer to th

Re: Pip installs to unexpected place

2025-04-19 Thread Peter J. Holzer via Python-list
On 2025-04-18 17:11:33 +0100, Oscar Benjamin via Python-list wrote: > On Fri, 18 Apr 2025 at 16:50, Peter J. Holzer via Python-list > wrote: > > > > On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: > > > On 18/04/25 9:41 am, Mats Wichmann wrote: > > > > There's just not a really gre

Re: Pip installs to unexpected place

2025-04-18 Thread Thomas Passin via Python-list
On 4/18/2025 11:38 AM, Peter J. Holzer via Python-list wrote: On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: On 18/04/25 9:41 am, Mats Wichmann wrote: There's just not a really great answer to this. Seems to me a system-installed application shouldn't be looking in the user's

Re: Pip installs to unexpected place

2025-04-18 Thread Oscar Benjamin via Python-list
On Fri, 18 Apr 2025 at 16:50, Peter J. Holzer via Python-list wrote: > > On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: > > On 18/04/25 9:41 am, Mats Wichmann wrote: > > > There's just not a really great answer to this. > > > > Seems to me a system-installed application shouldn't

Re: Pip installs to unexpected place

2025-04-18 Thread Peter J. Holzer via Python-list
On 2025-04-18 13:24:28 +1200, Greg Ewing via Python-list wrote: > On 18/04/25 9:41 am, Mats Wichmann wrote: > > There's just not a really great answer to this. > > Seems to me a system-installed application shouldn't be looking in the > user's .local packages in the first place. That should only b

Re: Pip installs to unexpected place

2025-04-17 Thread Greg Ewing via Python-list
On 18/04/25 9:41 am, Mats Wichmann wrote: There's just not a really great answer to this. Seems to me a system-installed application shouldn't be looking in the user's .local packages in the first place. That should only be for things the user has installed "for this user". -- Greg -- https

Re: Pip installs to unexpected place

2025-04-17 Thread Mats Wichmann via Python-list
On 4/17/25 15:15, Grant Edwards via Python-list wrote: On 2025-04-17, Left Right via Python-list wrote: Also... when installing stuff with pip --user, it is always a package that is not installed for the system (usually not even available for the system). How can that "break system packages"?

Re: Pip installs to unexpected place

2025-04-17 Thread Grant Edwards via Python-list
On 2025-04-17, Left Right via Python-list wrote: >> Also... when installing stuff with pip --user, it is always a package >> that is not installed for the system (usually not even available for >> the system). How can that "break system packages"? > > pip installs dependencies. Dependencies may di

Re: Pip installs to unexpected place

2025-04-17 Thread Left Right via Python-list
> Also... when installing stuff with pip --user, it is always a package > that is not installed for the system (usually not even available for > the system). How can that "break system packages"? pip installs dependencies. Dependencies may disagree on the version with the system packages. This is

Re: Pip installs to unexpected place

2025-04-17 Thread Thomas Passin via Python-list
On 4/17/2025 4:58 AM, Roel Schroeven via Python-list wrote: Op 15/04/2025 om 20:31 schreef Mats Wichmann via Python-list: To be clear: you do not have to activate a virtualenv to use *Python* from it. If you just call the python by the path it's in, it figures everything out (and sets some vari

Re: Pip installs to unexpected place

2025-04-17 Thread Roel Schroeven via Python-list
Op 15/04/2025 om 20:31 schreef Mats Wichmann via Python-list: To be clear: you do not have to activate a virtualenv to use *Python* from it. If you just call the python by the path it's in, it figures everything out (and sets some variables you can query vi sysconfig if you have reason to actua

Re: Pip installs to unexpected place

2025-04-16 Thread Thomas Passin via Python-list
On 4/15/2025 5:38 PM, rbowman via Python-list wrote: On Tue, 15 Apr 2025 14:12:19 -0400, Thomas Passin wrote: On Linux, at least, it's standard for pip to install into the user's site-packages location if it's not invoked with admin privileges - even without --user. Pip will emit a message sayi

Re: Pip installs to unexpected place

2025-04-16 Thread rbowman via Python-list
On Tue, 15 Apr 2025 14:12:19 -0400, Thomas Passin wrote: > On Linux, at least, it's standard for pip to install into the user's > site-packages location if it's not invoked with admin privileges - even > without --user. Pip will emit a message saying so. Well, that used to be > true but nowadays P

Re: Pip installs to unexpected place

2025-04-16 Thread Grant Edwards via Python-list
On 2025-04-16, Mats Wichmann via Python-list wrote: > On 4/15/25 16:07, Grant Edwards via Python-list wrote: >> On 2025-04-15, Thomas Passin via Python-list wrote: >> >>> On Linux, at least, it's standard for pip to install into the user's >>> site-packages location if it's not invoked with admi

Re: Pip installs to unexpected place

2025-04-15 Thread Mats Wichmann via Python-list
On 4/15/25 16:07, Grant Edwards via Python-list wrote: On 2025-04-15, Thomas Passin via Python-list wrote: On Linux, at least, it's standard for pip to install into the user's site-packages location if it's not invoked with admin privileges - even without --user. Pip will emit a message saying

Re: Pip installs to unexpected place

2025-04-15 Thread Grant Edwards via Python-list
On 2025-04-15, Thomas Passin via Python-list wrote: > On Linux, at least, it's standard for pip to install into the user's > site-packages location if it's not invoked with admin privileges - even > without --user. Pip will emit a message saying so. Well, that used to be > true but nowadays Pi

Re: Pip installs to unexpected place

2025-04-15 Thread rbowman via Python-list
On Tue, 15 Apr 2025 18:43:43 +0200, Friedrich Romstedt wrote: > Many people put emphasis on that you need to *activate* a virtualenv > before using it, but no-one so far stressed the fact that you got Sphinx > installed to ~/jonathan/.local/lib/python3.13/site-packages *without > using *--user. T

Re: Pip installs to unexpected place

2025-04-15 Thread Thomas Passin via Python-list
On 4/15/2025 3:41 PM, dn via Python-list wrote: Various responses have been provided but the OP has not yet replied on- list (as verified by Archive). Is this an error with the list-processor or have some posts been sent to one person only (using Reply instead of ReplyList)? There are always

Re: Pip installs to unexpected place

2025-04-15 Thread Thomas Passin via Python-list
On 4/15/2025 12:43 PM, Friedrich Romstedt via Python-list wrote: Am Mo., 14. Apr. 2025 um 01:14 Uhr schrieb Jonathan Gossage via Python-list : I am using *Python 3.13* in a virtual environment under *Ubuntu Linux 24.04* . [...] Instead, it was installed into the site-packages directory in

Re: Pip installs to unexpected place

2025-04-15 Thread dn via Python-list
Various responses have been provided but the OP has not yet replied on-list (as verified by Archive). Is this an error with the list-processor or have some posts been sent to one person only (using Reply instead of ReplyList)? There are always others who would like to learn from list-discussio

Re: Pip installs to unexpected place

2025-04-15 Thread Mats Wichmann via Python-list
On 4/15/25 10:43, Friedrich Romstedt via Python-list wrote: Many people put emphasis on that you need to *activate* a virtualenv before using it, but no-one so far stressed the fact that you got Sphinx installed to ~/jonathan/.local/lib/python3.13/site-packages *without using *--user. To be clea

Re: Pip installs to unexpected place

2025-04-15 Thread Friedrich Romstedt via Python-list
Am Mo., 14. Apr. 2025 um 01:14 Uhr schrieb Jonathan Gossage via Python-list : > I am using *Python 3.13* in a virtual environment under *Ubuntu Linux > 24.04* > . > [...] > Instead, it was > installed into the site-packages directory in > */home/jonathan/.locals/lib/python3.13/site-packages* ev

Re: Pip installs to unexpected place

2025-04-15 Thread rbowman via Python-list
On Mon, 14 Apr 2025 15:20:13 -0700, Keith Thompson wrote: > 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.

Re: Pip installs to unexpected place

2025-04-15 Thread Keith Thompson via Python-list
rbowman writes: > On Mon, 14 Apr 2025 09:55:09 -0400, Thomas Passin wrote: >> Pip doesn't know about the environment it runs in. It seems to me that >> you didn't active the venv before you installed using pip. So nothing >> would have gotten installed into the venv. So where is the venv that you

Re: Pip installs to unexpected place

2025-04-14 Thread Thomas Passin via Python-list
On 4/14/2025 6:20 PM, Keith Thompson via Python-list wrote: Thomas Passin 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

Re: Pip installs to unexpected place

2025-04-14 Thread Thomas Passin via Python-list
On 4/14/2025 6:20 PM, Keith Thompson via Python-list wrote: Thomas Passin 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

Re: Pip installs to unexpected place

2025-04-14 Thread rbowman via Python-list
On Mon, 14 Apr 2025 09:55:09 -0400, Thomas Passin wrote: > Pip doesn't know about the environment it runs in. It seems to me that > you didn't active the venv before you installed using pip. So nothing > would have gotten installed into the venv. So where is the venv that you > set up? I usually p

Re: Pip installs to unexpected place

2025-04-14 Thread Keith Thompson via Python-list
Thomas Passin 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.

Re: Pip installs to unexpected place

2025-04-14 Thread Thomas Passin via Python-list
Please include the group in your response; don't just send it to me. On 4/14/2025 5:09 AM, Jonathan Gossage wrote: The virtual environment was owned by the user running pip. It was not owned by root. Does pip not support virtual environments that are owned by a non-root user and have a multi-us

Re: Pip installs to unexpected place

2025-04-14 Thread rbowman via Python-list
On Sun, 13 Apr 2025 19:10:47 -0400, Jonathan Gossage wrote: > The version of Python was compiled from source code and installed with > make altinstall. I attempted to use *pip* to install the *Sphinx* > package into the virtual environment using the command *pip install > sphinx* in the virtual en

  1   2   3   4   5   6   7   8   9   10   >