[issue26227] Windows: socket.gethostbyaddr(name) fails for non-ASCII hostname

2016-01-28 Thread Emanuel Barry
Emanuel Barry added the comment: If it worked for you, I assume it's fine and I probably did something wrong on my side. Thanks for the fix! -- ___ Python tracker <http://bugs.python.org/is

[issue26227] Windows: socket.gethostbyaddr(name) fails for non-ASCII hostname

2016-01-28 Thread Emanuel Barry
Emanuel Barry added the comment: Oh, sorry. The patch applies without any problem, then I re-compile everything and run, and the same error happens. I re-compiled just now to make double sure. -- ___ Python tracker <http://bugs.python.

[issue26227] Windows: socket.gethostbyaddr(name) fails for non-ASCII hostname

2016-01-28 Thread Emanuel Barry
Emanuel Barry added the comment: Yes, it's not all that urgent. And Victor's latest patch doesn't work, either :( I wonder if there's a way to (temporarily) modify the output of ``socket.gethostname()`` to be able to test suc

[issue26227] Windows: socket.gethostbyaddr(name) fails for non-ASCII hostname

2016-01-29 Thread Emanuel Barry
Emanuel Barry added the comment: For future reference, Victor's patch does fix it, I was checking the wrong thing when testing. -- ___ Python tracker <http://bugs.python.org/is

[issue26110] Speedup method calls 1.2x

2016-02-02 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue26110> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue26279] time.strptime does not properly convert out-of-bounds values

2016-02-03 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry title: Possible bug in time library -> time.strptime does not properly convert out-of-bounds values versions: -Python 3.2, Python 3.3, Python 3.4 ___ Python tracker <http://bugs.python.org/issu

[issue17446] doctest test finder doesnt find line numbers of properties

2016-02-04 Thread Emanuel Barry
Emanuel Barry added the comment: Left a comment on Rietveld. I don't have time right now to check the test, but I suspect you tested it before submitting the patch, so it should probably be fine. -- nosy: +ebarry stage: -> patch review __

[issue26291] Floating-point arithmetic

2016-02-04 Thread Emanuel Barry
Emanuel Barry added the comment: This is due to how floating point numbers are handled under the hood. See http://effbot.org/pyfaq/why-are-floating-point-calculations-so-inaccurate.htm and https://docs.python.org/3/tutorial/floatingpoint.html for some useful read about why Python behaves like

[issue26324] sum() incorrect on negative zeros

2016-02-09 Thread Emanuel Barry
Emanuel Barry added the comment: This is consistent with the advertised equivalence of sum(): >>> -0.0 + -0.0 + 0 0.0 This works as you'd expect: >>> sum([-0.0, -0.0], -0.0) -0.0 It has a start value of 0, and I don't think we should special-case thi

[issue26324] sum() incorrect on negative zeros

2016-02-09 Thread Emanuel Barry
Emanuel Barry added the comment: "Not trivial" might be an understatement. You need the start value to begin summing the items, but you may face with a non-repeatable generator with side-effects. Sure, you could special-case some builtins, but I'm not too keen on adding special

[issue26329] os.path.normpath("//") returns //

2016-02-10 Thread Emanuel Barry
Changes by Emanuel Barry : -- assignee: -> serhiy.storchaka nosy: +ebarry, serhiy.storchaka stage: -> needs patch type: -> behavior ___ Python tracker <http://bugs.python.or

[issue26364] pip uses colour in messages that does not work on white terminals

2016-02-15 Thread Barry Scott
New submission from Barry Scott: pip3 (3.5 on Mac OS X) is outputting a message in yellow that I can barely see on a white background terminal. "You are using pip version 7.1.2, however version 8.0.2 is available. You should consider upgrading via the 'pip install --upgrade pip

[issue26546] Provide translated french translation on docs.python.org

2016-03-20 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry stage: -> patch review ___ Python tracker <http://bugs.python.org/issue26546> ___ ___ Python-bugs-list mai

[issue26756] fileinput handling of unicode errors from standard input

2016-04-14 Thread Joel Barry
New submission from Joel Barry: The openhook for fileinput currently will not be called when the input is from sys.stdin. However, if the input contains invalid UTF-8 sequences, a program with a hook that specifies errors='replace' will not behave as expected: $ cat x.py import

