[issue13359] urllib2 doesn't escape spaces in http requests

2017-06-02 Thread Martin Panter
Martin Panter added the comment: I think this could be merged with Issue 14826. Maybe it is sensible to handle all control characters the same way. -- nosy: +martin.panter resolution: -> duplicate superseder: -> urlopen URL with unescaped space

[issue30535] Explicitly note that meta_path is not empty

2017-06-02 Thread Nick Coghlan
Nick Coghlan added the comment: s/Warn/Explicitly note/ in the issue title :) I think this is actually both important enough and subtle enough to warrant a ".. note::" callout in the docs. In Python 3, it would say to use `sys.meta_path.insert(0, finder)` if you want your finder to take

[issue30558] [Suggestion] Improve documentation for set() API

2017-06-02 Thread Jacob Pratt
New submission from Jacob Pratt: While going through the documentation, I found that set() has surprisingly little documentation, not even a list of built-in methods. I'm not sure exactly what is missing, but I know that issubset and issuperset isn't in there (that's what I was looking for,

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Chris Angelico
On Sat, Jun 3, 2017 at 11:46 AM, Gregory Ewing wrote: > Chris Angelico wrote: >> >> with psycopg2.connect(...) as conn: >> with conn.trans() as trn: >> for row in trn.execute("select ..."): >> print(row) >> >> The outer context manager is

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Gregory Ewing
Chris Angelico wrote: with psycopg2.connect(...) as conn: with conn.trans() as trn: for row in trn.execute("select ..."): print(row) The outer context manager is optional, but not the inner one While I fully support making the use of transactions mandatory, I wouldn't

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Gregory Ewing
Chris Angelico wrote: Always using a context manager is good practice and great for code clarity. Another thing about my Firebird interface was that you were forced to always use transactions, because the transaction object was the only thing that had methods for executing statements. -- Greg

[issue30510] c_bool type not supported for BigEndianStructure on little-endian machine

2017-06-02 Thread Terry J. Reedy
Terry J. Reedy added the comment: Please post or upload minimal code that reproduces the problem for you. -- nosy: +terry.reedy ___ Python tracker ___

[issue30509] Optimize calling type slots

2017-06-02 Thread Terry J. Reedy
Terry J. Reedy added the comment: I believe Rietveld does not work with git-format patches. I don't know if git can produce the format hg did. -- nosy: +terry.reedy ___ Python tracker

[issue30498] Run Python's slowest tests in the first 3/4 of tests when using -r

2017-06-02 Thread Terry J. Reedy
Terry J. Reedy added the comment: Starting longer running tests sooner only make sense if one runs them in parallel with -jn. I just tried installed 64 bit 3.6.1 with -r -j12 (forgot -ugui). Total duration: 108 seconds. The last to finish was test_multiprocessing_spawn after 84 seconds, 5

Psycopg2 pool clarification

2017-06-02 Thread Israel Brewster
I've been using the psycopg2 pool class for a while now, using code similar to the following: >>> pool=ThreadedConnectionPool(0,5,) >>> conn1=pool.getconn() >>> >>> pool.putconn(conn1) repeat later, or perhaps "simultaneously" in a different thread. and my understanding was that the pool

[issue30542] [EASY] test_files() of test_tools.test_unparse.DirectoryTestCase leaks references

2017-06-02 Thread Milan Oberkirch
Milan Oberkirch added the comment: I tried to pin this leak down and got to the point where I suspect the compile call: def check_roundtrip(self, code1, filename="internal"): ast1 = compile(code1, filename, "exec", ast.PyCF_ONLY_AST) the leaks occur with only that line in the

[issue30489] Add CmdLineTest to standard library

2017-06-02 Thread Terry J. Reedy
Terry J. Reedy added the comment: Santiago, an idea like this (one that requests a reversal of previous decisions) should be discussed first on the python-ideas list. Such a discussion would need to result in a specific proposal of what to extract from test_cmd_line_script.py and where to

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Chris Angelico
On Sat, Jun 3, 2017 at 7:29 AM, Dennis Lee Bieber wrote: > On Sat, 3 Jun 2017 06:48:28 +1000, Chris Angelico > declaimed the following: > >> >>Wait, you have transactions with MyISAM now? I thought MySQL supported >>transactions with InnoDB but not

[issue30486] Allow setting cell value

2017-06-02 Thread Antoine Pitrou
Antoine Pitrou added the comment: There's already a documentation change to the PR, you can leave your comments there. -- ___ Python tracker ___

[issue30486] Allow setting cell value

2017-06-02 Thread Terry J. Reedy
Terry J. Reedy added the comment: A possible counter-indication would be if setting a cell could cause a crash, as opposed to a mysterious exception. Since 3.x already allows writing any object to a cell from python code, def outer(): cell = None def inner(ob): nonlocal cell

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Steve Dower
Changes by Steve Dower : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker ___

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Steve Dower
Steve Dower added the comment: New changeset c63ae1122f84d4188ffadfd1454902093eb10be1 by Steve Dower in branch '3.6': bpo-30544: _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails (#1912) (#1925)

HD LIVE مسلسل غرابيب سود الحلقة 8 @) ))MBC(( مشاهدة غرابيب سود الحلقة 8 الثامنة كاملة LBC

2017-06-02 Thread 6hktt . com
HD LIVE مسلسل غرابيب سود الحلقة 8 @) ))MBC(( مشاهدة غرابيب سود الحلقة 8 الثامنة كاملة LBCHD LIVE مسلسل غرابيب سود الحلقة 8 @) ))MBC(( مشاهدة غرابيب سود الحلقة 8 الثامنة كاملة LBCHD LIVE مسلسل غرابيب سود الحلقة 8 @) ))MBC(( مشاهدة غرابيب سود الحلقة 8 الثامنة كاملة LBCHD LIVE مسلسل غرابيب سود

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Steve Dower
Changes by Steve Dower : -- pull_requests: +2005 ___ Python tracker ___ ___

[issue30557] faulthandler does not correctly filter fatal exceptions on Windows

2017-06-02 Thread Steve Dower
Changes by Steve Dower : -- pull_requests: +2004 ___ Python tracker ___ ___

[issue30557] faulthandler does not correctly filter fatal exceptions on Windows

2017-06-02 Thread Steve Dower
Steve Dower added the comment: Also, it displays exception codes as decimal, but should be hex. I'll fix that too -- ___ Python tracker ___

[issue30557] faulthandler does not correctly filter fatal exceptions on Windows

2017-06-02 Thread Steve Dower
New submission from Steve Dower: faulthandler adds a structured exception handler on Windows so we can dump a Python traceback before crashing. This should only be done for fatal exceptions, but is currently done for some non-fatal exceptions. The current test is `flags &

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Chris Angelico
On Sat, Jun 3, 2017 at 5:31 AM, Jon Ribbens wrote: > On 2017-06-02, Chris Angelico wrote: >> On Sat, Jun 3, 2017 at 2:45 AM, Jon Ribbens >> wrote: >>> Bewaare - MyISAM tables have no transactions for DML but they do have

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread R. David Murray
R. David Murray added the comment: Thank you for linking to that Xiang. I had a vague memory of that discussion but couldn't find it. No, there is no bug here, but there is a question of whether or not there *should* be a bug here (that is, is there a design bug) and if so how/where to fix

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Skip Montanaro
On Fri, Jun 2, 2017 at 2:40 PM, Neil Cerutti wrote: > You get autocommit with sqlite3 by setting isolation_level=None > on the connection object. > Thanks for the pointer. I'd probably never have noticed the correspondence. Skip --

[issue21878] wsgi.simple_server's wsgi.input read/readline waits forever in certain circumstances

2017-06-02 Thread Dom Cote
Dom Cote added the comment: Just bumped into this issue today using bobo. On the first attempt to load a page, it's OK, because there is something to read. But if you hit the "reload" button on the browser, for some reason, it will connect with the server a second time after the request is

CherryPy Session object creation logic

2017-06-02 Thread Israel Brewster
I have a CherryPy app, for which I am using a PostgreSQL session. To be more exact, I modified a MySQL session class I found to work with PostgreSQL instead, and then I put this line in my code: cherrypy.lib.sessions.PostgresqlSession = PostgreSQLSession And this works fine. One thing about

[issue30541] Add restricted mocks to the python unittest mocking framework

2017-06-02 Thread Mario Corchero
Changes by Mario Corchero : -- pull_requests: +2003 ___ Python tracker ___ ___

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Neil Cerutti
On 2017-06-02, Skip Montanaro wrote: > On Fri, Jun 2, 2017 at 11:14 AM, Dennis Lee Bieber > wrote: > I just checked, and the sqlite3 adapter I have access to > (Python 2.7.13 in a Conda env, module version 2.6.0, SQLite3 > 3.13.0) has no

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Jon Ribbens
On 2017-06-02, Chris Angelico wrote: > On Sat, Jun 3, 2017 at 2:45 AM, Jon Ribbens wrote: >> Bewaare - MyISAM tables have no transactions for DML but they do have >> transactions for DDL. Insane but true. > > Not insane; not all DBMSes have

Re: Very Slow Disk Writes when Writing Large Data Blocks

2017-06-02 Thread Irmen de Jong
On 2-6-2017 20:14, remmm wrote: > These write speeds are in the range of 18 to 25 MBytes per second for > spinning disks and about 50 Mbytes/sec for SSDs. Keep in mind these numbers > should be more like 120 MBytes/sec for spinning disks and 300 MBytes/sec for > SSDs. You'll only reach

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Skip Montanaro
On Fri, Jun 2, 2017 at 11:14 AM, Dennis Lee Bieber wrote: > My conclusion: > If using a DB-API compliant adapter, explicitly issuing "begin" and > "commit" via .execute() should be avoided if one expects to be portable > (change the adapter from one DBMS to

[issue24899] Add an os.path <=> pathlib equivalence table in pathlib docs

2017-06-02 Thread Brett Cannon
Changes by Brett Cannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue24899] Add an os.path <=> pathlib equivalence table in pathlib docs

2017-06-02 Thread Brett Cannon
Brett Cannon added the comment: New changeset ae8750bca8234a9af9382b9d7e457b57f810ad64 by Brett Cannon (Jamiel Almeida) in branch 'master': bpo-24899: Add comparison table for os.path -> pathlib (GH-1753) https://github.com/python/cpython/commit/ae8750bca8234a9af9382b9d7e457b57f810ad64

[issue30534] error message for incorrect call degraded in 3.7

2017-06-02 Thread Brett Cannon
Brett Cannon added the comment: > Note that some error messages are "takes no keyword arguments", but others > are "does not take keyword arguments" or "doesn't take keyword arguments". > They should be unified. What wording is better? I vote for "takes no keyword arguments". --

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Brett Cannon
Brett Cannon added the comment: Yeah, there's actually a specific 'warning' directive which puts text in the docs in a red box to make it a full-blown warning which is what I thought you wanted, having it say "this is different than Python 2!". Having a sentence that just states how things

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread Xiang Zhang
Xiang Zhang added the comment: Looking at the code and doc it seems it's by design. But it's good or not remains in question. The related discussion about the more general problem behind this issue is https://groups.google.com/d/msg/python-ideas/Kou5cYGjGQ8/oXEixwgiDwAJ. There is a

Very Slow Disk Writes when Writing Large Data Blocks

2017-06-02 Thread remmm
I'm seeing slow write speeds from both Python and C code on some Windows workstations. In particular both Python "write" and numpy "tofile" method suffers from this issue. I'm wondering if anyone has any ideas regarding if this is a known issue, know the cause, or how to resolve the issue?

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-02 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- pull_requests: +2002 ___ Python tracker ___ ___

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Chris Angelico
On Sat, Jun 3, 2017 at 2:45 AM, Jon Ribbens wrote: > On 2017-06-02, Dennis Lee Bieber wrote: >> Connector/Python (MySQL) [guess it is time for me to finally upgrade to >> Python 3.x -- it was the delay in getting mysqldb ported that held me

[issue30555] _io._WindowsConsoleIO breaks in the face of fd redirection

2017-06-02 Thread Steve Dower
Steve Dower added the comment: > We can also switch to calling _get_osfhandle always instead of caching the > handle, it will break when the fd is redirected to a non-console. But so does > _WindowsConsoleIO in general since it will try to continue writing to the > console despite the

[issue30518] Import type aliases from another module

2017-06-02 Thread Ivan Levkivskyi
Ivan Levkivskyi added the comment: > Block = [int, Tuple[int]] > Blocks = List[Block] These are both invalid type aliases (I have no idea why PyCharm does not flag them, you could report this at PyCharm issue tracker). I am not sure what exactly you want. If you want a list of either

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Neil Cerutti
On 2017-06-02, Dennis Lee Bieber wrote: > > A bit of a long free-association rambling... > > On Fri, 2 Jun 2017 12:07:45 + (UTC), Neil Cerutti > declaimed the following: >>You're probably not expected to interleave transaction control

[issue30556] asyncio.wait very slow with FIRST_COMPLETED

2017-06-02 Thread Samuel Colvin
New submission from Samuel Colvin: This is best described the script at https://gist.github.com/samuelcolvin/00f01793c118bf9aafae886ffbc81a58. Basically, completing a set of tasks using asyncio.wait(...return_when=asyncio.FIRST_COMPLETED) in a loop to wait for them to finish is much much

Re: Bug or intended behavior?

2017-06-02 Thread bob gailer
On 6/2/2017 1:28 PM, Jussi Piitulainen wrote: sean.diza...@gmail.com writes: Can someone please explain this to me? Thanks in advance! ~Sean Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 12:39:47) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin Type "help", "copyright", "credits"

[issue30505] Performance of typing._ProtocolMeta._get_protocol_attrs and isinstance

2017-06-02 Thread Ivan Levkivskyi
Ivan Levkivskyi added the comment: Thanks for reporting! The runtime implementation of protocol classes will be thoroughly reworked as a part of PEP 544, see also https://github.com/python/typing/pull/417 for a proof of concept runtime implementation. Also, there is another ongoing

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread R. David Murray
R. David Murray added the comment: That's actually a very good question. hasattr returns False, but is it supposed to be an invariant that if dir returns a string hasattr should return True and getattr should not return AttributeError? (Well, it might raise AttributeError from inside the

Re: Bug or intended behavior?

2017-06-02 Thread Irmen de Jong
On 2-6-2017 19:17, sean.diza...@gmail.com wrote: > Can someone please explain this to me? Thanks in advance! > > ~Sean > > > Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 12:39:47) > [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin > Type "help", "copyright", "credits" or "license"

Re: Bug or intended behavior?

2017-06-02 Thread justin walters
On Fri, Jun 2, 2017 at 10:17 AM, wrote: > Can someone please explain this to me? Thanks in advance! > > ~Sean > > > Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 12:39:47) > [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin > Type "help", "copyright", "credits"

Re: Bug or intended behavior?

2017-06-02 Thread Jussi Piitulainen
sean.diza...@gmail.com writes: > Can someone please explain this to me? Thanks in advance! > > ~Sean > > > Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 12:39:47) > [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin > Type "help", "copyright", "credits" or "license" for more information.

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread Igor Kozyrenko (ikseek)
Igor Kozyrenko (ikseek) added the comment: So is it by design? cgitb library fails to create report if there are links to exceptions based on OSError on the stack because it tries to enumerate all it's attributes. -- ___ Python tracker

Bug or intended behavior?

2017-06-02 Thread sean . dizazzo
Can someone please explain this to me? Thanks in advance! ~Sean Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 12:39:47) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> print "foo %s" % 1-2 Traceback (most

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Segev Finer
Changes by Segev Finer : -- type: -> behavior ___ Python tracker ___ ___

[issue30555] _io._WindowsConsoleIO breaks in the face of fd redirection

2017-06-02 Thread Segev Finer
Changes by Segev Finer : -- nosy: +eryksun ___ Python tracker ___ ___ Python-bugs-list

Re: Manager for project templates, that allows "incremental" feature addition

2017-06-02 Thread Lele Gaifax
Lele Gaifax writes: > Paul Moore writes: > >> On Thursday, 23 March 2017 15:56:43 UTC, Paul Moore wrote: >> >> Sadly, it doesn't support Windows, which is what I use. > > FYI, I just saw https://pypi.python.org/pypi/what/0.4.0, that seems an >

[issue30555] _io._WindowsConsoleIO breaks in the face of fd redirection

2017-06-02 Thread Segev Finer
New submission from Segev Finer: _WindowsConsoleIO works by taking the handle out of the file descriptors of the stdio handles (get_osfhandle) and reading/writing to it directly using ReadConsoleW/WriteConsoleW. The problem is that some Python code wants to do file descriptor level

[issue30414] multiprocesing.Queue silently ignore messages after exc in _feeder

2017-06-02 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thomas, thanks for the heads up. I would suggest something like the following patch to multiprocessing.Pool: $ git diff diff --git a/Lib/multiprocessing/queues.py b/Lib/multiprocessing/queues.py index 7f77837..ebbb360 100644 ---

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Jon Ribbens
On 2017-06-02, Dennis Lee Bieber wrote: > Connector/Python (MySQL) [guess it is time for me to finally upgrade to > Python 3.x -- it was the delay in getting mysqldb ported that held me back] > does allow for turning on autocommit -- which is documented as issuing an

[issue29514] Add a test case that prevents magic number changes in minor releases

2017-06-02 Thread Eric Snow
Eric Snow added the comment: Sorry I didn't see the just-landed PR earlier, but it may make sense to not skip that test under *any* release level for a micro version > 0: @unittest.skipUnless( (sys.version_info.micro > 0 or sys.version_info.releaselevel in ('final',

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread Xiang Zhang
Xiang Zhang added the comment: Actually the docs says "This attribute is available when using the buffered I/O classes from the io module", which means it's not always available since it depends on an inner field set or not. It's just like Python code: >>> class CW: ... def __get__(self,

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-02 Thread Ethan Furman
Ethan Furman added the comment: If your example code is the same as the code in the SO problem, then my previous points stand. According to the plain-English description you provided the comparison would succeed, so if you have example code which: - doesn't involve ModuleA being the __main__

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-02 Thread R. David Murray
R. David Murray added the comment: Can you provide actual code that demonstrates the issue you are talking about? -- nosy: +r.david.murray versions: -Python 2.7 ___ Python tracker

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread R. David Murray
R. David Murray added the comment: In other words, this was a major standards screwup and we get to deal with the consequences :( All right, since I'm hardly likely to have time to deal with it anyway, we'll just say that email isn't going to handle unicode domain names until *someone*

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Steve Dower
Steve Dower added the comment: Yeah, make it a separate issue. This PR fixes an obvious error that we should just fix, so I've merged it. (I might get to the backport today, but if someone else submits it then I'll merge.) -- ___ Python tracker

[issue30544] _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails

2017-06-02 Thread Steve Dower
Steve Dower added the comment: New changeset 523776c3419f6795e78173d53c10e35ec4eed48d by Steve Dower (Segev Finer) in branch 'master': bpo-30544: _io._WindowsConsoleIO.write raises the wrong error when WriteConsoleW fails (#1912)

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-02 Thread Madhav Datt
Madhav Datt added the comment: Thanks a lot for those points Ethan. I feel I haven't done a very good job of explaining the bug, but let me use an example. Let's say we have an Enum called MyEnum, which is in a Python module called ModuleA. ModuleB imports ModuleA, and ModuleC imports both,

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread Paul Kehrer
Changes by Paul Kehrer : -- nosy: -reaperhulk ___ Python tracker ___ ___

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread Paul Kehrer
Paul Kehrer added the comment: As someone who built an idna aware API for pyca/cryptography and deeply regrets it I'd like to weigh in on the side of saying that IDNA is a presentation issue and that supporting it in lower level APIs is the cause of many bugs, some of which can potentially be

[issue30554] Inaccessible attribute characters_written on OSError instances

2017-06-02 Thread Igor Kozyrenko (ikseek)
New submission from Igor Kozyrenko (ikseek): If I enumerate attributes on OSError instance with dir dir(OSError()) I see an 'characters_written' attribute (which is supposed to be defined on BlockingIOError according to docs). If I try to access it getattr(OSError(), 'characters_written') I get

[issue30533] missing feature in inspect module: getmembers_static

2017-06-02 Thread Lisa Roach
Lisa Roach added the comment: +1 to a new getmembers_static(), I don't see why this couldn't be implemented. -- nosy: +lisroach ___ Python tracker ___

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread Christian Heimes
Christian Heimes added the comment: Adding automatic IDNA decoding is like opening Pandora's box. uts46 is not necessarily the correct solution. The correct handling of internationalized domain names depends on multiple factors: TLD, remote application and more. You actually have to know if

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread R. David Murray
R. David Murray added the comment: The email package currently forces explicit IDNA use currently. The new policies are supposed to support it automatically but I they currently don't. I'm not sure we should add it to the old interface (parseaddr/formataddr) any longer, but I don't object

[issue30458] CRLF Injection in httplib

2017-06-02 Thread Xiang Zhang
Xiang Zhang added the comment: Looking at the code and the previous issue #22928, CRLF immediately followed by a tab or space (obs-fold: CRLF 1*( SP / HTAB )) is a valid part of a header value so the regex deliberately ignore them. So it looks right to me the url given doesn't raise the same

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-02 Thread Ethan Furman
Ethan Furman added the comment: Two points: - Python 2.7 was the version marked, but 2.7 does not come with Enum (wasn't introduced until 3.4 -- the third-party backport does work on 2.7) - the problem in the SO question is not caused by Enum, but by re-importing a module under a

[issue30536] [EASY] SubinterpThreadingTests.test_threads_join_2() of test_threading leaks references

2017-06-02 Thread Sayan Chowdhury
Sayan Chowdhury added the comment: I replicated the issue. Starting to work on the issue. -- nosy: +sayanchowdhury ___ Python tracker ___

[issue11783] email parseaddr and formataddr should be IDNA aware

2017-06-02 Thread Christian Heimes
Christian Heimes added the comment: We can't replace IDNA-2003 with IDNA-2008 either. Some applications / protocols / TLDs still use IDNA-2003. I see two options, (1) make encoding configurable somehow, (2) drop implicit IDNA encoding/decoding and force applications to perform explicit IDNA.

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Eric Snow
Changes by Eric Snow : -- keywords: +easy ___ Python tracker ___ ___

[issue30414] multiprocesing.Queue silently ignore messages after exc in _feeder

2017-06-02 Thread Thomas Moreau
Changes by Thomas Moreau : -- pull_requests: +2001 ___ Python tracker ___ ___

[issue30414] multiprocesing.Queue silently ignore messages after exc in _feeder

2017-06-02 Thread Thomas Moreau
Thomas Moreau added the comment: This fix, while preventing the Queue to crash, does not give any way to programatically detect that the message was dropped. This is a problem as we can no longer assume that the Queue will not drop messages. For instance, we can no longer detect deadlocks in

[issue30538] Functional Programming HOWTO describes one argument itertools.count()

2017-06-02 Thread Raymond Hettinger
Raymond Hettinger added the comment: > enumerate was described with one argument, but it takes two. > Should I update that as well? Yes please. -- ___ Python tracker

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-02 Thread Nick Coghlan
Nick Coghlan added the comment: Not your fault, Cheryl! I unfortunately got distracted and didn't follow up on the backports for several PRs I merged a while back. Mariatta has been graciously cleaning some of those up rather than leaving them lingering the way I had been :) I also just

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-02 Thread Nick Coghlan
Changes by Nick Coghlan : -- pull_requests: +1999 ___ Python tracker ___ ___

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-02 Thread Nick Coghlan
Nick Coghlan added the comment: New changeset 7a82f9c2b94d31c8f4cc8bb8e3151765d8b148d7 by Nick Coghlan in branch 'master': bpo-30052: Always regenerate cross-references (#1339) https://github.com/python/cpython/commit/7a82f9c2b94d31c8f4cc8bb8e3151765d8b148d7 --

[issue15216] Support setting the encoding on a text stream after creation

2017-06-02 Thread Nick Coghlan
Nick Coghlan added the comment: Antoine posted a simpler reconfiguration RFE over in https://bugs.python.org/issue30526 (for setting line buffering). While technically orthogonal to this RFE, we're thinking it might be possible to expose them to users as a common "reconfigure()" API, rather

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-02 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks. I'll produce an updated PR using reconfigure() for line_buffering and write_through. -- ___ Python tracker ___

[issue30526] Allow setting line_buffering on existing TextIOWrapper

2017-06-02 Thread Nick Coghlan
Nick Coghlan added the comment: Right, the request/requirement for in-place configuration changes arise from the fact the underlying buffer objects can't readily be shared, while makes swapping out the wrapper problematic if others may already have references to the original. The "Don't do

[issue30052] URL Quoting page links to function Bytes instead of defintion

2017-06-02 Thread Cheryl Sabella
Cheryl Sabella added the comment: Sorry, Mariatta. I didn't realize this was waiting for a backport. -- ___ Python tracker ___

[issue27318] Add support for symlinks to zipfile

2017-06-02 Thread Mathieu Bridon
Mathieu Bridon added the comment: Do note that extracting a zipfile with symlinks might lead to unexpected results, for example if the path pointed to is outside of the extract dir. Maybe the behaviour introduced in this patch should not be the default, but instead `extract` and `extractall`

[issue30553] Add HTTP Response code 421

2017-06-02 Thread Julien
New submission from Julien: The `http.HTTPStatus` class provides constants for most of the HTTP status codes. Status code 421 was added by the RFC 7540 (HTTP/2), and is not part of this class. It is described as follows: > The 421 (Misdirected Request) status code indicates that the request >

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Xavier Morel
Xavier Morel added the comment: > Fair enough. So we can just add a sentence informing readers that `meta_path`, by default, holds entries to handle the standard kinds of modules (.py files, extension modules…). Yeah that's basically what I meant, talking about a "warning" in python 3 may have

[issue30538] Functional Programming HOWTO describes one argument itertools.count()

2017-06-02 Thread Cheryl Sabella
Cheryl Sabella added the comment: Submitted a PR, thank you. I changed added the argument for count(). Also I noticed that the link to accumulate() was broken, so I fixed that and I added a link to functools in the references at the end of the page. One other thing I noticed was that

[issue30538] Functional Programming HOWTO describes one argument itertools.count()

2017-06-02 Thread Cheryl Sabella
Changes by Cheryl Sabella : -- pull_requests: +1998 ___ Python tracker ___ ___

Re: Python DB API - commit() v. execute("commit transaction")?

2017-06-02 Thread Neil Cerutti
On 2017-06-02, Frank Millman wrote: > As I said, I cannot prove this, but the theory fits the > observed behaviour perfectly, so I have proceeded on the > assumption that it is true. Therefore I now always run every > SQL command or block of commands within a context manager,

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Antoine Pitrou
Antoine Pitrou added the comment: Le 02/06/2017 à 13:21, Xavier Morel a écrit : > > I spent a few hours trying to understand why our import hooks did not work > correctly anymore in 3.5, and I never even considered printing sys.meta_path > in an open interpreter, I realised the behavioural

[issue30537] Using PyNumber_AsSsize_t in itertools.islice

2017-06-02 Thread Roundup Robot
Changes by Roundup Robot : -- pull_requests: +1997 ___ Python tracker ___

[issue30552] Bugs

2017-06-02 Thread Mahira
Changes by Mahira : -- stage: -> resolved status: open -> closed ___ Python tracker ___

[issue30551] Attribute Error

2017-06-02 Thread Mahira
Mahira added the comment: hey issue Cleared -- stage: -> resolved status: open -> closed ___ Python tracker ___

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Xavier Morel
Xavier Morel added the comment: > A warning is probably too strong. Also, it's easy to check sys.meta_path at > the interpreter prompt, so I'm not sure it's worth mentioning at all. It's easy if you think of it and did not miss a small bit of the Python 3.3 release note indicating that the

[issue30535] Warn that meta_path is not empty

2017-06-02 Thread Xavier Morel
Xavier Morel added the comment: > I'm fine with adding a note to the Python 2 docs, but putting it in Python 3 > seems to be going in the wrong direction as having sys.meta_path not be empty > is how Python will be going forward. I don't think putting a note is any hint that the Python 3

[issue30547] [EASY][Windows] SubinterpreterTest.test_callbacks_leak() of test_atexit leaks references

2017-06-02 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: this issue can be executed on Linux, I think I am going to work on this one. -- nosy: +matrixise ___ Python tracker

  1   2   >