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

2015-12-22 Thread Grant Edwards
On 2015-12-21, Steven D'Aprano  wrote:

> So as far as I am concerned, if changes of subject line breaks threading for
> you, so sad, too bad. Go without threading or use a better mail client.

Same here.  After getting what is effectively a 

Re: Library function to encode data to multipart/form-data format?

2015-12-22 Thread Grant Edwards
On 2015-12-21, Laura Creighton  wrote:
> In a message of Mon, 21 Dec 2015 17:51:00 +, Grant Edwards writes:
>>Is there a standard library function that can be used to encode data
>>into multipart/form-data format?  IIRC, I looked for this once before
>>and didn't find anything in the library. 
[...]

> Cannibalise this:
> http://code.activestate.com/recipes/146306/
> which just uses standard library things.

Yep, that's what I ended up doing.  I noticed that the code referenced
above doesn't check to make sure the boundary string is not contained
in the data, so I fixed that.

-- 
Grant Edwards   grant.b.edwardsYow! I'm gliding over a
  at   NUCLEAR WASTE DUMP near
  gmail.comATLANTA, Georgia!!
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: unicodedata with chr() not the same between python 3.4 and 3.5

2015-12-22 Thread Chris Angelico
On Wed, Dec 23, 2015 at 2:27 AM, Vincent Davis  wrote:
> I was expecting the code below to be the same between python3.4 and 3.5. I
> need a mapping between the integers and unicode that is consistant between
> 3.4 and 3.5
>

> import unicodedata

> u = ''.join(chr(i) for i in range(65536) if (unicodedata.category(chr(i))
> in ('Lu', 'Ll')))[945:965]

Not sure why you're slicing it like this, but it makes little
difference. The significant thing here is that the newer Pythons are
shipping newer Unicode data files, and some code points have changed
category.

rosuav@sikorsky:~$ python3.4
Python 3.4.2 (default, Oct  8 2014, 10:45:20)
[GCC 4.9.1] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import unicodedata
>>> unicodedata.unidata_version
'6.3.0'
>>>
rosuav@sikorsky:~$ python3.5
Python 3.5.0b1+ (default:7255af1a1c50+, May 26 2015, 00:39:06)
[GCC 4.9.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import unicodedata
>>> unicodedata.unidata_version
'7.0.0'
>>>
rosuav@sikorsky:~$ python3.6
Python 3.6.0a0 (default:6e114c4023f5, Dec 20 2015, 19:15:28)
[GCC 4.9.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import unicodedata
>>> unicodedata.unidata_version
'8.0.0'
>>>

Have a read here of what changed in those two major versions:

http://unicode.org/versions/Unicode7.0.0/
http://unicode.org/versions/Unicode8.0.0/

I'm not sure what the best way is to create the mapping you want, but
I would advise freezing it to a specific set of codepoints in your
source code, rather than depending on something external.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue25925] Coverage support for CPython 2

2015-12-22 Thread Zachary Ware

Zachary Ware added the comment:

Left a couple of review comments on Rietveld.

--
nosy: +zach.ware
stage:  -> patch review

___
Python tracker 

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



[issue25925] Coverage support for CPython 2

2015-12-22 Thread Alecsandru Patrascu

Alecsandru Patrascu added the comment:

Thank you for the reviews. I've added a new patch (v02) to correct the issues.

--
Added file: http://bugs.python.org/file41386/coverage-2.7-v02.patch

___
Python tracker 

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



unicodedata with chr() not the same between python 3.4 and 3.5

2015-12-22 Thread Vincent Davis
​I was expecting the code below to be the same between python3.4 and 3.5. I
need a mapping between the integers and unicode that is consistant between
3.4 and 3.5

>>>
import unicodedata
>>>
u = ''.join(chr(i) for i in range(65536) if (unicodedata.category(chr(i))
in ('Lu', 'Ll')))[945:965]
>>> u
'ԡԢԣԤԥԦԧԨԩԪԫԬԭԮԯԱԲԳԴԵ'

Python 3.4
>>>
import unicodedata
>>>
u = ''.join(chr(i) for i in range(65536) if (unicodedata.category(chr(i))
in ('Lu', 'Ll')))[945:965]
>>> u
'ԢԣԤԥԦԧԱԲԳԴԵԶԷԸԹԺԻԼԽԾ'

As you can see they are not the same
​.​


'ԡԢԣԤԥԦԧԨԩԪԫԬԭԮԯԱԲԳԴԵ'
'ԢԣԤԥԦԧԱԲԳԴԵԶԷԸԹԺԻԼԽԾ'




Vincent Davis
720-301-3003
-- 
https://mail.python.org/mailman/listinfo/python-list


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

2015-12-22 Thread Ian Kelly
On Tue, Dec 22, 2015 at 8:17 AM, Grant Edwards  wrote:
> On 2015-12-21, Steven D'Aprano  wrote:
>
>> So as far as I am concerned, if changes of subject line breaks threading for
>> you, so sad, too bad. Go without threading or use a better mail client.
>
> Same here.  After getting what is effectively a 

[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Nathaniel Smith

Nathaniel Smith added the comment:

> We are working on the Fortran issue in a few different ways, one of which is 
> your work on MinGW compatibility so that gfortran can be used. But that isn't 
> the only solution to this whole problem, and it's not even preferable for a 
> lot of Python users, so expect other proposals to come out.

Hey Steve, I'm a bit surprised to be hearing this now given all our off-list 
discussions about these issues this year. Can you clarify what you're talking 
about here? Who is "we", what other solutions do you see, and why would they be 
preferable? (If the compatibility issues are solved, then AFAIK gfortran is 
basically perfect for 99% of uses; the only alternatives are proprietary 
compilers with much nastier -- F/OSS-incompatible -- license terms. Note that 
by contrast gfortran itself is GPLed, but with a specific exemption added to 
clarify that it is totally okay to use for compiling proprietary code.)

--

___
Python tracker 

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



Re: imshow keeps crashhing

2015-12-22 Thread John Gordon
In  norou...@gmail.com 
writes:

> Can anyone please help me with "imshow"? I have tried "imshow" on different 
> computers and different Python consoles but it does not work. Here are the 
> code and the error message:

> import scipy.misc as mi
> img = mi.imread('C:\images\circles.png')
> mi.imshow(img)

> 'see' is not recognized as an internal or external command,
> operable program or batch file.

scipy calls an external image viewer program to display the image.

The name of this program is stored in the environment variable
SCIPY_PIL_IMAGE_VIEWER.  If that variable is not present, it uses
'see' by default.

Do you have a suitable image viewing program installed on your computer?
If so, try setting the SCIPY_PIL_IMAGE_VIEWER environment variable to the
name of that program.

-- 
John Gordon   A is for Amy, who fell down the stairs
gor...@panix.com  B is for Basil, assaulted by bears
-- Edward Gorey, "The Gashlycrumb Tinies"

-- 
https://mail.python.org/mailman/listinfo/python-list


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

No I just misremembered.

--Guido (mobile)

--

___
Python tracker 

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



Re: 0x80070570-The file or directory is corrupted and unreadable

2015-12-22 Thread eryk sun
On Tue, Dec 22, 2015 at 11:51 AM, Dennis Lee Bieber
 wrote:
>
> http://www.tech-faq.com/how-to-fix-error-0x80070570.html
> suggests a registry cleaner (my preference over downloading some
> unknown/unvetted "repair" tool)
>
> Most of the links on Google are for getting the error when installing
> Win7 itself.

The log says "Error 0x80070570: Failed to extract all files from
container, erf: 1:4:0". 0x80070570 is a failure code for the Windows
API (facility code 7) with the error value ERROR_FILE_CORRUPT
(0x0570). The simplest recourse at this point is to clear the browser
cache and download the installer again.

Here's a program from Microsoft to check MD5 sums. You can copy
fciv.exe to the Windows directory.

https://www.microsoft.com/en-us/download/details.aspx?id=11533

Then verify that the MD5 sum is 4d6fdb5c3630cf60d457c9825f69b4d7, as
posted on python.org:

>fciv python-3.5.1.exe
//
// File Checksum Integrity Verifier version 2.05.
//
4d6fdb5c3630cf60d457c9825f69b4d7 python-3.5.1.exe

Of course, the file could be fine and this error could be just a
symptom of another problem.
-- 
https://mail.python.org/mailman/listinfo/python-list


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

2015-12-22 Thread Yury Selivanov

Yury Selivanov added the comment:

> Now we missed the 3.5.2 deadline.

Did you mean 3.5.1?  Or Larry is going to rush 3.5.2 soon?

--

___
Python tracker 

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



[issue8604] Adding an atomic FS write API

2015-12-22 Thread Марк Коренберг

Марк Коренберг added the comment:

instead of realpath, os.lstat() may be used in order to detect if target file 
object is not plain file. Also, os.rename() cannot be used since it follows 
symlinks by default.

--

___
Python tracker 

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



How to use a variable to act as @rule in a Sopel IRC bot module?

2015-12-22 Thread arresteddevlopment

Hi everyone. I'm working with the Sopel (previously Willie and before that, 
Jenni/Phenny) python IRC bot as I'd like to set up a trivia quiz for our IRC 
channel.

With Sopel, the @rule decorator lets you set a string that the bot will 
listen out for and which triggers a corresponding function when encountered. 
So for the quiz I'd like the bot to confirm a correct answer by saying 
"Correctamundo!" when someone gets the question right.





A. The first thing I tried was a nested function. After choosing a random 
question from the q_and_as tuples list, it sets the answer (q[1]) as the rule 
that should trigger the correct() function.



from sopel.module import commands, ruleimport randomq_and_as = [('Why?', 
'because'), ('Can I kick it?', 'nope')]@commands("quizme")def ask_q(bot, 
trigger):q = random.choice(q_and_as)bot.say(q[0])@rule(q[1])
def correct(bot, trigger):bot.sat('Correctamundo!')


For whatever reason the answer isn't triggering the correct() function when 
done this way.




B. I also tried passing the answer (q[1]) to a separate answer function, 
which would then set it as the rule that triggered the correct() function.



from sopel.module import commands, ruleimport randomq_and_as = [('Why?', 
'because'), ('Can I kick it?', 'nope')]@commands("quizme")def ask_q(bot, 
trigger):q = random.choice(q_and_as)bot.say(q[0])answer(bot, 
trigger, q[1])def answer(bot, trigger, answer):@rule(answer)def 
correct(bot, trigger):bot.say(' correctamundo!')


Again though, the function isn't being triggered. Any ideas where I'm going 
wrong? Or is there a better way of doing this? Thank you.
 
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue19475] Add timespec optional flag to datetime isoformat() to choose the precision

