[Python-ideas] Re: Descriptor __get__ and __set__ argument discrepancy

2023-10-19 Thread Antoine Rozo
answers that I got were very useful. > > DG > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ >

[Python-ideas] Re: Extract variable name from itself

2023-09-12 Thread Antoine Rozo
deferred eval :/ — > Regards, > DG > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.or

[Python-ideas] Re: Make ellipsis an indicator of missing implementation

2023-04-27 Thread Antoine Rozo
__ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas

[Python-ideas] Re: Ampersand operator for strings

2023-03-11 Thread Antoine Rozo
> Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/A7RPR3FSBXEMRYAUXJVYYROCHVHL7DVP/ > > Code of Conduct: http://python.org/psf/codeofconduct/ > > ___ > Python-ideas mailing list -- python-i

[Python-ideas] Re: join() could add separators at start or end

2023-03-10 Thread Antoine Rozo
'se, 'SE', 'Se', 'sE' > (the last two would have the same effect, but the difference in emphasis > might clarify the author's thought). > If nothing else, this would push authors into thinking about the empty > list case, rather than bein

[Python-ideas] Re: Delete dictionary entry if key exists using -= operator via __isub__()

2022-04-28 Thread Antoine Rozo
ttps://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/BBFALX57PJI4ALF4O6YGYMHMLNL4U4YI/ > Code of Conduct: http://python.org/psf/codeofconduct/ > -- Antoine Rozo

[Python-ideas] Re: mro and super don't feel so pythonic

2022-04-13 Thread Antoine Rozo
ch as we don't like it. > > Eric > > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python

[Python-ideas] Re: mro and super don't feel so pythonic

