[issue28937] str.split(): remove empty strings when sep is not None

2019-03-19 Thread Emanuel Barry


Emanuel Barry  added the comment:

Unfortunately not. I no longer have the time or means to work on this, sorry. I 
hope someone else can pick it up.

--

___
Python tracker 
<https://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2019-03-19 Thread Emanuel Barry


Change by Emanuel Barry :


--
nosy:  -ebarry

___
Python tracker 
<https://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33892] doc Add a couple of "or she/her"

2018-06-17 Thread Emanuel Barry


Emanuel Barry  added the comment:

Nice initiative! I like the idea of moving towards more inclusive 
documentation; as an addition, I would recommend using they/them/their instead 
- it's less clumsy to read (also, singular they is perfectly valid English) and 
includes everyone, even those who may not use either he/him or she/her pronouns 
:)

All in all, great initiative, I encourage you to keep going in that direction!

--
nosy: +ebarry

___
Python tracker 
<https://bugs.python.org/issue33892>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33423] [logging] Improve consistency of logger mechanism.

2018-05-03 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

You don't have access to this feature, so I've deleted the message for you :)

--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33423>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33423] [logging] Improve consistency of logger mechanism.

2018-05-03 Thread Emanuel Barry

Change by Emanuel Barry <ba...@dadadata.net>:


--
Removed message: https://bugs.python.org/msg316153

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33423>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33410] Using type in a format with padding causes TypeError

2018-05-02 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

`type` has a default `__format__` implementation which doesn't accept any 
formatting options. This is expected behaviour.

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33410>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33401] `exec` attribute can't be set to objects in Python2 (SyntaxError)

2018-05-01 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

Any valid variable name can be used as a an attribute; for example, "spam" is 
valid while "spam-eggs" is not. This isn't unique to classes, but to all 
assignments everywhere. If we allowed `o.exec = blah` then we should also allow 
`exec = blah` at the global scope and that's a whole load of not happening, 
much less in Python 2 (which isn't getting any significant updates anymore).

--

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33401>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33401] `exec` attribute can't be set to objects in Python2 (SyntaxError)

2018-05-01 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

This is because `exec` is a keyword in Python 2, whereas in Python 3 it's a 
function.

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33401>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33035] Some examples in documentation section 4.7.2 are incorrect

2018-03-09 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

The documentation is correct. The first argument in both of those cases is a 
str, which may not be what you were expecting, but the calls are still valid.

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue33035>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32912] Raise non-silent warning for invalid escape sequences

2018-02-24 Thread Emanuel Barry

Change by Emanuel Barry <ba...@dadadata.net>:


--
keywords: +patch
pull_requests: +5625
stage: needs patch -> patch review

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue32912>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2018-02-22 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

I have created Issue32912 as a follow-up to this issue for 3.8.

--

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32912] Raise non-silent warning for invalid escape sequences

2018-02-22 Thread Emanuel Barry

New submission from Emanuel Barry <ba...@dadadata.net>:

This is a follow-up to Issue27364.

Back in Python 3.6, a silent warning was added for all invalid escape sequences 
in str and bytes. It was suggested that it would remain a silent warning (which 
still impacts tests, while not visually annoying the average user) for two 
releases (3.6 and 3.7), then would be upgraded to a non-silent warning for two 
subsequent releases (3.8 and 3.9) before becoming a full-on syntax error. With 
the 3.7 feature freeze on and going, I think it's time to evaluate the approach 
we take for 3.8 :)

I suggest upgrading the DeprecationWarning to a SyntaxWarning, which is visible 
by default, for 3.8 and 3.9. I have cross-linked #27364 to this issue as well.

-Em

--
components: Interpreter Core
messages: 312575
nosy: ebarry
priority: normal
severity: normal
stage: needs patch
status: open
title: Raise non-silent warning for invalid escape sequences
type: behavior
versions: Python 3.8

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue32912>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31952] Weird behavior on tupple item assignment

2017-11-05 Thread Emanuel Barry

Emanuel Barry <ba...@dadadata.net> added the comment:

This is a known issue, and is properly explained here: 
https://docs.python.org/3/faq/programming.html#why-does-a-tuple-i-item-raise-an-exception-when-the-addition-works

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue31952>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30524] iter(classmethod, sentinel) broken for Argument Clinic class methods?