2015-12-22 Thread Alessandro Cucci

Alessandro Cucci added the comment:

Thanks SilentGhost!

--
Added file: http://bugs.python.org/file41391/issue19475_v9.patch

___
Python tracker 

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



Re: Newbie: String to Tuple

2015-12-22 Thread KP
On Tuesday, 22 December 2015 12:59:59 UTC-8, Mark Lawrence  wrote:
> On 22/12/2015 20:53, KP wrote:
> > How do I convert
> >
> > '1280,1024'
> >
> > to
> >
> > (1280,1024) ?
> >
> > Thanks for all help!
> >
> 
> Start with this https://docs.python.org/3/library/stdtypes.html#str.split
> 
> -- 
> My fellow Pythonistas, ask not what our language can do for you, ask
> what you can do for our language.
> 
> Mark Lawrence

Thanks - just what I was missing!
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: Newbie XML problem

2015-12-22 Thread KP

Thank you both - your help is much appreciated!
-- 
https://mail.python.org/mailman/listinfo/python-list


imshow keeps crashhing

2015-12-22 Thread norouzey
Hello everyone,

Can anyone please help me with "imshow"? I have tried "imshow" on different 
computers and different Python consoles but it does not work. Here are the code 
and the error message:

import scipy.misc as mi
img = mi.imread('C:\images\circles.png')
mi.imshow(img)

'see' is not recognized as an internal or external command,
operable program or batch file.
Traceback (most recent call last):
  File "", line 1, in 
  File 
"C:\...\Anaconda2\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py",
 line 699, in runfile
execfile(filename, namespace)
  File 
"C:\...\Anaconda2\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py",
 line 74, in execfile
exec(compile(scripttext, filename, 'exec'), glob, loc)
  File "C:/.../.spyder2/temp.py", line 11, in 
mi.imshow(img)
  File "C:\...\Anaconda2\lib\site-packages\scipy\misc\pilutil.py", line 389, in 
imshow
raise RuntimeError('Could not execute image viewer.')
RuntimeError: Could not execute image viewer.

Thanks a lot for your time.

Ahmad
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue19475] Add timespec optional flag to datetime isoformat() to choose the precision

2015-12-22 Thread Alessandro Cucci

Alessandro Cucci added the comment:

Sorry @SilentGhost, I didn't seen your comment at the bottom of the review. 
With this patch is microsecond is 0, the time will display 6 zeroes.

--
Added file: http://bugs.python.org/file41388/issue19475_v8.patch

___
Python tracker 

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



[issue25919] htp.client PUT method ignores error responses sent immediatly after headers

2015-12-22 Thread Wiktor Niesiobedzki

Wiktor Niesiobedzki added the comment:

Maybe something like this? Doesn't look too complicated and I haven't noticed 
any breakage yet.

--
keywords: +patch
Added file: http://bugs.python.org/file41390/http.client.put.fix.patch

___
Python tracker 

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



Re: Newbie: String to Tuple

2015-12-22 Thread Mark Lawrence

On 22/12/2015 20:53, KP wrote:

How do I convert

'1280,1024'

to

(1280,1024) ?

Thanks for all help!



Start with this https://docs.python.org/3/library/stdtypes.html#str.split

--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

--
https://mail.python.org/mailman/listinfo/python-list


Re: How to use a variable to act as @rule in a Sopel IRC bot module?

2015-12-22 Thread arresteddevlopment
Apologies for the terrible formatting, let me try that again:

A:
from sopel.module import commands, rule
import random

q_and_as = [('Why?', 'because'), ('Can I kick it?', 'nope')]

@commands("quizme")
def ask_q(bot, trigger):
 q = random.choice(q_and_as)
 bot.say(q[0])
 @rule(q[1])
 def correct(bot, trigger):
 bot.sat('Correctamundo!')

B:
...
@commands("quizme")
def ask_q(bot, trigger):
 q = random.choice(q_and_as)
 bot.say(q[0])
 answer(bot, trigger, q[1])

def answer(bot, trigger, answer):
 @rule(answer)
 def correct(bot, trigger):
 bot.say(' correctamundo!')

If the above comes out wonky again I also asked on StackOverflow 
(http://stackoverflow.com/questions/34419265/how-to-set-and-later-change-a-rule-in-a-sopel-irc-bot-module-python).
 
Any help would be greatly appreciated.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue19475] Add timespec optional flag to datetime isoformat() to choose the precision

2015-12-22 Thread Alessandro Cucci

Changes by Alessandro Cucci :


Added file: http://bugs.python.org/file41387/issue19475_v7.patch

___
Python tracker 

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



[issue8604] Adding an atomic FS write API

2015-12-22 Thread Марк Коренберг

Марк Коренберг added the comment:

Also, modern kernels allows to replace entire directory!

renameat2() + RENAME_EXCHANGE

So, there should be more atomic operations

--

___
Python tracker 

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



[issue21579] Python 3.4: tempfile.close attribute does not work

2015-12-22 Thread Марк Коренберг

Марк Коренберг added the comment:

David Murray, in your code, if temporary file cannot be created, it attempts to 
unlink unknown name :).

