Re: Python 3.9. 1 not working

2021-02-10 Thread Roland Mueller via Python-list
Hello, Please note that this is not a kind of support service rather than a community where people help each other on voluntary base. In order to get help from here, you should provide enough information about your issue with Python 3.9 that others can figure out what happened. BR, Roland ke 10

Re: Troubles with Python imports

2021-02-10 Thread Roland Mueller via Python-list
ke 10. helmik. 2021 klo 5.07 Terry Reedy (tjre...@udel.edu) kirjoitti: > On 2/9/2021 9:55 AM, Philipp Daher via Python-list wrote: > > Hello, > > > > I’ve just typed „pip install selenium“ into my command prompt on windows > 10. Although my computer told me that the requirement was already > satis

Re: Fwd: Inconveniente

2021-02-10 Thread MRAB
On 2021-02-09 22:34, Terry Reedy wrote: On 2/9/2021 3:39 PM, dn via Python-list wrote: On 09/02/2021 15.13, Juan Jose Reyna Figuera wrote: [ Translation: matplotlib (and seaborn) not playing-nicely with Python 3.9 64-bit edition on MS-Win 10. Solved by down-grading to Python 3.8 32-bit. ] Y

Re: Best practices for software architecture in Python

2021-02-10 Thread Henning Follmann
On 2021-02-10, Python wrote: > Hi, > > If you had to train engineers who are used to write > Python scripts for image processing, data format conversion, > etc. (so they know most the basics of Python types and > programming structures except advanced OOP techniques) > who now are about to devel

Re: installation issues

2021-02-10 Thread Mats Wichmann
On 2/9/21 4:23 PM, Martin Lopez wrote: Hello, My name is Martin Lopez. I just downloaded Python 3.9.1 (64 bit) Setup. After I install the program then try to run it, with no success. I've uninstalled all previous versions and reinstalled them, but it does not seem to help. Can you please assi

Running Jupyter Notebook

2021-02-10 Thread Rafael Llera
I installed Python and jupyter via pip, but when I run jupyter notebook I keep getting the following error. Requirement already satisfied: pyparsing>=2.0.2 in c:\users\mitzi\appdata\roaming\python\python39\site-packages (from packaging->bleach->nbconvert->jupyter) (2.4.7) Requirement already sati

Very starnge problem in python

2021-02-10 Thread Priya Singh
def closset_match(check, arr, itr): id_min = [] for ii in range(itr): id_min_tmp = np.argmin( abs(arr - check) ) id_min.append(id_min_tmp) arr[id_min_tmp] = float('-inf') id_min = np.array(id_min) return id_min def get_match(arr1, arr2, tol, itr): tt

Re: Very starnge problem in python

2021-02-10 Thread David Lowry-Duda
Hello! > The very strange thing which is happening here is you see variable > arr2 at ID id_ttt before changing the variable tt at the same ID (i.e. > id_ttt]) is showing some value but once I am printing its value after > assigning tt[id_ttt] = 0.0, arr2[id_ttt] is also showing 0 value > howe

Re: Running Jupyter Notebook

2021-02-10 Thread tommy yama
Hi, Have you tried this? python -m notebook On Wed, Feb 10, 2021 at 11:28 PM Rafael Llera wrote: > I installed Python and jupyter via pip, but when I run jupyter notebook I > keep getting the following error. > > Requirement already satisfied: pyparsing>=2.0.2 in > c:\users\mitzi\appdata\ro

Re: installation issues

2021-02-10 Thread Ming
On Tue, Feb 09, 2021 at 03:23:56PM -0800, Martin Lopez wrote: > Hello, > > My name is Martin Lopez. I just downloaded Python 3.9.1 (64 bit) Setup. > > After I install the program then try to run it, with no success. > > I've uninstalled all previous versions and reinstalled them, but it does > n

Re: Running Jupyter Notebook

