Re: Unable to save any files

2020-08-11 Thread Terry Reedy
On 8/11/2020 5:27 AM, Lim Clayton wrote: I am a relatively new Python User. I recently downloaded Python on my desktop and I am unable to save anything when I use IDLE. I can run codes on the shell without any issue but running anything on the window which requires saving causes nothing to happe

Re: Unable to save any files

2020-08-11 Thread dn via Python-list
On 11/08/2020 21:27, Lim Clayton wrote: Hi, I am a relatively new Python User. I recently downloaded Python on my desktop and I am unable to save anything when I use IDLE. I can run codes on the shell without any issue but running anything on the window which requires saving causes nothing to ha

Re: Strange namespace issue

2020-08-11 Thread Chris Angelico
On Wed, Aug 12, 2020 at 12:03 PM Lele Gaifax wrote: > But I see this is somewhat fragile, and wonder about a proper fix, but isn't > that a reasonable usage of the "locals" argument to exec()? > I'm not sure. Passing a locals argument to eval() I have sometimes done, but never exec(). I've always

Re: IDLE: New Feature?

2020-08-11 Thread Terry Reedy
On 8/11/2020 4:26 AM, Steve wrote: << Simplest specification: << one list for all 3 search boxes; << start fresh each session I do not understand what this means... A proposed feature needs a specification with sufficient details to code and review. Your proposal "a pull-down history list fo

Unable to save any files

2020-08-11 Thread Lim Clayton
Hi, I am a relatively new Python User. I recently downloaded Python on my desktop and I am unable to save anything when I use IDLE. I can run codes on the shell without any issue but running anything on the window which requires saving causes nothing to happen. I still get the prompt which says yo

Re: Strange namespace issue

2020-08-11 Thread Lele Gaifax
Chris Angelico writes: > Interesting. You're passing an empty globals and a non-empty locals > (the second and third arguments to exec, respectively). Is that > deliberate? By the look of this code, it's meant to be at global scope > (as if it's the top level code in a module), which is best done

[RELEASE] Python 3.9.0rc1 is now available

2020-08-11 Thread Łukasz Langa
Python 3.9.0 is *almost* ready. This release, *3.9.0rc1*, is the penultimate release preview. You can get it here: https://www.python.org/downloads/release/python-390rc1/ Entering the release candidate phase, only reviewed code changes which are clear bug fixes are allowed between this release c

Re: How to remove "" from starting of a string if provided by the user

2020-08-11 Thread Bill Campbell
On Tue, Aug 11, 2020, Ganesh Pal wrote: >The possible value of stat['server2'] can be either (a) >"'/fileno_100.txt'" or (b) '/fileno_100.txt' . def stripquotes(s): '''Strip leading single or double quotes to any depth''' import re pat = re.compile(r'^([\'"])(.*)(\1)$') slast = Non

Re: How to remove "" from starting of a string if provided by the user

2020-08-11 Thread Akkana Peck
> > On 2020-08-11 02:20, Ganesh Pal wrote: > > > How do I check if it the value was (a) i.e string started and ended > > > with a quote Of course the original question was simple and there have been lots of solutions given. But I find this comes up periodically, and I'm always leery of using som

Re: How explain why Python is easier/nicer than Lisp which has a simpler grammar/syntax?

2020-08-11 Thread bryan . gene . olson
Christian Seberino wrote: > A beginner I think could learn Lisp much faster than Python. For talented beginners, Lisp rocks much like Python, in that easy assignments are easy enough to implement. On the high end, Lisp rocks again: Lisp masters are astonishingly productive. In between, beyond pe

Re: How to remove "" from starting of a string if provided by the user

2020-08-11 Thread Joel Goldstick
On Tue, Aug 11, 2020 at 12:26 PM MRAB wrote: > > On 2020-08-11 02:20, Ganesh Pal wrote: > > The possible value of stat['server2'] can be either (a) > "'/fileno_100.txt'" or (b) '/fileno_100.txt' . > > How do I check if it the value was (a) i.e string started and ended > with a quote , so that I

Re: How to remove "" from starting of a string if provided by the user

2020-08-11 Thread MRAB
On 2020-08-11 02:20, Ganesh Pal wrote: > The possible value of stat['server2'] can be either (a) "'/fileno_100.txt'" or (b) '/fileno_100.txt' . > How do I check if it the value was  (a) i.e string started and ended with a quote , so that I can use ast.literal_eval() > >>> import ast > >>> stat

RE: IDLE: New Feature?

2020-08-11 Thread Steve
<< Simplest specification: << one list for all 3 search boxes; << start fresh each session I do not understand what this means... Footnote: The only time "incorrectly" is spelled incorrectly is when it is spelled "incorrectly". -Original Message- From: Python-list On Behalf Of Terry