But, I already have almost the same solution in production. I mention it 
sources in issue8604.

--

___
Python tracker 

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



[issue11588] Add "necessarily inclusive" groups to argparse

2015-12-22 Thread Chris Mayo

Changes by Chris Mayo :


--
nosy: +cjmayo

___
Python tracker 

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



[issue19475] Add timespec optional flag to datetime isoformat() to choose the precision

2015-12-22 Thread SilentGhost

SilentGhost added the comment:

I think the patch is nearly finalised, but I'd appreciate if someone else would 
carefully go over the new C code. After that, I think, the patch could be 
committed.

--

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Steve Dower

Steve Dower added the comment:

"We" is a lot of different companies and individuals. Anyone distributing 
prebuilt binaries is helping here, a few people are working on the licensing 
concerns for some components, other people are working on C BLAS libraries.

I see the issue approximately as "it's hard to install the scipy stack", which 
is broader than "Windows does not have a Free Fortran compiler" and allows for 
more solutions (apologies for putting words in your mouth, which is not my 
intent, though I have certainly seen a fixation on this one particular solution 
to the exclusion of other possibilities).

--

___
Python tracker 

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



unable to open IDLE for Python3.50rc1 on windows10 64bit AMD

2015-12-22 Thread Nicky Mac
I have run the install (and repair) which explicitly includes Tcl/Tk and l
have this problem:

Microsoft Windows [Version 10.0.10586] (c) 2015 Microsoft Corporation. All
rights reserved.

>C:\Python\Python35\python.exe -m idlelib
** IDLE can't import Tkinter.
Your Python may not be configured for Tk. **

Please suggest how this can be fixed
any support greatly appreciated

Nick  McElwaine
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue24840] implement bool conversion for enums to prevent odd edge case

2015-12-22 Thread Gregory P. Smith

Gregory P. Smith added the comment:

This change breaks existing code that is relying on the behavior of the enum 
API as shipped in 3.4 and 3.5.  Please do NOT do this.

Worse, you've landed this change in a "stable" release of the enum34 "backport" 
module (1.1.1) despite it never having been released as a stable Python API.  
Please do not let *the backport* get ahead of the latest stable released Python 
API.

https://bitbucket.org/stoneleaf/enum34/issues/10/versions-of-enum34-111-break-support-for

--
nosy: +gregory.p.smith
resolution: fixed -> 
status: closed -> open
versions: +Python 3.6

___
Python tracker 

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



[issue21815] imaplib truncates some untagged responses

2015-12-22 Thread Lita Cho

Lita Cho added the comment:

Sounds good.

On Tuesday, December 22, 2015, Maciej Szulik  wrote:

>
> Maciej Szulik added the comment:
>
> Lita can you please apply the changes from latest review (from
> SilentGhost). Especially the one regarding newline, which currently fails
> to apply this patch on default. If all those will be cleaned I'll recommend
> this patch for David for inclusion.
>
> --
>
> ___
> Python tracker >
> 
> ___
>

--

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Anthony Sottile

Anthony Sottile added the comment:

Breaks this function:

```
def rmtree(path):
"""On windows, rmtree fails for readonly dirs."""
def handle_remove_readonly(func, path, exc):  # pragma: no cover (windows)
excvalue = exc[1]
if func in (os.rmdir, os.remove) and excvalue.errno == errno.EACCES:
os.chmod(path, stat.S_IRWXU | stat.S_IRWXG | stat.S_IRWXO)
func(path)
else:
raise
shutil.rmtree(path, ignore_errors=False, onerror=handle_remove_readonly)
```

--

___
Python tracker 

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



[issue25251] Unknown MS Compiler version 1900

2015-12-22 Thread Tod Haren

Tod Haren added the comment:

In addition to patching cygwincompiler.py I also had to patch 
numpy\distutils\misc_util.py and numpy\distutils\mingw32ccompiler.py to handle 
the new dll name.

A pull request has been submitted for the numpy patches. 
https://github.com/numpy/numpy/pull/6875

--
nosy: +Tod Haren

___
Python tracker 

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



[issue25930] Document that os.remove is semantically identical to os.unlink

2015-12-22 Thread Brett Cannon

Brett Cannon added the comment:

I think it's reasonable to say the documentation could be misconstrued -- as 
Anthony has shown -- and so a patch changing the os.remove docs to say "This 
function is semantically identical to os.unlink()" would be acceptable.

--
assignee:  -> docs@python
components: +Documentation -Argument Clinic, Library (Lib)
nosy: +brett.cannon, docs@python
resolution: not a bug -> 
status: closed -> open
title: os.unlink != os.remove in python3.5 -> Document that os.remove is 
semantically identical to os.unlink

___
Python tracker 

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



[issue25929] When doing string.replace, it uses the entire 'find' string and doesn't let it get reused...

2015-12-22 Thread R. David Murray

R. David Murray added the comment:

No, you aren't missing anything, it is working as designed.

--
nosy: +r.david.murray
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 

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



[issue25770] expose name, args, and kwargs from methodcaller

2015-12-22 Thread Joe Jevnik

Joe Jevnik added the comment:

Is there a decision on the name? I can update the patch if needed.

--

___
Python tracker 

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



[issue24379] operator.subscript

2015-12-22 Thread Joe Jevnik

Joe Jevnik added the comment:

> and the latter might give the impression it was some sort of special 
> method/attribute when it was not.

Wouldn't adding this be special because it is specifically reserved by CPython 
as an implementation detail?

Also, would adding this name (__stub or __stub__) be sufficient to get this 
patch merged again. I would not mind investigating the gc_head issue after but 
I view that as a separate issue which is only exercised by this patch.

--

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Larry Hastings

Larry Hastings added the comment:

Unless you can explain what bugs this is causing, I don't see any need to 
change the behavior.

--
resolution:  -> not a bug
status: open -> closed

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Anthony Sottile

Anthony Sottile added the comment:

When calling shutil.rmtree on windows on a readonly directory, the error 
handler is called with os.unlink as the first argument `func` which fails the 
check `func in (os.rmdir, os.remove)` which succeeded on previous python 
versions

--

___
Python tracker 

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



[issue15068] fileinput requires two EOF when reading stdin

2015-12-22 Thread Benjamin Peterson

Benjamin Peterson added the comment:

That individually is probably okay. It's more a question of whether the
entire change is appropriate for 2.7.

Note PendingDeprecationWarning is fairly useless, since it's rarely
enabled.

On Sat, Dec 19, 2015, at 00:34, Serhiy Storchaka wrote:
> 
> Serhiy Storchaka added the comment:
> 
> Benjamin, is it good to add PendingDeprecationWarning in 2.7?
> 
> --
> nosy: +benjamin.peterson
> versions:  -Python 3.4
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

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



Re: v3.5.1 - msi download

2015-12-22 Thread jfong
Mark Lawrence at 2015/12/21 UTC+8 8:50:00PM wrote:
> My fellow Pythonistas, ask not what our language can do for you, ask
> what you can do for our language.

When I saw this sentence, I can't resist to think of the famous lie created by 
president John kennedy: "Ask not what your country can do for you, ask what you 
can do for your country".

A COUNTRY WAS BUILT TO SERVE THE PEOPLE!!!

Do you think people are so boring that they have to build a country to serve to?

But there is always a bunch of idiots lost in these gorgeous words, don't even 
take a single moment to think of it, completely forgot the purpose of what a 
country was built for. The means eventually become the object, and millions of 
millions idiots sacrifice their life for this imaginary object.

A LANGUAGE WAS BUILT TO SERVE THE USER!!!


-- 
https://mail.python.org/mailman/listinfo/python-list


[issue21998] asyncio: support fork

2015-12-22 Thread Adam Bishop

Adam Bishop added the comment:

A note about this issue should really be added to the documentation - on OS X, 
it fails with the rather non-sensical "OSError: [Errno 9] Bad file descriptor", 
making this very hard to debug.

