[issue25597] unittest.mock does not wrap dict objects correctly

2015-12-22 Thread Joseph Gordon
Changes by Joseph Gordon : -- nosy: +josephgordon ___ Python tracker ___ ___

Re: Ignore error with non-zero exit status

2015-12-22 Thread Thomas 'PointedEars' Lahn
Terry Reedy wrote: > On 12/21/2015 9:05 AM, Thomas 'PointedEars' Lahn wrote: >> Chris Angelico wrote: >>> On Tue, Dec 22, 2015 at 12:19 AM, Thomas 'PointedEars' Lahn >>> wrote: Mark Lawrence wrote: > On 21/12/2015 07:51, Thomas 'PointedEars' Lahn wrote: >> Chris

Re: Newbie XML problem

2015-12-22 Thread jmp
On 12/22/2015 05:29 AM, KP wrote: From my first foray into XML with Python: I would like to retrieve this list from the XML upon searching for the 'config' with id attribute = 'B' config = {id: 1, canvas: (3840, 1024), comment: "a comment", {id: 4, gate: 3, (0,0, 1280,

[issue25924] investigate if getaddrinfo(3) on OSX is thread-safe

2015-12-22 Thread Ronald Oussoren
New submission from Ronald Oussoren: https://emptysqua.re/blog/getaddrinfo-deadlock/ claims that getaddrinfo may deadlock when using threads and fork on (amongst others) OSX due to using a global lock. That lock is used when getaddrinfo is believed to be not thread safe, see the relevant

Re: In Python 3, how to append a nested dictionary to a shelve file with the added difficulty of using a for loop?

2015-12-22 Thread Peter Otten
Aaron Christensen wrote: > Thanks for the response! Several things you stated definitely got me > thinking. I really appreciate the response. I used what you said and I > am able to accomplish what I needed. Perhaps it becomes clearer when you write two helper functions def read_record(key):

[issue25923] More const char

2015-12-22 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: Proposed patch adds the const qualifier to char* parameter declarations and static char arrays if appropriate. This makes the code more strict and can help to catch bugs or generate more efficient code. In additional it can decrease memory consumption by

Re: Meaning and purpose of the Subject field

2015-12-22 Thread Thomas 'PointedEars' Lahn
Random832 wrote: > This makes sense for the change from "old" to "new (was: old)", > which nobody was advocating against (after all, there's semantic > content - they wouldn't have changed the subject line if they > didn't consider it a new discussion topic), but I think there is > a reasonable

Re: match point

2015-12-22 Thread Thomas 'PointedEars' Lahn
Thierry wrote: > Reading the docs about regular expressions, I am under the impression > that calling > re.match(pattern, string) > is exactly the same as > re.search(r'\A'+pattern, string) Correct. > Same for fullmatch, that amounts to > re.search(r'\A'+pattern+r'\Z', string) Correct. >

Re: (Execution) Termination bit, Alternation bit.

2015-12-22 Thread Skybuck Flying
"Richard Damon" wrote in message news:QXSdy.6634$qg6.5...@fx31.iad... On 12/21/15 7:40 AM, Skybuck Flying wrote: The original idea I posted is less about sending a signal to another processor. It is more about how to break out of an instruction sequence. Example of problem: [snip] Bye,

[issue25848] Tkinter tests failed on Windows buildbots

2015-12-22 Thread R. David Murray
R. David Murray added the comment: Well, it clutters up the buildbot web interface with builders that aren't being used. Our historical pattern has been to deactivate the builders after a release goes into security-fix-only mode. Zach, would it be practical to just comment them out and then

Re: (Execution) Termination bit, Alternation bit.

2015-12-22 Thread Chris Angelico
On Wed, Dec 23, 2015 at 2:46 AM, Skybuck Flying wrote: > One idea which immediatly comes to mind to fix this problem is to offer a > "PushTerminationFlag" onto stack and then a "ClearTerminationFlag" > instruction. > > Then a code section can be executed without breaking

0x80070570-The file or directory is corrupted and unreadable

2015-12-22 Thread muizz hasan
Hi there! I've been recently trying to install Python for Windows 10 and I've been encountering some issues. Every time i try to install the program it just says"0x80070570-The file or directory is corrupted and unreadable". I have attached my log file and i hope that you guys might enlighten me

Re: What could cause a plot fail in my code?

2015-12-22 Thread Denis McMahon
On Mon, 21 Dec 2015 09:15:38 -0800, Robert wrote: > Hi, > > I find a useful code snippet on link: > > http://stackoverflow.com/questions/25126444/logistic-regression-in- pymc/34400966#34400966 > > but it has error on plot function. The error message is as following: >6192

Re: return from function

2015-12-22 Thread Denis McMahon
On Sun, 20 Dec 2015 12:34:40 +, Emil Natan wrote: > I'm completely new to Python. > parent_domain = domainname.partition('.')[2] > try: > print('Test for parent domain %s' % parent_domain) > z = dns.resolver.query(parent_domain, 'SOA') > print('the parent

[issue25925] Coverage support for CPython 2

2015-12-22 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker ___ ___ Python-bugs-list

[issue25925] Coverage support for CPython 2

2015-12-22 Thread Alecsandru Patrascu
New submission from Alecsandru Patrascu: Hi All, This is Alecsandru from Server Scripting Languages Optimization team at Intel Corporation. I would like to submit a patch that adds extended support for coverage, in the same way that it is used in CPython3. Used in conjunction with the

[issue25926] problems with "times" keyword in itertools.repeat

2015-12-22 Thread Thomas Feldmann
New submission from Thomas Feldmann: According to the docs `itertools.repeat(object[, times])` is equivalent to ``` def repeat(object, times=None): # repeat(10, 3) --> 10 10 10 if times is None: while True: yield object else: for i in range(times):

[issue25926] problems with "times" keyword in itertools.repeat

2015-12-22 Thread R. David Murray
R. David Murray added the comment: Huh. I always thought the wording was "roughly equivalent to". This is a consequence of C vs python, and is the reason the docstring uses the [] notation. -- nosy: +r.david.murray, rhettinger ___ Python tracker

Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status)

2015-12-22 Thread Tim Chase
On 2015-12-21 23:24, Jon Ribbens wrote: > That sounds a bit confused - if the *intention* of changing the > subject line is to create a new thread, then breaking the thread > is not "breaking threading" ;-) I'm pretty sure that the purpose is not to *break* the thread, but to suggest that the

Re: match point

2015-12-22 Thread Thierry Closen
I found the story behind the creation of re.fullmatch(). I had no luck before because I was searching under "www.python.org/dev", while in reality it sprang out of a bug report: https://bugs.python.org/issue16203 In summary, there were repeated bugs where during maintenance of code the $

[issue25848] Tkinter tests failed on Windows buildbots

2015-12-22 Thread Zachary Ware
Zachary Ware added the comment: Would pretty much eliminate the benefit; there are currently a few special cases for 3.4 (particularly for the ICC builders, and the XP bot), which could go away. For the record, the secret undocumented method for running a build on all custom builders is to

[issue25848] Tkinter tests failed on Windows buildbots

2015-12-22 Thread R. David Murray
R. David Murray added the comment: How about just keeping the stable set configs, minus any from that set that have special cases? Although if it is just one form submission, maybe we just need to document that in the release manager's guide? --

Why doesn't os.remove work on directories?

2015-12-22 Thread Random832
This is surprising to anyone accustomed to the POSIX C remove function, which can remove either files or directories. Is there any known rationale for this decision? -- https://mail.python.org/mailman/listinfo/python-list

Re: Why doesn't os.remove work on directories?

2015-12-22 Thread Ben Finney
Random832 writes: > This is surprising to anyone accustomed to the POSIX C remove > function, which can remove either files or directories. Is there > any known rationale for this decision? No, I don't know a rationale for implementing it this way. I expect the

[issue25848] Tkinter tests failed on Windows buildbots

2015-12-22 Thread Zachary Ware
Zachary Ware added the comment: I think only keeping some builders would be more complex than any other option. Here's a patch against pep101 to document the custom builder trick. -- keywords: +patch Added file: http://bugs.python.org/file41389/pep101_custom_buildbots.diff

[issue25927] add dir_fd for mkstemp, and also maybe to all tempfile.*

2015-12-22 Thread Марк Коренберг
Changes by Марк Коренберг : -- components: +Library (Lib) ___ Python tracker ___ ___

[issue25927] add dir_fd for mkstemp, and also maybe to all tempfile.*

2015-12-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you want to provide a patch Mark? -- nosy: +georg.brandl, ncoghlan, serhiy.storchaka stage: -> needs patch type: -> enhancement versions: -Python 3.3, Python 3.4, Python 3.5 ___ Python tracker

[issue25599] asyncio.iscoroutinefunction returns unexpected results when presented with unittest.mock.Mock

2015-12-22 Thread Guido van Rossum
Guido van Rossum added the comment: Oh dang. We were waiting for the OP to submit a patch (not very complex) but they never did. Now we missed the 3.5.2 deadline. Maybe someone can try again for 3.5.3? On Tue, Dec 22, 2015 at 12:30 AM, Joseph Gordon wrote: > > Changes

Newbie: String to Tuple

2015-12-22 Thread KP
How do I convert '1280,1024' to (1280,1024) ? Thanks for all help! -- https://mail.python.org/mailman/listinfo/python-list

Re: Newbie: String to Tuple

2015-12-22 Thread Peter Otten
KP wrote: > How do I convert > > '1280,1024' > > to > > (1280,1024) ? >>> import ast >>> ast.literal_eval('1280,1024') (1280, 1024) -- https://mail.python.org/mailman/listinfo/python-list

Re: does the order in which the modules are placed in a file matters ?

2015-12-22 Thread Ganesh Pal
Thanks to Don , Chris and Carl for sharing your view on this topic . -- https://mail.python.org/mailman/listinfo/python-list

<    1   2