2017-05-31 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +haypo, serhiy.storchaka
stage:  -> needs patch
type:  -> behavior

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue30524>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28794] inspect.isasyncgen and inspect.isasyncgenfunction aren't documented

2016-12-15 Thread Emanuel Barry

Emanuel Barry added the comment:

LGTM. Thanks for the patch!

--
nosy: +ebarry
stage:  -> commit review

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28794>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28961] unittest.mock._Call ignores `name` parameter

2016-12-14 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
stage: needs patch -> commit review

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28961>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28961] unittest.mock._Call ignores `name` parameter

2016-12-13 Thread Emanuel Barry

Emanuel Barry added the comment:

That indeed looks like a bug. Well spotted :)

That code has been there since unittest.mock was added back in March 2012. If I 
were to guess, I'd say that it should be `if name is None: name = ''`. Care to 
submit a patch?

--
nosy: +ebarry, michael.foord
stage:  -> needs patch
title: Is it a bug(method `_Call.__new__` in unittest.mock)? -> 
unittest.mock._Call ignores `name` parameter
type: enhancement -> behavior
versions: +Python 3.5, Python 3.6

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28961>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-12 Thread Emanuel Barry

Emanuel Barry added the comment:

Barry: Sure, the docs example was just a quick write-up, you can word it 
however you want!

Guido: Pretty much, except the other way around (when prune is False, i.e. 
"don't remove empty strings").

The attached patch exposes the behaviour (it's identical to last night's, but 
I'm re-uploading it as an unrelated file went in), except that the `prune` 
argument isn't keyword-only (I didn't know how to do this, and didn't bother 
searching for just a proof-of-concept).

--
Added file: http://bugs.python.org/file45863/split_prune_1.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-12 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Removed file: http://bugs.python.org/file45853/split_prune_1.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Yes, I agree that being able to pass in a tuple would be really useful. As far 
as rolling out a custom function goes, I'd sooner reach for re.split than do 
that, so I don't really have a strong argument for either side. Feel free to 
play with the patch or make an entirely new one, though! I mainly submitted the 
patch to keep the discussion going, and eventually come to a concensus, but I 
don't have a strong opinion either way :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Here's an initial patch. It works exactly as discussed earlier, doesn't break 
any tests, and retains full backwards compatibility. No doc changes (except for 
the docstrings of str.[r]split) and no tests, as this is just a preliminary 
patch to see if there's any merit to the idea.

--
keywords: +patch
stage:  -> test needed
Added file: http://bugs.python.org/file45853/split_prune_1.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Matthew: Yes, that's exactly the way I was going about it.

Thank you Raymond for your comments (and your informative answer on that SO 
question).

I think that part of the problem is that no delimiter (or None) behaves 
differently than with a delimiter. If we wanted proper consistency, we would 
have needed to make passing None (or nothing) the same as passing whitespace, 
but alas, we have to work with what we have.

As you said, API complexity is a concern that needs to be addressed. I think 
that the most important part is how it's documented, and, if phrased correctly 
(which is non-trivial), could actually simplify the explanation.

Consider this draft:

***

The value of the `prune` keyword argument determines whether or not consecutive 
delimiters should be grouped together. If `prune` is not given or None, it 
defaults to True if sep is None or not given, and False otherwise.

If `prune` is True, consecutive delimiters (all whitespace if None or not 
given) are regarded as a single separator, and the result will not contain any 
empty string. The resulting list may be empty.

Otherwise, if `prune` is False, consecutive delimiters are not grouped 
together, and the result may contain one or more empty string. The resulting 
list will never be empty.

***

I may be oversimplifying this, but it seems to me that this might help some 
people by hopefully streamlining the explanation.

This still doesn't solve the issue where a user can't say "split on a space or 
a tab, but not newlines", which IMO is lacking in the design, but that may be 
for another issue ;)

I've wrapped up a basic patch which probably doesn't work at all; I'll put it 
up when it's at least partly working for everyone to look at.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Actually, there might be a way. We could make prune default to True if sep is 
None, and default to False if sep is not None. That way, we get to keep the 
existing behaviour for either case, while satisfying both of our use cases :)

If that's a bad idea (and it quite probably is), I'll retract it. But it's an 
interesting possibility to at least consider.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