I don't have any specific requirement for fork support in asyncio as it's 
trivial to move loop creation after the fork, but having to run the interpreter 
through GDB to diagnose the problem is not a good state of affairs.

--
nosy: +Adam.Bishop

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Larry Hastings

Larry Hastings added the comment:

How does it break?  Maybe you could explain more.

--

___
Python tracker 

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



[issue25931] os.fork() command distributed in windows Python27 (in SocketServer module)

2015-12-22 Thread Sam Lobel

New submission from Sam Lobel:

I ran into this bug while using multiprocessing in Flask, which deep down uses 
the SocketServer.py module.

There's a call to os.fork() in the windows version , which obviously doesn't 
work. So SocketServer.py can't be used on windows.

Maybe replace it with something from the multiprocessing module?

--
components: Windows
messages: 256896
nosy: Sam Lobel, paul.moore, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: os.fork() command distributed in windows Python27 (in SocketServer 
module)
type: behavior
versions: Python 2.7

___
Python tracker 

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



[issue24379] Add operator.subscript as a convenience for creating slices

2015-12-22 Thread Emanuel Barry

Changes by Emanuel Barry :


--
nosy: +ebarry
stage: resolved -> patch review
title: operator.subscript -> Add operator.subscript as a convenience for 
creating slices

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Nathaniel Smith

Nathaniel Smith added the comment:

Hi Steve- okay, thanks for clarifying! I think you already know this, but for 
the general record: the reason for the apparent fixation on this solution is 
that after a lot of struggle it's emerged as basically the only contender for 
scipy-development-on-windows; there are a number of problems (fortran, BLAS, 
C99, python 2.7 support, desire to distribute F/OSS software) and it's the only 
thing that solves all of them. The details that lead to this conclusion are 
rather complicated, but here's how I understand the situation as of the end of 
2015:

- If you just want to compile C/C++ (don't need fortran or BLAS), and you can 
either [live with MSVC 2008's somewhat archaic understanding of C] or [drop 2.7 
support and only support 3.5], then we're actually in a pretty good place now: 
you can install the msvc-for-2.7 distribution for 2.7, install msvc 2015 for 
3.5, and you're good to go.

- Alternatively if you don't care about your code being F/OSS and have money to 
spare, then you can solve all of the above problems by using icc/ifort for your 
compiler and MKL for your BLAS. (The "F/OSS" caveat here is because you 
actually cannot distribute binaries using this toolchain as F/OSS.)

- If you're a F/OSS project and you need BLAS, then your options are either 
OpenBLAS or (hopefully soon) BLIS. Neither of them can be compiled with any 
version of MSVC, because both of them use asm extensions/dialects that MSVC 
doesn't understand. The good news is that soon probably you will be able to 
compile them with clang! However, I think clang only targets compatibility with 
recent MSVC, not MSVC 2008, so this is useless for python 2.7? I could be wrong 
here.

(Well, you can also try crossing your fingers and try mixing runtimes -- the 
BLAS interface specifically is narrow enough that you might be able to get away 
with it. I'm not sure how many projects can get away with just BLAS and no 
LAPACK, though, and LAPACK is Fortran; I've heard rumors of LAPACK-in-C, but 
AFAICT they're still just rumors...)

- If you're a free software project who needs [C99 on Python 2.7] or [BLAS on 
2.7] or [Fortran, period], then none of the above options help, or show any 
prospect of helping (except maybe if clang can target MSVC 2008 compatibility). 
OTOH the mingw-w64-with-improved-MSVC-compatibility approach fixes all of these 
problems at once, thus eliminating the whole decision tree above in one swoop.

It is true that it doesn't help with the "GPL cooties" problem; AFAIK that's 
the only limitation. Of course any company has the right to decide that they 
absolutely will not use a GPL-licensed compiler, for any reason they might feel 
like. But if they want random volunteers at python.org to care about this then 
it seems to me that those companies need to *either* articulate some convincing 
reason why their needs are legitimate (gcc seems to work just fine for tons and 
tons of companies, including e.g. the entire linux and android ecosystems), 
*or* start paying those volunteers to care :-). And even if we do care, then 
I'm not sure what there is to be done about it anyway -- if you want to go buy 
a license to icc/ifort then you can do that today, have fun, it seems to work 
great?

--

___
Python tracker 

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



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

2015-12-22 Thread Марк Коренберг

New submission from Марк Коренберг:

dir_fd support is good in `os` module. but tempfile module lack support of that 
great feature. Please add.

--
messages: 256856
nosy: mmarkk
priority: normal
severity: normal
status: open
title: add dir_fd for mkstemp, and also maybe to all tempfile.*
versions: Python 3.3, Python 3.4, Python 3.5, Python 3.6

___
Python tracker 

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



[issue25860] os.fwalk() silently skips remaining directories when error occurs

2015-12-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 767262c149ca by Serhiy Storchaka in branch '3.5':
Issue #25860: os.fwalk() no longer skips remaining directories when error 
occurs.
https://hg.python.org/cpython/rev/767262c149ca

New changeset a85675dabb8f by Serhiy Storchaka in branch 'default':
Issue #25860: os.fwalk() no longer skips remaining directories when error 
occurs.
https://hg.python.org/cpython/rev/a85675dabb8f

--
nosy: +python-dev

___
Python tracker 

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



[issue25928] Improve performance of statistics._decimal_to_ratio and fractions.from_decimal

2015-12-22 Thread John Walker

John Walker added the comment:

Heres the output of running the benchmark on my machine:

Testing proposed implementation
number = 1
0.07098613299967838
number = 10
0.6952260910002224
number = 100
6.948197601999709
Testing current implementation
number = 1
0.141816276996
number = 10
1.350394603001405
number = 100
13.625065807000283

--

___
Python tracker 

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



[issue25928] Improve performance of statistics._decimal_to_ratio and fractions.from_decimal

2015-12-22 Thread John Walker

Changes by John Walker :


--
type:  -> performance

___
Python tracker 

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



[issue25929] When doing string.replace, it uses the entire 'find' string and doesn't let it get reused...

2015-12-22 Thread Mark Cline

New submission from Mark Cline:

The Title might be a bit awkward but this is what I mean:

before = ''
after = before.replace(',,', ',null,')
print(after)
>,null,,null,

I suspect it is starting the second search at the start of the first find + 
length of the find? ie:

0123
Starting the next search at spot 2 (the 3rd ,).

This might be expected behaviour as it is looking at the rest of the string 
after finding the match, as opposed to taking the updated string:
,null,,, after the first replace. (Actually, writing that out it does make 
sense that it would behave like this, but thought I would mention just in case 
I am missing something). 

[Its easy enough to work around it, but just thought I would mention it :D]

--
components: Library (Lib)
messages: 256877
nosy: Mark Cline
priority: normal
severity: normal
status: open
title: When doing string.replace, it uses the entire 'find' string and doesn't 
let it get reused...
type: behavior
versions: Python 3.5

___
Python tracker 

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



[issue21815] imaplib truncates some untagged responses

2015-12-22 Thread Maciej Szulik

Maciej Szulik added the comment:

Lita can you please apply the changes from latest review (from SilentGhost). 
Especially the one regarding newline, which currently fails to apply this patch 
on default. If all those will be cleaned I'll recommend this patch for David 
for inclusion.

--

___
Python tracker 

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



[issue12797] io.FileIO and io.open should support openat

2015-12-22 Thread Eryk Sun

Eryk Sun added the comment:

Марк, os.open added dir_fd support in 3.3, which is implemented on POSIX 
systems by calling openat. The dir_fd parameter is available for many os 
functions. This is discussed in section 1.5, Files and Directories [1].