[issue26756] fileinput handling of unicode errors from standard input

2016-04-14 Thread Joel Barry
Joel Barry added the comment: I was suggesting that the openhook could somehow be applied to a *reopening* of sys.stdin. Something like this: 326c326,329 < self._file = sys.stdin --- > if self._openhook: > self._fi

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-18 Thread Emanuel Barry
New submission from Emanuel Barry: `shutil.get_terminal_size()` will sometimes propagate `AttributeError: module has not attribute 'get_terminal_size'` to the caller. The call checks for NameError, which makes no sense, so I guess it must be an oversight. Attached patch fixes it.

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-18 Thread Emanuel Barry
Emanuel Barry added the comment: I think Rietveld doesn't like me because I made it a .diff file, and not a .patch file, but who knows. It's a bit of a shot in the dark though, because I can't reproduce an environment where `os.get_terminal_size()` doesn't exist. I'm

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-19 Thread Emanuel Barry
Emanuel Barry added the comment: On posix-based OSes, `os.get_terminal_size` might not exist ( https://hg.python.org/cpython/file/default/Modules/posixmodule.c#l12462 ), so this is needed. New patch file with tests included. -- Added file: http://bugs.python.org/file42522

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-19 Thread Emanuel Barry
Emanuel Barry added the comment: Hmm, if `sys.__stdout__` was deleted (or set to `None`), this would also raise an `AttributeError` when calling `shutil.get_terminal_size`, so I think that even if `os.get_terminal_size` is guaranteed to be always present (which it's not, IIUC), cat

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-19 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file42523/get_term_size_with_test2.patch ___ Python tracker <http://bugs.python.org/issue26801> ___ ___ Pytho

[issue26801] Fix shutil.get_terminal_size() to catch AttributeError

2016-04-19 Thread Emanuel Barry
Emanuel Barry added the comment: To be fair, I don't think we actually need a unit test to check if `os.get_terminal_size` exists, as we catch any `AttributeError` at all. I'd want to keep the except clause there to properly handle `sys.__stdout__` being `None` (or simply absen

[issue26809] `string` exposes ChainMap from `collections`

2016-04-20 Thread Emanuel Barry
Emanuel Barry added the comment: Patch fixes this the proper way by defining __all__ in the string module. -- keywords: +patch nosy: +ebarry Added file: http://bugs.python.org/file42536/string___all__.patch ___ Python tracker <http://bugs.python.

[issue26809] `string` exposes ChainMap from `collections`

2016-04-20 Thread Emanuel Barry
Emanuel Barry added the comment: Thanks SilentGhost, seems my brain decided not to see uppercase names :) Attached patch adds Formatter and Template as well. -- Added file: http://bugs.python.org/file42537/string___all___2.patch ___ Python tracker

[issue26809] `string` exposes ChainMap from `collections`

2016-04-20 Thread Emanuel Barry
Emanuel Barry added the comment: I added an underscore in front of ChainMap, but I kept the __all__ definition because I think it should be there regardless (like every module, basically). -- Added file: http://bugs.python.org/file42540/ChainMap___all__.patch

[issue26809] `string` exposes ChainMap from `collections`

2016-04-20 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file42541/ChainMap___all___2.patch ___ Python tracker <http://bugs.python.org/issue26809> ___ ___ Python-bug

[issue26823] Shrink recursive tracebacks

2016-04-21 Thread Emanuel Barry
New submission from Emanuel Barry: I recently suggested on Python-ideas ( https://mail.python.org/pipermail/python-ideas/2016-April/039899.html ) to shrink long tracebacks if they were all the same noise (recursive calls). Seeing as the idea had a good reception, I went ahead and implemented

[issue26823] Shrink recursive tracebacks

2016-04-21 Thread Emanuel Barry
Emanuel Barry added the comment: Yes, can't handle mutually recursive functions. I could maybe check for the last two or three functions, but that seems like unnecessary work for something that might not happen as often (I can see it being the case with e.g. __getattr__ though). If e

[issue26823] Shrink recursive tracebacks

2016-04-21 Thread Emanuel Barry
Emanuel Barry added the comment: The message is mostly a placeholder, but "message" is singular so I figured it would be obvious. But alas, if you are confused, others might be too. Propositions for a better message are welcome :) I'll attempt to make it track chained cal

[issue26823] Shrink recursive tracebacks

2016-04-21 Thread Emanuel Barry
Emanuel Barry added the comment: Attached patch also modifies Lib/traceback.py to present identical behaviour, and changes "Previous message" to "Previous line". I'll postpone the more complex implementation of that, and might just not do it as it's indeed bet

[issue26823] Shrink recursive tracebacks

2016-04-22 Thread Emanuel Barry
Emanuel Barry added the comment: New version with tests now, I test both the C and Python implementations. -- assignee: -> ebarry Added file: http://bugs.python.org/file42570/short_tracebacks_3.patch ___ Python tracker <http://bugs.pyth

[issue26874] Docstring error in divmod function

2016-04-28 Thread Emanuel Barry
Emanuel Barry added the comment: The documentation looks fine to me. Are you seeing any other place that I'm missing? https://docs.python.org/3/library/functions.html#divmod -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/is

[issue26951] Unintuitive error when using generator expression in class property

2016-05-04 Thread Emanuel Barry
Emanuel Barry added the comment: Using a simple metaclass shows that definition order is not at fault here: >>> class PrintOrder(dict): ... def __setitem__(self, item, value): ... print(item, value) ... super().__setitem__(item, value) ... >>> class Show(type): ...

[issue27045] Forward slashes in Windows paths

2016-05-16 Thread Emanuel Barry
Emanuel Barry added the comment: Forward slashes work fine in Windows, for both the command line and PowerShell. Windows always displays backslahes, but accepts either (as well as any combination of both) in paths. -- assignee: docs@python -> nosy: +ebarry resolution: -> not

[issue26823] Shrink recursive tracebacks

2016-05-16 Thread Emanuel Barry
Emanuel Barry added the comment: I realize that I haven't given any update on this since my last patch. I figured that trying to detect when an arbitrary number of functions call each other in a convoluted call chain isn't a very good idea. Not only is it way beyond my abilities, b

[issue27048] Breakages in subprocess.Popen with non-ascii characters in environment

2016-05-17 Thread Emanuel Barry
New submission from Emanuel Barry: I got a random UnicodeDecodeError while trying to install a module with distutils. Traced it back and it being my name having a non-ascii character floating around in my environment. I'm including two patches: subprocess_errors_simple_1.patch simply

[issue27048] Breakages in subprocess.Popen with non-ascii characters in environment

2016-05-17 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file42881/subprocess_distutils_errors_1.patch ___ Python tracker <http://bugs.python.org/issue27048> ___ ___

[issue27048] Breakages in subprocess.Popen with non-ascii characters in environment

2016-05-17 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file42883/subprocess_distutils_errors_2.patch ___ Python tracker <http://bugs.python.org/issue27048> ___ ___

[issue27048] Breakages in subprocess.Popen with non-ascii characters in environment

2016-05-17 Thread Emanuel Barry
Emanuel Barry added the comment: The data that causes the issue is my name (Émanuel), which is present in a couple of places in my environment. I also completely forgot about surrogateescape, my bad. Here are two new patches with the surrogateescape error handler instead of the replace one

[issue27048] Breakages in subprocess.Popen with non-ascii characters in environment

2016-05-17 Thread Emanuel Barry
Emanuel Barry added the comment: Oops, I thought I had written that - must have accidentally deleted it. I'm on Windows 7, my locale is fr-CA / cp1252, and the non-ascii data (my name =) comes from my environment. I discussed a bit with R. David Murray off-issue, and in the end it seems

[issue27048] distutils._msvccompiler._get_vc_env() fails with UnicodeDecodeError if an env var is not encodable

2016-05-17 Thread Emanuel Barry
Emanuel Barry added the comment: You are right Martin, this also fixes it, and it seems much less controversial :) Here you go. -- Added file: http://bugs.python.org/file42885/distutils_windows_non_ascii_1.patch ___ Python tracker <h

[issue27122] Hang with contextlib.ExitStack and subprocess.Popen (regression)

2016-05-25 Thread Emanuel Barry
Emanuel Barry added the comment: Yes, and it seems that it is waiting for a review. http://bugs.python.org/issue25782 -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue27

[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

[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 <http://bugs.python.org/issue27

[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: -> n

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

2016-09-01 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ncoghlan, rhettinger ___ Python tracker <http://bugs.python.org/issue27933> ___ ___ Python-bugs-list mailing list Unsub

[issue27945] Various segfaults with dict

2016-09-02 Thread Emanuel Barry
Changes by Emanuel Barry : -- 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 tr

[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 s

[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 <http://bugs.python.org/is

[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.

[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file44433/invalid_stdlib_escapes_3_regen.patch ___ Python tracker <http://bugs.python.org/issue27

[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry
Changes by Emanuel Barry : Removed file: http://bugs.python.org/file44433/invalid_stdlib_escapes_3_regen.patch ___ Python tracker <http://bugs.python.org/issue27

[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file44435/invalid_stdlib_escapes_4.patch ___ Python tracker <http://bugs.python.org/issue27364> ___ ___ Pytho

[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

[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

[issue27364] Deprecate invalid escape sequences in str/bytes

2016-09-07 Thread Emanuel Barry
Changes by Emanuel Barry : Added file: http://bugs.python.org/file44457/invalid_stdlib_escapes_3_rebased_2.patch ___ Python tracker <http://bugs.python.org/issue27

[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 <http://bugs.python.org/is

[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_escap

[issue28028] Convert warnings to SyntaxWarning in parser

2016-09-08 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28028> ___ ___ Python-bugs-list mailing list Unsubscribe:

[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 <http://bugs.python.or

[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 b

[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 <http://bugs.python.org/is

[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 <http://bugs.python.org/issue27

[issue28050] test_traceback is broken by new CALL_FUNCTION* opcodes

2016-09-09 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28050> ___ ___ Python-bugs-list mailing list Unsubscribe:

[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 mess

[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 ob

[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 <http://bugs.python.org/issue27

[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 <http://bugs.python.org/issue28061> ___ ___

[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

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

2016-09-10 Thread Emanuel Barry
Changes by Emanuel Barry : -- components: +Windows nosy: +paul.moore, steve.dower, tim.golden, zach.ware ___ Python tracker <http://bugs.python.org/issue28

[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 i

[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 s

[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

[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 -> c

[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 <http://bugs.python.o

[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 w

[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 sp

[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 d

[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'

[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

[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 tr

[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 worr

[issue28243] Performance regression in functools.partial()

2016-09-21 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28243> ___ ___ Python-bugs-list mailing list Unsubscribe:

[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 <http://bugs.py

[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,

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

2016-10-10 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28410> ___ ___ Python-bugs-list mailing list Unsubscribe:

[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

[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: +Pyt

[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 progr

[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

[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

[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 go

[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

[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 <http://bugs.python.org/issu

[issue28028] Convert warnings to SyntaxWarning in parser

2016-10-31 Thread Emanuel Barry
Changes by Emanuel Barry : -- priority: high -> normal ___ Python tracker <http://bugs.python.org/issue28028> ___ ___ Python-bugs-list mailing list Unsubscrib

[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\\' A

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

2016-11-20 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28750> ___ ___ Python-bugs-list mailing list Unsubscribe:

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

2016-11-20 Thread Emanuel Barry
Changes by Emanuel Barry : -- stage: patch review -> commit review ___ Python tracker <http://bugs.python.org/issue28750> ___ ___ Python-bugs-list mai

[issue28751] Fix comments in code.h

2016-11-20 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28751> ___ ___ Python-bugs-list mailing list Unsubscribe:

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

2016-11-22 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker <http://bugs.python.org/issue28450> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue46142] python --help output is too long

2021-12-20 Thread Barry A. Warsaw
Change by Barry A. Warsaw : -- nosy: +barry ___ Python tracker <https://bugs.python.org/issue46142> ___ ___ Python-bugs-list mailing list Unsubscribe:

<    1   2   3   4   5   6   7   8   9   10   >