That would work for my case, but it wouldn't for Barry's (unless I missed 
something). He wants a non-None argument to not leave empty strings, but I want 
a None argument to leave empty strings... I don't think there's a 
one-size-fits-all solution in this case, but feel free to prove me wrong :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Changing the behaviour when sep is None is a big backwards-compatibility break, 
and I'm not sure we'd even want that. It's logical to allow passing None to 
mean the same thing as NULL (i.e. no arguments), and the behaviour in that case 
has been like that for... well, long enough that changing it isn't really 
feasible.

I agree with Barry here, especially since this is a completely opt-in feature, 
and existing behaviour isn't changed without the user's knowledge.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28937] str.split(): remove empty strings when sep is not None

2016-12-11 Thread Emanuel Barry

Emanuel Barry added the comment:

I understand the feeling. However, in a project I maintain, we want the other 
way around - to be able to never have an empty list, even if the string is 
empty (we resorted to using re.split in the end, which has this behaviour). 
Consider:

rest = re.split(" +", rest)[0].strip()

This gives us None-like behaviour in splitting, at the cost of not actually 
using str.split.

I'm +1 on the idea, but I'd like some way to better generalize str.split use 
(not everyone knows you can pass None and/or an integer).

(At the same time, the counter arguments where str has too many methods, or 
that methods shouldn't do too much, also apply here.)

But I don't like bikeshedding too much, so let's just count me as +1 for your 
way, if there's no strong momentum for mine :)

--
nosy: +ebarry
type:  -> enhancement

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28937>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28869] __module__ attribute is not set correctly for a class created by direct metaclass call

2016-12-04 Thread Emanuel Barry

Emanuel Barry added the comment:

Oh, nicely spotted! Apparently I was wrong, and it does create a key; 
defaulting to __name__.

About the original issue, I don't think it's easily possible to fix, sadly.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28869>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28869] __module__ attribute is not set correctly for a class created by direct metaclass call

2016-12-04 Thread Emanuel Barry

Emanuel Barry added the comment:

As a matter of fact, A.__module__ in this case is abc.ABCMeta.__module__. A 
class body creates a __module__ key, while a direct metaclass call does not.

--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28869>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28868] Python advertising BeOpen.com domain

2016-12-04 Thread Emanuel Barry

Emanuel Barry added the comment:

Part of the copyright notice, as SilentGhost mentioned. This can't be removed.

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28868>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28866] Unexpected behavior resulting from mro() and __setattr__ in interactive mode

2016-12-04 Thread Emanuel Barry

Emanuel Barry added the comment:

Additionally, trying to access an attribute before assigning it will result in 
an AttributeError on all subsequent accesses (even if set).

I didn't manage to get a segfault, however.

--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28866>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue23722] During metaclass.__init__, super() of the constructed class does not work

2016-12-03 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue23722>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10444] A mechanism is needed to override waiting for Python threads to finish

2016-12-01 Thread Emanuel Barry

Emanuel Barry added the comment:

Let's just close this.

--
nosy: +ebarry
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10444>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28828] Connection reset by peer error when installing python packages

2016-11-28 Thread Emanuel Barry

Emanuel Barry added the comment:

Decorater: For very large projects, the switch from Python 2 to 3 is a 
non-trivial task that can take up years of work, and there are many reasons why 
one cannot switch.

On the issue, however, for all PyPi-related issues, please go to the PyPa 
GitHub: https://github.com/pypa/pypi-legacy/

--
nosy: +ebarry
resolution:  -> third party
stage:  -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28828>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28797] Modifying class __dict__ inside __set_name__

2016-11-24 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +Martin.Teichmann

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28797>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28797] Modifying class __dict__ inside __set_name__

2016-11-24 Thread Emanuel Barry

Emanuel Barry added the comment:

Ow!

I can confirm the bug still happens on latest trunk. Nice finding!

--
nosy: +ebarry, ned.deily, rhettinger, serhiy.storchaka
priority: normal -> release blocker
stage:  -> needs patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28797>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28450] Misleading/inaccurate documentation about unknown escape sequences in regular expressions

2016-11-22 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28450>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28751] Fix comments in code.h

2016-11-20 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28751>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28750] Replace string with bytes in doc of unicode-escape an raw-unicode-escape

2016-11-20 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
stage: patch review -> commit review

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28750>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28750] Replace string with bytes in doc of unicode-escape an raw-unicode-escape

2016-11-20 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28750>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28611] Syntax error when using raw strings ending with a backslash.

2016-11-04 Thread Emanuel Barry

Emanuel Barry added the comment:

That's how strings work, unfortunately. You can't end any string (raw or not) 
with an odd number of backslashes. You could do the following to get around 
this limitation:

>>> r"C:\Folder" "\\"
'C:\\Folder\\'

As a side note, please don't upload screenshots if what you're capturing 
consists only of text (you can paste it directly in your message). This makes 
it impossible to copy-paste input in the interpreter to try to replicate the 
issue, and makes it harder/impossible for the blind and visually-impaired to 
contribute. Thanks!

--
nosy: +ebarry
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed
type: compile error -> behavior

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28611>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28028] Convert warnings to SyntaxWarning in parser

2016-10-31 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
priority: high -> normal

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28028>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-10-31 Thread Emanuel Barry

Emanuel Barry added the comment:

Even better than what I was aiming for :)

--
dependencies:  -Convert warnings to SyntaxWarning in parser
priority: deferred blocker -> release blocker

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-10-31 Thread Emanuel Barry

Emanuel Barry added the comment:

As Nick pointed out in an earlier message on this thread and as Serhiy observed 
on GitHub issues, backporting this patch to 3.6 is a must. Large projects' use 
of Python 3.6 has shown that it's hard to track down the actual cause of the 
error; it only makes sense to improve that before the final release.

Serhiy, are you working on #28028 alongside this, or can it be removed from the 
dependencies?

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-10-30 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you Eric. Have you looked at making a new DeprecatedSyntaxWarning 
subclass of both DeprecationWarning and SyntaxWarning? Hopefully that's of some 
help.

I don't see a review link, but from a quick glance this looks good. Thanks :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28028] Convert warnings to SyntaxWarning in parser

2016-10-28 Thread Emanuel Barry

Emanuel Barry added the comment:

Cross-ping from #28128

I think it would be best to solve this issue, solving both #28128 and any 
future warning-introducing feature or deprecation. I've marked this issue as a 
dependency for #28128 as well as upping the priority. There are less than 7 
weeks before the final 3.6.0 release and I would like to get as much mileage 
out of this before then.

Thanks :)

--
nosy: +eric.smith, martin.panter, ncoghlan, ned.deily
priority: normal -> high
stage:  -> needs patch
versions: +Python 3.7

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28028>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-10-28 Thread Emanuel Barry

Emanuel Barry added the comment:

Following Ned's email to Python-Dev, I'm upping the priority of this issue to 
"deferred blocker".

I haven't had a lot of time to work on this, but I had time to think about it, 
and I think that resolving #28028 would be the best way to solved this. I 
pinged this issue as well and added several people to nosy there. I've also 
added it as a dependency of this issue.

To be clear, I really like Eric's approach to this, but I think that resolving 
#28028 would let us kill a couple of issues with the same patch. My priority is 
getting this issue here resolved, though, so either way works. I doubt I'll 
have much time to actually work on this; life's been busy and Python isn't my 
priority right now (as much as I'd like it to be).

--
dependencies: +Convert warnings to SyntaxWarning in parser
priority: normal -> deferred blocker

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28514] Python (IDLE?) freezes on file save on Windows

2016-10-23 Thread Emanuel Barry

Emanuel Barry added the comment:

Could provide more information on the issue? Which program exactly is failing? 
Is it the IDLE editor? If you don't know what you're using, you can provide a 
screenshot as a last resort (but don't provide one if you can figure out the 
program that freezes).

--
nosy: +ebarry
stage:  -> test needed
title: Crash -> Python (IDLE?) freezes on file save on Windows
type:  -> behavior
versions: +Python 3.6, Python 3.7

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28514>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27910] Doc/library/traceback.rst — references to tuples should be replaced with new FrameSummary object

2016-10-20 Thread Emanuel Barry

Emanuel Barry added the comment:

This is not a regression, the documentation was just not fully updated when the 
new feature was added. Patch looks good. This should probably be applied to the 
3.5 branch as well.

--
nosy: +ebarry
stage: patch review -> commit review
versions: +Python 3.7

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27910>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28410] Add convenient C API for "raise ... from ..."

2016-10-18 Thread Emanuel Barry

Emanuel Barry added the comment:

I see the function is private; is there any concern with extending the PyErr_* 
API? I think it'd make sense to expose it, since it's a convenient way to do in 
C what can already be done easily in Python, but I don't actually have a good 
reason :)

Other than this small nitpick, this LGTM.

(Alternatively, we can keep it private for 3.6 and revise that decision for 3.7)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28410>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28410] Add convenient C API for "raise ... from ..."