It would be nice if we could support dir_fd on Windows as well, but we'd have 
to bypass the CRT and Windows API to use the native NT API instead, such as 
NtCreateFile [2]. The kernel has supported opening a file relative to a 
directory handle since it was release in 1993 (NT 3.1). All named kernel 
objects are referenced using an OBJECT_ATTRIBUTES [3] data structure. 
ObjectName -- a path with up to 32768 UTF-16 characters -- is relative to the 
RootDirectory handle if non-NULL. This is how paths relative to the process 
working directory are implemented, but changing the working directory isn't 
thread safe. 

[1]: https://docs.python.org/3/library/os.html#files-and-directories
[2]: https://msdn.microsoft.com/en-us/library/ff566424
[3]: https://msdn.microsoft.com/en-us/library/ff557749

--
nosy: +eryksun

___
Python tracker 

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



Re: unable to open IDLE for Python3.50rc1 on windows10 64bit AMD

2015-12-22 Thread Terry Reedy


On 12/22/2015 3:27 PM, Nicky Mac wrote:

I have run the install (and repair) which explicitly includes Tcl/Tk and l
have this problem:


First, I would download and install the final 3.5.1. I believe there was 
a change to the installer that might, possibly, make a difference.


Write down exactly the install options you choose.


C:\Python\Python35\python.exe -m idlelib

** IDLE can't import Tkinter.
Your Python may not be configured for Tk. **


Then run python -m tkinter to remove IDLE from the issue.
If problem persists, report again.


Please suggest how this can be fixed
any support greatly appreciated


--
Terry Jan Reedy

--
https://mail.python.org/mailman/listinfo/python-list


[issue25860] os.fwalk() silently skips remaining directories when error occurs

2015-12-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 7995a81236b6 by Serhiy Storchaka in branch '3.5':
Issue #25860: Fixed test failure caused by inconsistency of os.walk() and
https://hg.python.org/cpython/rev/7995a81236b6

New changeset dcf9e9ae5393 by Serhiy Storchaka in branch 'default':
Issue #25860: Fixed test failure caused by inconsistency of os.walk() and
https://hg.python.org/cpython/rev/dcf9e9ae5393

--

___
Python tracker 

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



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

2015-12-22 Thread Grant Edwards
On 2015-12-22, Ian Kelly  wrote:
> On Tue, Dec 22, 2015 at 8:17 AM, Grant Edwards  
> wrote:
>> On 2015-12-21, Steven D'Aprano  wrote:
>>
>>> So as far as I am concerned, if changes of subject line breaks threading for
>>> you, so sad, too bad. Go without threading or use a better mail client.
>>
>> Same here.  After getting what is effectively a 

[issue25919] htp.client PUT method ignores error responses sent immediatly after headers

2015-12-22 Thread Wiktor Niesiobedzki

Wiktor Niesiobedzki added the comment:

Here is revised patch. Also covers changes to tests.

--
Added file: http://bugs.python.org/file41392/http.client.put.fix.patch

___
Python tracker 

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



Newbie: Convert strings in nested dict to tuples

2015-12-22 Thread KP
I now know how to convert a string cont. coordinates to a tuple, but hwo can I 
do this?

Given

cfg = {'canvas': ('3840', '1024'),
  'panel1': {'gpio': '1', 'id': '4', 'co': '0,0,1280,1024'}, 
  'panel2': {'gpio': '2', 'id': '5', 'co': '1280,0,2560,1024'},
  'panel3': {'gpio': '3', 'id': '6', 'co': '2560,0,3840,1024'}}

how can I transform cfg to 

cfg = {'canvas': ('3840', '1024'),
  'panel1': {'gpio': '1', 'id': '4', 'co': ('0','0','1280','1024')}, 
  'panel2': {'gpio': '2', 'id': '5', 'co': ('1280','0','2560','1024')},
  'panel3': {'gpio': '3', 'id': '6', 'co': ('2560','0','3840','1024')}}

Again, thanks for all help!
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: Newbie: Convert strings in nested dict to tuples

2015-12-22 Thread KP
Beautiful - thanks!

On Tuesday, 22 December 2015 15:23:25 UTC-8, Peter Otten  wrote:
> KP wrote:
> 
> > I now know how to convert a string cont. coordinates to a tuple, but hwo
> > can I do this?
> > 
> > Given
> > 
> > cfg = {'canvas': ('3840', '1024'),
> >   'panel1': {'gpio': '1', 'id': '4', 'co': '0,0,1280,1024'},
> >   'panel2': {'gpio': '2', 'id': '5', 'co': '1280,0,2560,1024'},
> >   'panel3': {'gpio': '3', 'id': '6', 'co': '2560,0,3840,1024'}}
> > 
> > how can I transform cfg to
> > 
> > cfg = {'canvas': ('3840', '1024'),
> >   'panel1': {'gpio': '1', 'id': '4', 'co': ('0','0','1280','1024')},
> >   'panel2': {'gpio': '2', 'id': '5', 'co':
> >   ('1280','0','2560','1024')}, 'panel3': {'gpio': '3', 'id': '6',
> >   'co': ('2560','0','3840','1024')}}
> > 
> > Again, thanks for all help!
> 
> >>> cfg = {'canvas': ('3840', '1024'),
> ...   'panel1': {'gpio': '1', 'id': '4', 'co': '0,0,1280,1024'}, 
> ...   'panel2': {'gpio': '2', 'id': '5', 'co': '1280,0,2560,1024'},
> ...   'panel3': {'gpio': '3', 'id': '6', 'co': '2560,0,3840,1024'}}
> >>> 
> >>> for value in cfg.values():
> ... if isinstance(value, dict):
> ... value["co"] = tuple(value["co"].split(","))
> ... 
> >>> import pprint
> >>> pprint.pprint(cfg)
> {'canvas': ('3840', '1024'),
>  'panel1': {'co': ('0', '0', '1280', '1024'), 'gpio': '1', 'id': '4'},
>  'panel2': {'co': ('1280', '0', '2560', '1024'), 'gpio': '2', 'id': '5'},
>  'panel3': {'co': ('2560', '0', '3840', '1024'), 'gpio': '3', 'id': '6'}}

-- 
https://mail.python.org/mailman/listinfo/python-list


[issue24840] implement bool conversion for enums to prevent odd edge case

2015-12-22 Thread Ethan Furman

Ethan Furman added the comment:

The enum34 backport has been fixed to not have 3.6 only features (assuming the 
__bool__ change was the only one).

Was that your only objection, or do you not want this change in 3.6 either?

--

___
Python tracker 

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



[issue25928] Improve performance of statistics._decimal_to_ratio and fractions.from_decimal

2015-12-22 Thread John Walker

New submission from John Walker:

In statistics, there is a FIXME on Line 250 above _decimal_to_ratio that says:

# FIXME This is faster than Fraction.from_decimal, but still too slow.

Half of the time is spent in a conversion in d.as_tuple(). Decimal internally 
stores the digits as a string, but in d.as_tuple(), the digits are individually 
cast to integers and returned as a tuple of integers.

This is OK, but _decimal_to_ratio undoes the work that was done in d.as_tuple() 
by adding them all back into an integer. A similar, but slightly different 
approach is taken in Fractions.from_decimal, where the tuple is cast into a 
string and then parsed into an integer. We can be a lot faster if we use the 
_int instance variable directly.

In the case of _decimal_to_ratio, the new code seems to be twice as fast with 
usage _decimal_to_ratio(Decimal(str(random.random(:


def _decimal_to_ratio(d):
sign, exp = d._sign, d._exp
if exp in ('F', 'n', 'N'):  # INF, NAN, sNAN
assert not d.is_finite()
return (d, None)
num = int(d._int)
if exp < 0:
den = 10**-exp
else:
num *= 10**exp
den = 1
if sign:
num = -num
return (num, den)

If the performance improvement is considered worthwhile, here are a few 
solutions I see.

1) Use _int directly in fractions and statistics.

2) Add a digits_as_str method to Decimal. This prevents exposing _int as an 
implementation detail, and makes sense to me since I suspect there is a lot of 
code casting the tuple of int to a string anyway. 

3) Add a parameter to as_tuple for determining whether digits should be 
returned as a string or a tuple.

4) Deprecate _int in Decimal and add a new reference str_digits.