2021-02-10 Thread Terry Reedy
On 2/10/2021 9:26 AM, Rafael Llera wrote: I installed Python and jupyter via pip, but when I run jupyter notebook I keep getting the following error. Requirement already satisfied: pyparsing>=2.0.2 in c:\users\mitzi\appdata\roaming\python\python39\site-packages (from packaging->bleach->nbconve

Re: Mutable defaults

2021-02-10 Thread J. Pic
> Most of us know of the perils of mutable default values. And those who don't pay the price. I wonder what would be the harm in removing them, or doing copy on call by default. -- https://mail.python.org/mailman/listinfo/python-list

Re: Mutable defaults

2021-02-10 Thread Chris Angelico
On Thu, Feb 11, 2021 at 10:17 AM J. Pic wrote: > > > Most of us know of the perils of mutable default values. > > And those who don't pay the price. > > I wonder what would be the harm in removing them Define "removing". Most objects in Python are mutable; would that mean you can no longer use an

Re: Mutable defaults

2021-02-10 Thread Paul Bryan
Also -1 on changing the existing default behavior. +1 to an opt-in late-bound solution. On Thu, 2021-02-11 at 10:29 +1100, Chris Angelico wrote: > On Thu, Feb 11, 2021 at 10:17 AM J. Pic wrote: > > > > > Most of us know of the perils of mutable default values. > > > > And those who don't pay th

Re: Mutable defaults

2021-02-10 Thread J. Pic
I just meant removing the whole "default value mutating" story, not removing mutable variables. Really, I was wondering if there was a use case where this actually turns to an advantage, in which case it would be a designed feature rather than an undesirable side effect, which it seems to be. Now

Re: Mutable defaults

2021-02-10 Thread Chris Angelico
On Thu, Feb 11, 2021 at 12:56 PM J. Pic wrote: > > I just meant removing the whole "default value mutating" story, not removing > mutable variables. Really, I was wondering if there was a use case where this > actually turns to an advantage, in which case it would be a designed feature > rather

Python subinterpreters with separate GILs

2021-02-10 Thread James Lu
Directly removing the Global Interpreter Lock (GIL) would break a lot of libraries that implicitly assume it is there. What if Python had "realms" that each had separate GILs? The "realms" (not sure if "subinterpreter" is the correct term here) could share objects. -- https://mail.python.org/mail

Re: Mutable defaults

2021-02-10 Thread J. Pic
Adding decorators with some inspect sauce could certainly work with the syntax we already have: @default(x=lambda: copy([]), y=lambda x: len(x)) def foo(x=None, y=None): I think this PoC is doable. But the lambda copy is a boring so, two decorators: @default.copy(x=[]) @default.call(y=lamba x: l

Re: Mutable defaults

2021-02-10 Thread J. Pic
Silly me, we don't even need copy but just execution @lazy(x=lambda: [], y=lamba x: len(x)) def foo(x=None, y=None): So only one operator is needed, the walrus is still fine: def foo(x:=[], y:=len(x)): Not copy, just evaluate. Le jeu. 11 févr. 2021 à 03:54, J. Pic a écrit : > Adding decorato

Re: Mutable defaults

2021-02-10 Thread Chris Angelico
On Thu, Feb 11, 2021 at 1:55 PM J. Pic wrote: > > Adding decorators with some inspect sauce could certainly work with the > syntax we already have: > > @default(x=lambda: copy([]), y=lambda x: len(x)) > def foo(x=None, y=None): This would work, although the copy is unnecessary here. But you're a

Re: Mutable defaults

2021-02-10 Thread J. Pic
Ok, maybe: def foo(x=:[], y=:len(x)): As a shorthand for: @default(x=lambda: [], y=lambda x: len(x)) def foo(x=None, y=None): =: Is the contraction for =lambda: At the same time, this new syntax avoid breaking def foo(x=lamba: []) which is completely different as we know. Le jeu. 11 févr. 202

Re: Python subinterpreters with separate GILs

2021-02-10 Thread Cameron Simpson
On 10Feb2021 21:51, James Lu wrote: >Directly removing the Global Interpreter Lock (GIL) would break a lot >of libraries that implicitly assume it is there. What if Python had >"realms" that each had separate GILs? > >The "realms" (not sure if "subinterpreter" is the correct term here) >could shar

Re: Python subinterpreters with separate GILs

2021-02-10 Thread Christian Heimes
On 11/02/2021 03.51, James Lu wrote: > Directly removing the Global Interpreter Lock (GIL) would break a lot > of libraries that implicitly assume it is there. What if Python had > "realms" that each had separate GILs? > > The "realms" (not sure if "subinterpreter" is the correct term here) > coul

Why am I unable to using rsync to install modules and appear to have to use pip install instead?

2021-02-10 Thread Robert Nicholson
I’m using Python 3.7.0 so I have multiple environments all on the same architecture with the same python release using anonconda. What I discovered was that if I install the cryptography module in my dev / uat and then tried to synchronize to production server using rsync I ended up with error

Re: Why am I unable to using rsync to install modules and appear to have to use pip install instead?

2021-02-10 Thread Robert Nicholson
Just reinstalling cryptography with pip install seems to have fixed my issue. Any pointers on why? > On Feb 10, 2021, at 3:21 PM, Robert Nicholson > wrote: > > I’m using Python 3.7.0 > > so I have multiple environments all on the same architecture with the same > python release using anoncon

Re: Why am I unable to using rsync to install modules and appear to have to use pip install instead?

2021-02-10 Thread Robert Nicholson
Ok this was due to an install of miniconda then choosing to unconditionally install an older version of cryptography. > On Feb 10, 2021, at 3:40 PM, Robert Nicholson > wrote: > > Just reinstalling cryptography with pip install seems to have fixed my issue. > > Any pointers on why? > >> On Fe

Re: Mutable defaults

2021-02-10 Thread Grant Edwards
On 2021-02-11, J. Pic wrote: > I just meant removing the whole "default value mutating" story, not > removing mutable variables. Really, I was wondering if there was a use case > where this actually turns to an advantage, I've seen people show how it can be used to provide function-scope persist

Re: Mutable defaults

2021-02-10 Thread Ross Wilson
On Thu, 11 Feb 2564 BE at 12:52 Grant Edwards wrote: > On 2021-02-11, J. Pic wrote: > > > I just meant removing the whole "default value mutating" story, not > > removing mutable variables. Really, I was wondering if there was a use > case > > where this actually turns to an advantage, > > I've

Re: Mutable defaults

2021-02-10 Thread Chris Angelico
On Thu, Feb 11, 2021 at 6:03 PM Ross Wilson wrote: > > On Thu, 11 Feb 2564 BE at 12:52 Grant Edwards > wrote: > > > On 2021-02-11, J. Pic wrote: > > > > > I just meant removing the whole "default value mutating" story, not > > > removing mutable variables. Really, I was wondering if there was a