2016-10-10 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28410>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28376] rangeiter_new fails when creating a range of step 0

2016-10-06 Thread Emanuel Barry

Emanuel Barry added the comment:

I'm not able to trigger an assertion error when running the latest trunk in 
debug mode. I get a "valid" range_iterator object though, and using __reduce__ 
gives me direct access to `range(0, 0, 0)` (which is completely worthless).

Error or not, this should be fixed, and your patch LGTM. Thanks!

(I changed the type to 'behaviour' since I can't reproduce the assertion, but 
it doesn't make much of a difference)

--
nosy: +ebarry
stage:  -> patch review
title: assertion failure in rangeobject.c -> rangeiter_new fails when creating 
a range of step 0
type: crash -> behavior

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28376>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-10-02 Thread Emanuel Barry

Emanuel Barry added the comment:

Ping. I'd like for this to get merged in beta 2; should I (or Eric if he wants 
to) get to work on this? Is the DeprecatedSyntaxWarning subclass route still 
desired?

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28243] Performance regression in functools.partial()

2016-09-21 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28243>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-16 Thread Emanuel Barry

Emanuel Barry added the comment:

Personally I'd be fine with only one warning, reporting the first invalid 
escape. Presumably the string would be checked as a whole, or would get an r 
prefix. Patch seems like a good start; bytes would also need updating in that 
regard. Don't worry too much about the details, we can iron that out later :)

Also yeah, the fact that warnings are triggered at compile time results in 
surprising behaviour even for me. I'm liking the idea of a 
DeprecatedSyntaxWarning more.

I'll try to get some work done in that regard by the end of next week, but 
life's been somewhat busy so I can't give any guarantees. Thank you for your 
patch draft though, it helps me to figure out how I should tackle this!

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28180] sys.getfilesystemencoding() should default to utf-8

2016-09-16 Thread Emanuel Barry

Emanuel Barry added the comment:

This is a duplicate of issue27781.

--
nosy: +ebarry
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> Change sys.getfilesystemencoding() on Windows to UTF-8

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28180>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread Emanuel Barry

Emanuel Barry added the comment:

Hmm, I see; I'll need to dig a bit deeper get to and understand that part of 
the compile process better. I'll look up where SyntaxErrors are generated 
(since they have access to at least the line number at that point), and try to 
hook it up from there.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you Nick for the useful feedback! I think that a subclass of 
DeprecationWarning and SyntaxWarning would be a good idea; I'll play around 
with that.

As far as when the warning should occur, I agree that erroring out at the 
compile step isn't optimal, however (AFAIK) strings aren't checked again once 
they've been created; they're assumed to be correct (and checking them at 
runtime would presumably add a performance hit to *all* strings, which I think 
is too big a price to pay).

On the other hand, a way to ignore invalid escapes in certain files could be 
considered, but we need to be somewhat careful since some people might choose 
to silence all warnings, thus defeating the purpose.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread Emanuel Barry

Emanuel Barry added the comment:

There definitely needs to be a better message for that. The problem is that the 
parser doesn't have access to the whole string (of course; it's being 
constructed!), so I think there are several possible venues here:

- Change DeprecationWarning to display the line which is faulty (unlikely);
- Promote these specific warnings to SyntaxErrors *only* if the warning is an 
error (i.e. Python was run with -W error), in which case the compilation of 
code is stopped either way, so there is no drawback (but only being a syntax 
error "sometimes" is likely to confuse people);
- Use a different warning class, but presumably we'd need a new one and we 
can't do that now since we're in beta (unless Ned thinks this is appropriate, 
but I doubt it).

Anything else, maybe? I'm sure there is a way to properly fix it; my personal 
favourite all things considered is the second option (which I've thought over 
and over recently), but I'm open to other, less intrusive alternatives.

My intention is to make this deprecation the least painful possible for 
application and third-party library developers. As such, I think adding a note 
to the docs (possibly in What's New, but probably also under a few other 
related places) is good, and probably doing a preemptive SO question+answer for 
people who stumble upon this.

I've added to nosy a couple of people whose feedback I believe could be very 
helpful.

--
nosy: +brett.cannon, ncoghlan, rhettinger, yselivanov

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-15 Thread Emanuel Barry

Emanuel Barry added the comment:

Besides converting the DeprecationWarning to a Syntax{Error,Warning}, I don't 
see an easy way to include the offending line (or even file). The place in the 
code where the strings are created has no idea *where* they are being defined. 
AIUI, either we special-case this, or we resolve #28028 (but I don't think the 
latter can go in 3.6).

--
assignee: ebarry -> 

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28128] Improve the warning message for invalid escape sequences

2016-09-13 Thread Emanuel Barry

Emanuel Barry added the comment:

Hello, and thanks! I'll work on a patch this week, or at most next week. I will 
make it so that it's completely uncontroversial to apply it to 3.6 as well 
(won't change the actual feature, only prettify the error message), so no need 
to worry about that :)

--
assignee:  -> ebarry
components:  -Library (Lib)
nosy: +ebarry
stage:  -> needs patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28128>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-12 Thread Emanuel Barry

Emanuel Barry added the comment:

Fair enough, but please open a new issue for that.

@Terry - you're welcome; that's exactly the reason I pushed for it :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Compact dict bug on Windows (Visual Studio): if (mp->ma_keys->dk_usable * 3 < other->ma_used * 2)

2016-09-12 Thread Emanuel Barry

Emanuel Barry added the comment:

I actually did a clean rebuild and could not reproduce, so I'm guessing 
something did go wrong on my side.

--
priority: deferred blocker -> normal
resolution:  -> not a bug
stage: needs patch -> resolved
status: open -> closed
type: crash -> 

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Fair enough; I can see why such an addition would be a good idea. But please 
open a new issue for that (add me to nosy); I don't want this issue to be 
further cluttered.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Compact dict bug on Windows (Visual Studio): if (mp->ma_keys->dk_usable * 3 < other->ma_used * 2)

2016-09-11 Thread Emanuel Barry

Emanuel Barry added the comment:

I don't know what exactly happened that would make it crash, but after wiping 
off everything and starting over, it works fine now. Sorry for the noise!

--
components:  -Windows
priority: release blocker -> normal
resolution:  -> not a bug
stage: needs patch -> resolved
status: open -> closed
type: crash -> 

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Compact dict bug on Windows (Visual Studio): if (mp->ma_keys->dk_usable * 3 < other->ma_used * 2)

2016-09-11 Thread Emanuel Barry

Emanuel Barry added the comment:

Huh, weird. I'm running a win32 build on a 64 bits machine, with VS2015. I 
didn't have time to test on a clean checkout, I will do that first thing when 
I'm back home tonight. I hope I did something wrong and there really isn't any 
issue :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Python crashes on 'from test import support'

2016-09-10 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
components: +Windows
nosy: +paul.moore, steve.dower, tim.golden, zach.ware

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Python crashes on 'from test import support'

2016-09-10 Thread Emanuel Barry

Emanuel Barry added the comment:

I compiled, I got a "Python stopped working" during compiling (but it went on 
anyway), and then launched it from VS in Debugging mode. I did 'from test 
import support' and then it crashed. VS said this line was the faulty one, and 
didn't give me anything else useful (no call stack, no access to locals, etc.). 
I'm sadly not home until Monday, so I can't further investigate this.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Python crashes on 'from test import support'

2016-09-10 Thread Emanuel Barry

Emanuel Barry added the comment:

Latest, i.e. https://hg.python.org/cpython/rev/a477ef882a16

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-10 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you Nick! I just opened #28062 to fix the repr inconsistency between 
functools.partial and any subclass :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28062] Streamline repr(partial object)

2016-09-10 Thread Emanuel Barry

New submission from Emanuel Barry:

This is a followup to #27137, where it was found out the repr of a partial 
object includes the module (i.e. 'functools') only if it's not a subclass. This 
behaviour is surprising at best. Attached patch streamlines the reprs of 
partial objects to always include the module.

Raymond, do you remember why this approach was taken? Looking at the code, it 
seems it was just the easiest way to go about it.

Side-note: I couldn't run the test suite since I ran into #28061, so I just did 
manual testing.

--
components: Library (Lib)
files: functools_partial_repr_1.patch
keywords: patch
messages: 275628
nosy: ebarry, ncoghlan, rhettinger, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Streamline repr(partial object)
type: behavior
versions: Python 3.6
Added file: http://bugs.python.org/file44529/functools_partial_repr_1.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28062>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28061] Python crashes on 'from test import support'

2016-09-10 Thread Emanuel Barry

New submission from Emanuel Barry:

VS breaks at line Objects/dictobject.c:2339 - 'if 
(mp->ma_keys->dk_usable * 3 < other->ma_used * 2)'