There are probably more solutions. I lean towards 4, because it makes usage 
easier and avoids cluttering Decimal with methods. 

Here is what I used for benchmarks:



import timeit

old_setup = """
import random
from decimal import Decimal

def _decimal_to_ratio(d):
sign, digits, exp = d.as_tuple()
if exp in ('F', 'n', 'N'):  # INF, NAN, sNAN
assert not d.is_finite()
return (d, None)
num = 0
for digit in digits:
num = num*10 + digit
if exp < 0:
den = 10**-exp
else:
num *= 10**exp
den = 1
if sign:
num = -num
return (num, den)

def run_it():
dec = Decimal(str(random.random()))
_decimal_to_ratio(dec)
"""

new_setup = """
import random
from decimal import Decimal

def _decimal_to_ratio(d):
sign, exp = d._sign, d._exp
if exp in ('F', 'n', 'N'):  # INF, NAN, sNAN
assert not d.is_finite()
return (d, None)
num = int(d._int)
if exp < 0:
den = 10**-exp
else:
num *= 10**exp
den = 1
if sign:
num = -num
return (num, den)

def run_it():
dec = Decimal(str(random.random()))
_decimal_to_ratio(dec)
"""

if __name__ == '__main__':
print("Testing proposed implementation")
print("number = 1")
print(timeit.Timer(stmt='run_it()', setup=new_setup).timeit(number=1))
print("number = 10") 
print(timeit.Timer(stmt='run_it()', setup=new_setup).timeit(number=10))
print("number = 100") 
print(timeit.Timer(stmt='run_it()', setup=new_setup).timeit(number=100))

print("Testing old implementation")
print("number = 1")
print(timeit.Timer(stmt='run_it()', setup=old_setup).timeit(number=1))
print("number = 10") 
print(timeit.Timer(stmt='run_it()', setup=old_setup).timeit(number=10))
print("number = 100") 
print(timeit.Timer(stmt='run_it()', setup=old_setup).timeit(number=100))

--
components: Library (Lib)
messages: 256873
nosy: johnwalker
priority: normal
severity: normal
status: open
title: Improve performance of statistics._decimal_to_ratio and 
fractions.from_decimal
versions: Python 3.5

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Anthony Sottile

New submission from Anthony Sottile:

I've confirmed this bug is present on both windows and linux, the outputs below 
are from linux however.

Compare:

```
$ python3.4 --version
Python 3.4.3
$ python3.4 -c 'import os; print(os.unlink == os.remove)'
True
```

```
$ python3.5 --version
Python 3.5.0
$ python3.5 -c 'import os; print(os.unlink == os.remove)'
False
```

The docs say: https://docs.python.org/3/library/os.html#os.remove

"This function is identical to unlink()."

To me identity means `is` but I at least expect the `==` behaviour of previous 
versions.

--
messages: 256880
nosy: Anthony Sottile
priority: normal
severity: normal
status: open
title: os.unlink != os.remove in python3.5
versions: Python 3.5

___
Python tracker 

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



[issue23846] asyncio : ProactorEventLoop raised BlockingIOError when ThreadPoolExecutor has many workers

2015-12-22 Thread Yury Selivanov

Yury Selivanov added the comment:

> Why are you using 2 threads?

That's a good question.

In any case it looks like self-pipe sock's buffer was overflown because 
call_soon_threadsafe was called too many times, and loop._read_from_self 
couldn't empty the buffer promptly.  Then, at some point, _write_to_self failed 
with an IOError.

It looks like this was fixed for the selector loop, but not for proactor:

selector_events.py:

def _write_to_self(self):
csock = self._csock
if csock is not None:
try:
csock.send(b'\0')
except OSError:
if self._debug:
logger.debug("Fail to write a null byte into the "
 "self-pipe socket",
 exc_info=True)

proactor_events.py:

def _write_to_self(self):
self._csock.send(b'\0')

--

___
Python tracker 

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



Re: Newbie: Convert strings in nested dict to tuples

2015-12-22 Thread Peter Otten
KP wrote:

> I now know how to convert a string cont. coordinates to a tuple, but hwo
> can I do this?
> 
> Given
> 
> cfg = {'canvas': ('3840', '1024'),
>   'panel1': {'gpio': '1', 'id': '4', 'co': '0,0,1280,1024'},
>   'panel2': {'gpio': '2', 'id': '5', 'co': '1280,0,2560,1024'},
>   'panel3': {'gpio': '3', 'id': '6', 'co': '2560,0,3840,1024'}}
> 
> how can I transform cfg to
> 
> cfg = {'canvas': ('3840', '1024'),
>   'panel1': {'gpio': '1', 'id': '4', 'co': ('0','0','1280','1024')},
>   'panel2': {'gpio': '2', 'id': '5', 'co':
>   ('1280','0','2560','1024')}, 'panel3': {'gpio': '3', 'id': '6',
>   'co': ('2560','0','3840','1024')}}
> 
> Again, thanks for all help!

>>> cfg = {'canvas': ('3840', '1024'),
...   'panel1': {'gpio': '1', 'id': '4', 'co': '0,0,1280,1024'}, 
...   'panel2': {'gpio': '2', 'id': '5', 'co': '1280,0,2560,1024'},
...   'panel3': {'gpio': '3', 'id': '6', 'co': '2560,0,3840,1024'}}
>>> 
>>> for value in cfg.values():
... if isinstance(value, dict):
... value["co"] = tuple(value["co"].split(","))
... 
>>> import pprint
>>> pprint.pprint(cfg)
{'canvas': ('3840', '1024'),
 'panel1': {'co': ('0', '0', '1280', '1024'), 'gpio': '1', 'id': '4'},
 'panel2': {'co': ('1280', '0', '2560', '1024'), 'gpio': '2', 'id': '5'},
 'panel3': {'co': ('2560', '0', '3840', '1024'), 'gpio': '3', 'id': '6'}}


-- 
https://mail.python.org/mailman/listinfo/python-list


[issue8604] Adding an atomic FS write API

2015-12-22 Thread Марк Коренберг

Марк Коренберг added the comment:

You also forgot about two things:

1. set temporary file permissions before rename
2. fsync(open(os.dirname(temporaryfile)))
3. if original file name is symlink, replace will works wrong. os.realpath 
should be used.

So, here are real life function, that we use in production:


# TODO: save_mtime, save_selinux, extended attr, chattrs and so on...
# TODO: malicious user may replace directory with another while writing to file,
#   so we should use open directory first, and then use openat() and 
renameat()
#   with relative filename instead of specifying absolute path.
#   also NameTemporaryFile should allow to specify dir=
@contextmanager
def replace_file(path, save_perms=False, fsync=True, **kwargs):
realpath = os.path.realpath(path)
operating_dir = os.path.dirname(realpath)
uid = None
gid = None
mode = None
if save_perms:
try:
stinfo = os.lstat(realpath)
uid = stinfo.st_uid
gid = stinfo.st_gid
mode = stinfo.st_mode
except OSError as e:
if e.errno != errno.ENOENT:
raise

with NamedTemporaryFile(dir=operating_dir, **kwargs) as fff:
filedes = fff.fileno()
if None not in (uid, gid, mode):
os.fchown(filedes, uid, gid)
os.fchmod(filedes, mode & 0o)

yield fff

# survive application crash
fff.flush()
if fsync:
# survive power outage, is not required if that is temporary file
os.fsync(filedes)
os.rename(fff.name, realpath)

# see http://bugs.python.org/issue21579
fff._closer.delete = False

if fsync:
# Sync directory: 
http://stackoverflow.com/questions/3764822/how-to-durably-rename-a-file-in-posix
dirfd = os.open(operating_dir, os.O_RDONLY | os.O_CLOEXEC | 
os.O_DIRECTORY)
try:
os.fsync(dirfd)
finally:
os.close(dirfd)