2022-04-08 Thread Antoine Rozo
If these examples were possible (I wouldn't say they are smart designs) they would lead to recursion errors. Limitations on MRO are good, they force to keep a quite simple structure. Le jeu. 7 avr. 2022 à 17:41, malmiteria a écrit : > Antoine Rozo writes: > > If the only feature

[Python-ideas] Re: mro and super don't feel so pythonic

2022-04-07 Thread Antoine Rozo
I, but your multiply-derived class *written before the > > refactoring* Just Works. As far as I can see, super(), and maybe even > > the deterministic MRO, is needed to make that work. > I'm curious about this exemple, do you have a link to share so i could > h

[Python-ideas] Re: define an idiomatic way to make a generator that throws StopIteration immediately and add it to PEP8

2021-09-03 Thread Antoine Rozo
5JCWC/ > Code of Conduct: http://python.org/psf/codeofconduct/ -- Antoine Rozo ___ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python

[Python-ideas] Re: staticmethod with property

2021-08-24 Thread Antoine Rozo
> Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/M4

[Python-ideas] Re: Getting rid of FOR loops and simplifying cicular conviolutions with Circular Indexing

2020-11-25 Thread Antoine Rozo
t; https://mail.python.org/archives/list/python-ideas@python.org/message/5TJYKFLBHB26WEFFQXMY6AGWS34XTIUR/ >> Code of Conduct: http://python.org/psf/codeofconduct/ >> > > > -- > > CALVIN SPEALMAN > > SENIOR QUALITY ENGINEER > > cspea...@redhat.com M: +1.33

[Python-ideas] Re: Getting rid of FOR loops and simplifying cicular conviolutions with Circular Indexing

2020-11-25 Thread Antoine Rozo
> nD arrays is offered by the fact that n-dimensional DFT reduces n-dimensional > circular convolution to element-wise multiplication. > > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ide

[Python-ideas] Re: JSON Serializing UUID objects

2020-06-10 Thread Antoine Rozo
d an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/W23G6CWWXPCB3L5M2UGGLOEALO5WN4IN/ > Code of Conduct: http://python.org/psf/codeofcond

[Python-ideas] Re: Equality between some of the indexed collections

2020-05-02 Thread Antoine Rozo
5HGECRTS3ERK5OMG3GB77EKSAFJV7R/ >> Code of Conduct: http://python.org/psf/codeofconduct/ > > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.

[Python-ideas] Re: Equality between some of the indexed collections

2020-05-02 Thread Antoine Rozo
(and a check on the length or zip_longest to ensure that there is no other items) Le sam. 2 mai 2020 à 18:53, Antoine Rozo a écrit : > > And if you can't / don't want to create new lists for the values you > want to compare, a solution could be to use zip & all builtins: &

[Python-ideas] Re: SQL string prefix idea

2020-02-21 Thread Antoine Rozo
de of Conduct: http://python.org/psf/codeofconduct/ -- Antoine Rozo ___ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.py

[Python-ideas] Re: Proposal: Complex comprehensions containing statements

2020-02-21 Thread Antoine Rozo
> Would you feel better if `yield` was always required? Yes but then it's the same as defining a generator-function. > For almost all the examples I've provided a corresponding equivalent in the > current syntax, so are you saying that you're still confused now or that you > can't figure it out

[Python-ideas] Re: Proposal: Complex comprehensions containing statements

2020-02-21 Thread Antoine Rozo
line.strip(): > stripped > ] > > I think both of these look great and are easily better than any of the other > options. And I think it would be the clear winner in any similar situation - > no careful judgement needed. This would become the one (and only o

[Python-ideas] Re: Add Binary module.

2020-02-16 Thread Antoine Rozo
to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/RJLGYE4N7NR6JYFSA64VES375U45PIKW/ > Code of Conduct: http://python.org/psf/codeofconduct/ -- An

[Python-ideas] Re: Add Binary module.

2020-02-16 Thread Antoine Rozo
-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/VGPNG4IBWGRWPEQOAKCNTLBINWQS4BZO/ > Code of Conduct: http://python.org/psf/codeofconduct/ -- Antoine Rozo __

[Python-ideas] Re: Annotated string literals

2020-02-03 Thread Antoine Rozo
g/message/GEBY52WVQBFB7J27MRJPZZPJMWUZZJWO/ > > Code of Conduct: http://python.org/psf/codeofconduct/ > ___ > Python-ideas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.py

[Python-ideas] Re: The "When" Keyword

2019-12-29 Thread Antoine Rozo
mail.python.org/archives/list/python-ideas@python.org/message/3VOQUSHPYTKLL65V6BUN4MMKKJOXCIKO/ > Code of Conduct: http://python.org/psf/codeofconduct/ -- Antoine Rozo ___ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to

[Python-ideas] Re: Moving PEP 584 forward (dict + and += operators)

2019-12-03 Thread Antoine Rozo
of the time > myself (the behavior is a bit more obvious). I'm mostly just curious if the > difference between |= and dict.update() would end up being similar as far as > performance goes, with |= having a negligible advantage over dict.update() in > most situations. >

[Python-ideas] Re: Ability to specify function for auto-test in Enum and pass the given value as an argument to _generate_next_value_

2019-10-27 Thread Antoine Rozo
; What if I want to set my enum item to an empty tuple? -- Antoine Rozo ___ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.

[Python-ideas] Re: Additional meanings for "in" operator and ability to customize implementation

2019-10-13 Thread Antoine Rozo
deas mailing list -- python-ideas@python.org > To unsubscribe send an email to python-ideas-le...@python.org > https://mail.python.org/mailman3/lists/python-ideas.python.org/ > Message archived at > https://mail.python.org/archives/list/python-ideas@python.org/message/LOWRX42JL3SWG4QSOMV3WX4SOLJ

Re: [Python-ideas] ternary without else

2018-05-26 Thread Antoine Rozo
Dismiss my message, I have read `if "art_wt" not in article`. But in the same way, you could have a function to reset a value in your dict if the current value evaluates to False. 2018-05-26 11:21 GMT+02:00 Antoine Rozo : > > if not article["art_wt"]: article["

Re: [Python-ideas] ternary without else

2018-05-26 Thread Antoine Rozo
Python-ideas@python.org >> https://mail.python.org/mailman/listinfo/python-ideas >> Code of Conduct: http://python.org/psf/codeofconduct/ >> > > > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > > -- Antoine Rozo ___ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/

Re: [Python-ideas] Allow additional separator character in variables

2017-11-18 Thread Antoine Rozo
. > > So is my proposal, and as usual urging for constructive conversation. > (i.e. proposing to write own language/translator is not constructive > conversation) > > > Cheers, > Mikhail > _______ > Python-ideas mailing list > Python-ideas@python

Re: [Python-ideas] install pip packages from Python prompt

2017-10-29 Thread Antoine Rozo
o execute the > > following line in their Python interpreter. > >pip("install woolamaloo-sheepshavers-goodies --user") > > which will install a package which will in turn, as dependencies, > > pull in a number of packages which are relevant for sheep shaving but > > which have nevertheless irresponsibly been

Re: [Python-ideas] Add a module itertools.recipes

2017-10-13 Thread Antoine Rozo
Chris Angelico : > On Sat, Oct 14, 2017 at 5:16 AM, Antoine Rozo > wrote: > > Hello, > > > > A very useful part of the itertools module's documentation is the section > > "Recipes", giving utility functions that use itertools iterators. > > But when y

[Python-ideas] Add a module itertools.recipes

2017-10-13 Thread Antoine Rozo
utils). Can we consider making itertools a package and adding a module itertools.recipes that implements all these utilility functions? Regards. -- Antoine Rozo ___ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/py

Re: [Python-ideas] Make map() better

2017-09-15 Thread Antoine Rozo
eel at > home in Python, and adopt it. I see this only has promoting a peaceful > coexistence. > > Another pain point is python uses [].append() and JS uses [].join() Having > a wrapper for append would be helpful. > > And for that matter, why isn't append/extend a global? I can add things to > lots of different collections. lists, sets, strings... > > > > > -- Antoine Rozo ___ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/

Re: [Python-ideas] Make map() better

2017-09-14 Thread Antoine Rozo
gt; anyone really planned for anyone to write multi-language code > involving Python and JS. > > ChrisA > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of C

Re: [Python-ideas] Make map() better

2017-09-14 Thread Antoine Rozo
t;>> point does a method become a global? A member? Do we take the path that >>> everything is a global? Or should all methods be members? So far it seems >>> arbitrary. >>> >> >> Okay, its arbitrary. >> >> Why is it called [].len instead of

Re: [Python-ideas] New PEP 550: Execution Context

2017-08-11 Thread Antoine Rozo
t()``? > --- > > ``PyThreadState_GetDict`` is a TLS, and some of its existing users > might depend on it being just a TLS. Changing its behaviour to follow > the Execution Context semantics would break backwards compatibility. > > > PEP 521 > --- > > :pep:`521` propose

Re: [Python-ideas] Pseudo methods

2017-08-04 Thread Antoine Rozo
understand > > ~Paul > > > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > > -- Antoine Ro

Re: [Python-ideas] namedtuple nit...

2017-07-28 Thread Antoine Rozo
>> a.foo = 'bar' > Traceback (most recent call last): > File "", line 1, in > AttributeError: 'A' object has no attribute 'foo' > > -Mike > > > On 2017-07-28 01:06, Antoine Rozo wrote: > >> > If an object has no

Re: [Python-ideas] namedtuple nit...

2017-07-28 Thread Antoine Rozo
, is it not effectively immutable? > > -Mike > > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > -- A

Re: [Python-ideas] ImportError raised for a circular import

2017-06-13 Thread Antoine Rozo
n? > > I am willing to work on a patch. > > Barry > > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > -- Antoine Rozo ___

Re: [Python-ideas] Dictionary destructing and unpacking.

2017-06-07 Thread Antoine Rozo
* locals().update(mydict) 2017-06-08 0:59 GMT+02:00 Antoine Rozo : > I think you want something similar to locals.update(mydict)? > > 2017-06-08 0:54 GMT+02:00 Erik : > >> On 07/06/17 23:42, C Anthony Risinger wrote: >> >>> Neither of these are really comparab

Re: [Python-ideas] Dictionary destructing and unpacking.

2017-06-07 Thread Antoine Rozo
rg/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > -- Antoine Rozo ___ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/

Re: [Python-ideas] π = math.pi

2017-06-01 Thread Antoine Rozo
ython.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > > > > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas

Re: [Python-ideas] JavaScript-Style Object Creation in Python (using a constructor function instead of a class to create objects)

2017-05-14 Thread Antoine Rozo
teve > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > -- Antoine Rozo __

Re: [Python-ideas] JavaScript-Style Object Creation in Python (using a constructor function instead of a class to create objects)

2017-05-14 Thread Antoine Rozo
avaScript's design that couldn't be done >>> better, and most of what it does are things that Python already does >>> better and has done better for years. In short, I don't see any >>> advantages at all to doing classes this way, and there are some >>> non-negligible disadvantages. >>> >> >> Interesting, didn't know that about Javascript. I also don't like >> Javascript's prototypes very much but thought adding "JavaScript-like" to >> the title might help explain what I meant. >> >> Leaving the possible replacement for classes aside, do you have an >> opinion specifically about the following? >> >> def obj.my_function(a, b): >>... >> >> as syntactic sugar for >> >> def my_function(a, b): >> ... >> >> obj.my_function = my_function >> >> In my experience this pattern comes actually up quite a bit. E.g. when >> working with these "symbolic" machine learning frameworks like theano or >> tensorflow. Apart from that it mixins very easy. >> >> What do you think are the odds of something like this actually making it >> into the Python and if greater than 0 in which timeframe? >> >> >> >>> -- >>> Brendan Barnwell >>> "Do not follow where the path may lead. Go, instead, where there is no >>> path, and leave a trail." >>> --author unknown >>> ___ >>> Python-ideas mailing list >>> Python-ideas@python.org >>> https://mail.python.org/mailman/listinfo/python-ideas >>> Code of Conduct: http://python.org/psf/codeofconduct/ >> >> >> Thanks, >> >> Simon >> >>> >>> >> ___ >> Python-ideas mailing list >> Python-ideas@python.org >> https://mail.python.org/mailman/listinfo/python-ideas >> Code of Conduct: http://python.org/psf/codeofconduct/ >> >> > ___ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ > > -- Antoine Rozo ___ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/