I don't have any more useful information; I'm running Windows 7.

--
components: Interpreter Core
messages: 275627
nosy: ebarry, haypo, methane, ned.deily, serhiy.storchaka
priority: release blocker
severity: normal
stage: needs patch
status: open
title: Python crashes on 'from test import support'
type: crash
versions: Python 3.6

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28061>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28050] test_traceback is broken by new CALL_FUNCTION* opcodes

2016-09-09 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28050>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27945] Various segfaults with dict

2016-09-09 Thread Emanuel Barry

Emanuel Barry added the comment:

Ping. The built-in dict was considerably changed in #27350; do any of these 
issues still persist?

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27945>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-09 Thread Emanuel Barry

Emanuel Barry added the comment:

The patch LGTM and applies fine. Looks like there's no need to wait for beta 2 
after all; thanks Serhiy!

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-08 Thread Emanuel Barry

Emanuel Barry added the comment:

Can this be merged even with the two failing tests? I have little to no time 
available to fix it properly before the feature freeze. We can skip/silence 
those tests for a bit; I'll open a new issue and fix it in time for beta 2.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-08 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you David for taking the time to review and commit this :)

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28028] Convert warnings to SyntaxWarning in parser

2016-09-08 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28028>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-08 Thread Emanuel Barry

Emanuel Barry added the comment:

All right, since you'll work on it I'm leaving it out. Removed it and 
test_bytes (which you already fixed, thanks!) from new patch.

--
Added file: http://bugs.python.org/file44465/invalid_stdlib_escapes_5.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-08 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you R. David for the review, here's a new patch with the one change.

--
Added file: http://bugs.python.org/file44463/invalid_stdlib_escapes_4.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Added file: 
http://bugs.python.org/file44457/invalid_stdlib_escapes_3_rebased_2.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-07 Thread Emanuel Barry

Emanuel Barry added the comment:

Thank you Serhiy for the comments! Here's a new patch. I'm fine with the 
recursive repr tests failing for now; it's something I believe we can fix 
during the beta phase if we don't have time before (fix as in modify the C 
implementation to match the Python version instead of the other way around).

--
Added file: http://bugs.python.org/file44450/functools_partial_4.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-07 Thread Emanuel Barry

Emanuel Barry added the comment:

Hi Nick, thank you for letting me know! I started trying to fix this, however I 
found it very hard to fix the recursive repr issue. I've whipped up an 
incomplete (but yet working) patch that fixes all but the recursive repr issue. 
Only those two tests fail (once for functools.partial and once for the 
subclass). I have to go for now, but feel free to play with this patch and see 
if you can fix it. The problem is that the way it's handled is inconsistent 
within the C implementation, and is incompatible with reprlib.recursive_repr. I 
might try my hand at it later today or tomorrow.

In the meantime, I think maybe the C implementation cares too much about the 
special cases for that.

--
Added file: 
http://bugs.python.org/file44436/functools_partial_3_1_incomplete.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Added file: http://bugs.python.org/file44435/invalid_stdlib_escapes_4.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Removed file: 
http://bugs.python.org/file44433/invalid_stdlib_escapes_3_regen.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Added file: 
http://bugs.python.org/file44433/invalid_stdlib_escapes_3_regen.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry

Emanuel Barry added the comment:

Rebased patch after Victor's commit in #16334. Also regenerated 
invalid_stdlib_escapes_3 in the hopes that Rietveld picks it up.

--
Added file: 
http://bugs.python.org/file44432/deprecate_invalid_escapes_both_4.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27137] Python implementation of `functools.partial` is not a class

2016-09-05 Thread Emanuel Barry

Emanuel Barry added the comment:

We're one week from the feature freeze, seems like a good time to merge this :)

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27137>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-05 Thread Emanuel Barry

Emanuel Barry added the comment:

Updated and rebased patch. There's a few file tweaks here and there to stay up 
to date, otherwise it's mostly the same.

Martin, it may look like I've ignored your comments, but I'm trying to keep the 
patches as simple as possible, and so I don't want to go further than to make 
strings into raw strings (also the alignment issue you pointed out). I'd rather 
have the other issues addressed in another issue, as I want to get this merged 
in time for the feature freeze. The other issues (some which were already 
present) can be taken care of during the beta phase.