--
nosy: +mmarkk

___
Python tracker 

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



[issue12797] io.FileIO and io.open should support openat

2015-12-22 Thread Марк Коренберг

Марк Коренберг added the comment:

But... os.openat() is still missing... why status is closed() ?!

--
nosy: +mmarkk

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Steve Dower

Steve Dower added the comment:

And FTR, there are plenty of major Python-using companies that insist on 
compiling from scratch and also refuse to touch GPL at all, no matter how many 
exemptions are in the licenses. GFortran is not the ideal solution for these 
users.

--

___
Python tracker 

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



[issue25919] htp.client PUT method ignores error responses sent immediatly after headers

2015-12-22 Thread SilentGhost

SilentGhost added the comment:

There is a test suite which can be run to test for breakages:

./python -m test test_httplib

If you do that you'll notice that some things are broken, I got error in 5 
different tests related to you select.select call:

TypeError: argument must be an int, or have a fileno() method. 

Your test code seems to be running fine now, though.

--
nosy: +SilentGhost

___
Python tracker 

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



[issue25919] htp.client PUT method ignores error responses sent immediatly after headers

2015-12-22 Thread SilentGhost

SilentGhost added the comment:

That was a testing issue, apparently test.test_httplib.FakeSocket is not fake 
enough.

--

___
Python tracker 

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



[issue25930] os.unlink != os.remove in python3.5

2015-12-22 Thread Eryk Sun

Eryk Sun added the comment:

This is due to using argument clinic in Modules/posixmodule.c:

