On Wed, May 20, 2020 at 11:09 AM Jim J. Jewett <jimjjew...@gmail.com> wrote:
> David Mertz wrote: > > > Fwiw, I don't think it changes my order, but 'strict' is a better word > than > > 'equal' in all those places. I'd subtract 0.1 from each of those votes if > > they used "equal". > > I would say that 'equal' is worse than 'strict'. but 'strict' is also > wrong. > > Zipping to a potentially infinite sequence -- like a manual enumerate -- > isn't wrong. It may be the less common case, but it isn't wrong. Using > 'strict' implies that there is something sloppy about the data in, for > example, cases like Stephen J. Turnbull's lagged time series. > > Unfortunately, the best I can come up with is 'same_length', or possibly > 'equal_len' or 'equal_length'. While those are better semantically, they > are also slightly too long or awkward. I would personally still consider > 'same_length' the least bad option. > > -jJ > As we've come down to naming things... if you want it to read more like English, `zip(vorpal_rabbits, holy_hand_grenades, lengths_must_match=True)` or another chosen variation of that such as `len_must_match=` or `length_must_match=` reads nicely and is pretty self explanatory that an error can be expected if the condition implied by the "must" is found untrue without really feeling a need to look it up in documentation. It is also harder to type or fit on a line. Which is one advantage to a short thing like `strict=`. I don't care so much about the particular spelling here to argue among any of those, I primarily want the feature to exist. I expect we're entering steering council territory for a decision soon... -gps _______________________________________________ > Python-Dev mailing list -- python-dev@python.org > To unsubscribe send an email to python-dev-le...@python.org > https://mail.python.org/mailman3/lists/python-dev.python.org/ > Message archived at > https://mail.python.org/archives/list/python-dev@python.org/message/G5JTZI6SARFG5AA3H2XJUIUNXR2TBNQ4/ > Code of Conduct: http://python.org/psf/codeofconduct/ >
_______________________________________________ Python-Dev mailing list -- python-dev@python.org To unsubscribe send an email to python-dev-le...@python.org https://mail.python.org/mailman3/lists/python-dev.python.org/ Message archived at https://mail.python.org/archives/list/python-dev@python.org/message/TGLTTQ7PKYSWYBYVKE6PHUH5RLJSDUH5/ Code of Conduct: http://python.org/psf/codeofconduct/