--
title: Deprecate invalid unicode escape sequences -> Deprecate invalid escape 
sequences in str/bytes
Added file: http://bugs.python.org/file44382/invalid_stdlib_escapes_3.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27945] Various segfaults with dict

2016-09-02 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ebarry, larry, ned.deily, rhettinger, serhiy.storchaka
priority: normal -> critical
stage:  -> needs patch
title: five dictobject issues -> Various segfaults with dict
type:  -> crash

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27945>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27933] functools.lru_cache seems to not work when renaming decorated functions

2016-09-01 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


--
nosy: +ncoghlan, rhettinger

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27933>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27929] asyncio.AbstractEventLoop.sock_connect broken for AF_BLUETOOTH

2016-09-01 Thread Emanuel Barry

Emanuel Barry added the comment:

Thanks for the report! I'm unable to reproduce, as `socket.AF_BLUETOOTH` 
doesn't exist on my system, but surely someone else can.

--
keywords: +3.5regression
nosy: +ebarry, ned.deily
priority: normal -> high
stage:  -> needs patch
title: asyncio.AbstractEventLoop.sock_connect brooken for AF_BLUETOOTH -> 
asyncio.AbstractEventLoop.sock_connect broken for AF_BLUETOOTH
type:  -> behavior

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27929>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid unicode escape sequences

2016-09-01 Thread Emanuel Barry

Emanuel Barry added the comment:

Thanks Serhiy; it does look better to me too!

--
Added file: 
http://bugs.python.org/file44322/deprecate_invalid_escapes_both_3.patch

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27364] Deprecate invalid unicode escape sequences

2016-09-01 Thread Emanuel Barry

Emanuel Barry added the comment:

Ping. I'd like to get this merged in time for 3.6. Is there anything I can do 
to speed up the review?

Since the change itself is very straightforward, I think this would make sense 
to merge it now and then fix the invalid escapes that are found during the beta 
phase.

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue27364>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27877] Add recipe for "valueless" Enums to docs

2016-08-28 Thread Emanuel Barry

Emanuel Barry added the comment:

The patch doesn't apply. I manually copy-pasted the lines in the source and 
generated a new one.

I would probably rephrase "these values hold no meaning and should not be used" 
into "the values are not important" or something along those lines.

--
nosy: +ebarry
Added file: https://bugs.python.org/file44250/enum_valueless_1.patch

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27877>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27882] Python docs on 9.2 Math module lists math.log2 as function but it does not exist

2016-08-27 Thread Emanuel Barry

New submission from Emanuel Barry:

The function does definitely exist for me. Please make sure your Python version 
is up-to-date. Also, please post a short summary of the issue, and avoid 
screenshots whenever possible; it's more work for you, makes it harder for us 
to reproduce/follow (need to manually type everything back), and makes it 
impossible for the blind and visually impaired to participate. Thanks!

--
assignee: docs@python -> 
components:  -Documentation
nosy: +ebarry
status: open -> pending

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27882>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27425] Tests fail because of git's newline preferences on Windows

2016-08-27 Thread Emanuel Barry

Emanuel Barry added the comment:

Martin: Indeed, seems like it's backwards for some reason. I'm not sure what 
happened when I regenerated the index; I removed the patches now anyway. I 
think the .gitattributes patch would be fine to go on its own.

It's my understanding that line endings don't matter for XML files, so it would 
probably be a better move to fix xml.sax instead of the test. I'll likely open 
a new issue if we decide to do that.

--

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27425>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27425] Tests fail because of git's newline preferences on Windows

2016-08-27 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Removed file: https://bugs.python.org/file44220/fix_newlines_1.patch

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27425>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27425] Tests fail because of git's newline preferences on Windows

2016-08-27 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Removed file: https://bugs.python.org/file44225/fix_newlines_2.patch

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27425>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27425] Tests fail because of git's newline preferences on Windows

2016-08-25 Thread Emanuel Barry

Changes by Emanuel Barry <ba...@dadadata.net>:


Added file: https://bugs.python.org/file44225/fix_newlines_2.patch

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27425>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27425] Tests fail because of git's newline preferences on Windows

2016-08-25 Thread Emanuel Barry

Emanuel Barry added the comment:

Whoops, turns out I was using the wrong approach for binary files. Here come 
add_gitattributes_2.patch and fix_newlines_2.patch (thanks Zachary for pointing 
this out).

--
Added file: https://bugs.python.org/file44224/add_gitattributes_2.patch

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue27425>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   3   4   >