/*[clinic input]
os.remove = os.unlink

builtin_function_or_method instances are equal if m_self (the module in this 
case) and m_ml->ml_meth (the C function) are the same. In 3.4, the function 
posix_unlink is used for both os.unlink and os.remove, which is why they 
compare as equal. In 3.5, argument clinic defines separate os_unlink and 
os_remove implementations in Modules/clinic/posixmodule.c.h.

--
components: +Argument Clinic, Library (Lib)
nosy: +eryksun, larry
versions: +Python 3.6

___
Python tracker 

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



[issue24840] implement bool conversion for enums to prevent odd edge case

2015-12-22 Thread Gregory P. Smith

Gregory P. Smith added the comment:

lets collect some examples of where it causes problems (someone ran into the 
problem at work which is why i hunted down this bugs.python.org issue) before 
deciding.

If it stays in, it needs a mention in both Misc/NEWS and What's New as it will 
require some people to test and update their code for 3.6.  Examples will let 
us decide which way to go.

--

___
Python tracker 

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



[issue24658] open().write() fails on 2 GB+ data (OS X)

2015-12-22 Thread Ian Carroll

Ian Carroll added the comment:

Write still fails on 3.5.1 and OS X 10.11.2. I'm no dev, so can someone explain 
how to use the patch while it's under review?

--
nosy: +Ian Carroll

___
Python tracker 

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



convert to python code

2015-12-22 Thread Rodrick Brown
Tried a few things but can't seem to get it right any help ?

let times = (...matrices) =>

  matrices.reduce(

([a,b,c], [d,e,f]) => [a*d + b*e, a*e + b*f, b*e + c*f]

  );
-- 
https://mail.python.org/mailman/listinfo/python-list


Re: convert to python code

2015-12-22 Thread Ben Finney
Rodrick Brown  writes:

> Tried a few things but can't seem to get it right any help ?

To convert it to Python code, you'll need to actually write some code.

Please show here in this forum the actual Python code which is not
behaving how you want, and say *exactly* what it's doing different from
what you expect (and, preferably, explain why you expect it to behave
differently).

-- 
 \  “Do I believe in God? … without clarification of a kind I have |
  `\never seen, I don’t know whether I believe or don’t believe in |
_o__)whatever a questioner has in mind.” —Noam Chomsky |
Ben Finney

-- 
https://mail.python.org/mailman/listinfo/python-list


[issue25913] base64.a85decode adobe flag incorrectly utilizes <~ as a marker causing error

2015-12-22 Thread Swati Jaiswal

Changes by Swati Jaiswal :


Added file: http://bugs.python.org/file41393/iss_25913_2.patch

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Ralf Gommers

Ralf Gommers added the comment:

> "We" is a lot of different companies and individuals. Anyone distributing 
> prebuilt binaries is helping here, a few people are working on the licensing 
> concerns for some components, other people are working on C BLAS libraries.

Note that we by default recommend to users to use a distribution like 
Anaconda/Canopy (for example at http://scipy.org/install.html). That's fine for 
many scientific users, but not for people that already have a Python stack 
installed or simply prefer to use pip for another reason.  So pre-built 
binaries like the ones in Anaconda/Canopy help, but don't solve the "make `pip 
install scipy` work" problem. And giving up on pip/PyPi would make no one 
happy...

> I see the issue approximately as "it's hard to install the scipy stack", 
> which is broader than "Windows does not have a Free Fortran compiler" 

It's: "it's hard to install the scipy stack on Windows". On OS X and Linux it's 
really not that hard. On OS X, you can install all core packages with pip 
(there are binary wheels on PyPi). On Linux you can do that too after using 
your package manager to install a few things like BLAS/LAPACK and Python 
development headers.

And the lack of Windows wheels on PyPi is directly related to no free Fortran 
compiler.

> and allows for more solutions (apologies for putting words in your mouth, 
> which is not my intent, though I have certainly seen a fixation on this one 
> particular solution to the exclusion of other possibilities).

Much more effort has gone into pre-built binaries than into MinGW, as well as 
into other things that help but can't be a full solution like a C BLAS. And I 
haven't seen other solutions to "make the scipy stack pip-installable" that 
could work. So I have to disagree with "fixation".

--

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Ralf Gommers

Ralf Gommers added the comment:

> I'm happy and keen to help so please feel free to poke me if you need 
> assistance with anything. I'll keep an eye out too - is it actively being 
> discussed on any list?

Thanks Henry. There's no ongoing discussion on a list right now, but give it a 
week or two. I'll make sure to ping you.

--

___
Python tracker 

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



OT: citizens and countries - was Re: v3.5.1 - msi download

2015-12-22 Thread Michael Torrie
On 12/22/2015 07:06 PM, jf...@ms4.hinet.net wrote:
> Mark Lawrence at 2015/12/21 UTC+8 8:50:00PM wrote:
>> My fellow Pythonistas, ask not what our language can do for you, ask
>> what you can do for our language.
> 
> When I saw this sentence, I can't resist to think of the famous lie created 
> by president John kennedy: "Ask not what your country can do for you, ask 
> what you can do for your country".
> 
> A COUNTRY WAS BUILT TO SERVE THE PEOPLE!!!
> 
> Do you think people are so boring that they have to build a country to serve 
> to?

In the American way of thinking, the country *is* the people.  So it was
neither a lie nor a bad thing that Kennedy proclaimed.  Maybe this is
not true for other countries, but I think most Americans would feel it
is true for their country.  And indeed the sentiment that Kennedy
expressed resonates deeply with many/most Americans. A country is only
made great by citizens willing to do many things for the good of the
country and their fellow citizens.

A country in which citizens only expect things from the country and
never think about their ability to change and benefit the country is a
week country indeed.

I say this as a someone not from the US.

-- 
https://mail.python.org/mailman/listinfo/python-list


[issue25931] os.fork() command distributed in windows Python27 (in SocketServer module)

2015-12-22 Thread Eryk Sun

Eryk Sun added the comment:

Starting a Windows process is expensive. Who not use threading, e.g. 
SocketServer.ThreadingTCPServer? 

It seems to me that it's a bug to even define ForkingMixIn, ForkingTCPServer, 
and ForkingUDPServer on Windows. Those should be conditionally defined 
depending on the existence of os.fork.

--
components: +Library (Lib)
nosy: +eryksun
versions: +Python 3.5, Python 3.6

___
Python tracker 

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



[issue13317] building with 2to3 generates wrong import paths because build_ext is run after build_py

2015-12-22 Thread Swati Jaiswal

Swati Jaiswal added the comment:

Can someone help with tests? I just need a pointer on how to do it.

--
keywords: +patch
Added file: http://bugs.python.org/file41394/iss_13317.patch

___
Python tracker 

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



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

2015-12-22 Thread Joseph Gordon

Joseph Gordon added the comment:

I uploaded a patch that appears to fix the issue.

--
keywords: +patch
Added file: http://bugs.python.org/file41396/issue25599.patch

___
Python tracker 

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



[issue21815] imaplib truncates some untagged responses

2015-12-22 Thread Lita Cho

Lita Cho added the comment:

Here is a patch after SlientGhost's review. I have added back the newline and 
included the comments for the imaplib documentation.

--
Added file: 
http://bugs.python.org/file41395/imaplib_after_silentghost_review.patch

___
Python tracker 

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



[issue25913] base64.a85decode adobe flag incorrectly utilizes <~ as a marker causing error

2015-12-22 Thread Martin Morrison

Martin Morrison added the comment:

The proposed patch does stop requiring the leading <~, but still trims the 
first two characters off the data set. This will no doubt fail in cases where 
there is no leading marker.

I think it will need to explicitly handle the case where the leading marker is 
there vs. not.

--

___
Python tracker 

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



Re: 0x80070570-The file or directory is corrupted and unreadable

2015-12-22 Thread eryk sun
On Tue, Dec 22, 2015 at 8:02 AM, muizz hasan  wrote:
> 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 on how to solve my problem. Thank you!

Try downloading a new copy of the installer. Clear your browser cache first.
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue23846] asyncio : ProactorEventLoop raised BlockingIOError when ThreadPoolExecutor has many workers

2015-12-22 Thread Guido van Rossum

Guido van Rossum added the comment:

Why are you using 2 threads?

--Guido (mobile)
On Dec 22, 2015 02:03, "Joseph Gordon"  wrote:

>
> Changes by Joseph Gordon :
>
>
> --
> nosy: +josephgordon
>
> ___
> Python tracker 
> 
> ___
>

--

___
Python tracker 

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



Re: match point

2015-12-22 Thread Chris Angelico
On Tue, Dec 22, 2015 at 9:56 PM, Thierry  wrote:
> Maybe re.match has an implementation that makes it more efficient? But
> then why would I ever use r'\A', since that anchor makes a pattern match
> in only a single position, and is therefore useless in functions like
> re.findall, re.finditer or re.split?

Much of the value of regular expressions is that they are NOT string
literals (just strings). Effectively, someone who has no authority to
change the code of the program can cause it to change from re.search
to re.match, simply by putting \A at the beginning of the search
string.

ChrisA
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue23894] lib2to3 doesn't recognize rb'...' as a raw byte string in Python 3

2015-12-22 Thread Joseph Gordon

Joseph Gordon added the comment:

With the changes in the uploaded patch it looks like strings of the form 
rb'...' are now recognized as raw byte strings.

--
keywords: +patch
Added file: http://bugs.python.org/file41382/issue23894.patch

___
Python tracker 

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



[issue25661] tokenize.untokenize does not maintain the order of tabbed indentations and leading spaces

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



[issue19873] There is a duplicate function in Lib/test/test_pathlib.py

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



match point

2015-12-22 Thread Thierry

Hi,

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)

Same for fullmatch, that amounts to
re.search(r'\A'+pattern+r'\Z', string)

The docs devote a chapter to "6.2.5.3. search() vs. match()", but they
only discuss how match() is different from search() with '^', completely
eluding the case of search() with r'\A'.

At first I thought those functions could have been introduced at a time
when r'\A' and r'\Z' did not exist, but then I noticed that re.fullmatch
is a recent addition (python 3.4)

Surely the python devs are not cluttering the interface of the re module
with useless functions for no reason, so what am I missing?

Maybe re.match has an implementation that makes it more efficient? But
then why would I ever use r'\A', since that anchor makes a pattern match
in only a single position, and is therefore useless in functions like
re.findall, re.finditer or re.split?

Thanks,

Thierry


-- 
https://mail.python.org/mailman/listinfo/python-list


[issue25922] canceling a repair install breaks the ability to uninstall, repair, or re-install

2015-12-22 Thread Steve Dower

Steve Dower added the comment:

Does rebooting allow you to keep going?

--

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Steve Dower

Steve Dower added the comment:

We are working on the Fortran issue in a few different ways, one of which is 
your work on MinGW compatibility so that gfortran can be used. But that isn't 
the only solution to this whole problem, and it's not even preferable for a lot 
of Python users, so expect other proposals to come out.

I'm not aware of any C99 limitations still present in VC14, so please let me 
know so I can file bugs against the team.

--

___
Python tracker 

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



[issue25900] unittest ignores the first ctrl-c when it shouldn't

2015-12-22 Thread Marius Gedminas

Marius Gedminas added the comment:

Somewhat unrelated nitpick: I'm not very happy that _InterruptHandler doesn't 
return early after calling the original handler.

It's all very well, if the original handler raises or does nothing at all, but 
if it's a user-installed handler that does something (e.g. print a stack trace 
to sys.stderr), then it might get called twice (or three times, after my patch).

AFAIU the situation would have to be pretty contrived:

- there's a user-provided SIGINT handler
- unittest installs its own on top
- one of the tests (or some test runner plugin) overrides the SIGINT handler 
again
- user presses Ctrl-C
- the current SIGINT handler delegates to the unittest _InterruptHandler
- _InterruptHandler notices it's not the current handler and delegates to the 
original one
- the original handler doesn't raise
- _InterruptHandler.__call__ doesn't return early and goes on to perform the 
"if called check"
- if this is a second Ctrl-C, the original handler will get called a second 
time for the same Ctrl-C event
- if there are no registered results, my new code will cause the original 
handler to get called again (a third, or a 2nd time for the same Ctrl-C event)

Is there a good reason not to add early returns after defering to the original 
handler?  Maybe it's desired that ^C should stop the test suite even if a test 
overrides the SIGINT handler but delegates back to the unittest one?

--

___
Python tracker 

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



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

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



[issue25900] unittest ignores the first ctrl-c when it shouldn't

2015-12-22 Thread Marius Gedminas

Marius Gedminas added the comment:

Here's an updated patch with tests

--
Added file: 
http://bugs.python.org/file41383/dont-ignore-first-ctrl-c-with-tests.patch

___
Python tracker 

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



[issue4709] Mingw-w64 and python on windows x64

2015-12-22 Thread Henry Gomersall

Henry Gomersall added the comment:

Thanks Ralf - I'm happy and keen to help so please feel free to poke me if you 
need assistance with anything. I'll keep an eye out too - is it actively being 
discussed on any list?

--

___
Python tracker 

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



[issue25900] unittest ignores the first ctrl-c when it shouldn't

2015-12-22 Thread Marius Gedminas

Marius Gedminas added the comment:

I looked for any existing tests (by grepping for 'signals' and 'import' on the 
same line), didn't find any (because my assumption that 'signals' would have to 
be explicitly imported was wrong).

Wrote some new tests, which made me also make some further changes to 
unittest/signals.py: https://gist.github.com/mgedmin/a91872054884dbaaa344

And that's how I discovered that there's an existing test suite for SIGINT 
handling, in test_break.py, and that it fails after my changes.

Stay tuned.

--

___
Python tracker 

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



[issue25664] Logging cannot handle Unicode logger names

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



[issue25324] Importing tokenize modifies token

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



[issue23846] asyncio : ProactorEventLoop raised BlockingIOError when ThreadPoolExecutor has many workers

2015-12-22 Thread Joseph Gordon

Changes by Joseph Gordon :


--
nosy: +josephgordon

___
Python tracker 

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



  1   2   >