[issue20434] Fix error handler of _PyString_Resize() on allocation failure

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Is there anything left for this issue?

--

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Could anyone please make a review of the patch?

--
keywords: +needs review

___
Python tracker 

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



[issue19687] Fixes for elementtree integer overflow

2014-11-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
nosy:  -serhiy.storchaka

___
Python tracker 

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



[issue19883] Integer overflow in zipimport.c

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Ping.

--

___
Python tracker 

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



[issue22889] set a timeout for DNS lookups

2014-11-17 Thread R. David Murray

R. David Murray added the comment:

As far as I know, the libc dns timeout is controlled by /etc/resolv.conf (or 
whatever the Windows equivalent is), and libc doesn't provide any way for an 
application to override this.  There is no mention of timeout on the 
resolver(3) man page.   Do you know of a way?  (One that doesn't change global 
state.)  (In theory one could re-implement a DNS resolver client, but that is 
not something CPython is going to do :)

--
nosy: +r.david.murray

___
Python tracker 

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



[issue18697] Unify arguments names in Unicode object C API documentation

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The same issue exists for other types. E.g. PyLong_* functions have Python long 
argument named as p, obj and pylong, PyFloat_* -- p and pyfloat, PyList_* -- p 
and list, PyDict_* -- p, a and mapping, PyBytes_* -- o, obj, string and bytes.

--

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Armin Rigo

Armin Rigo added the comment:

It's seriously obscure to call a user-defined __oct__ method and then mangle 
the resulting string in ways that only make sense if the __oct__ method 
returned something reasonable.

The patch is probably a little more complicated than it could be.  For example, 
I don't understand the special cases for `llen <= 1`: I don't think 
`PyString_FromStringAndSize(NULL, 1)` can return an existing object.  And if 
you cut off the final 'L' you don't replace it with '\0' any longer, which 
could in theory break some callers expecting to see a null-terminated string 
here.  PyErr_Format() should use `%.200s` for `tp_name`.

--

___
Python tracker 

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



[issue22870] urlopen timeout failed with SSL socket

2014-11-17 Thread Dave Tian

Dave Tian added the comment:

Alright. The issued URL of my case is here: www.5giay.vn
Nor am I a ssl dev...Here is what happens after further debugging: 
PySSL_SSLread() returns 1/2 bytes without any error/timeout per call. 
readline() in socket.py keeps looping. Occasionally, it may break out because 
of a newline recv’d. However, readheaders() in httplib.py repeats the 
readline() again because of another while True loop. I have no idea why I’ve 
got only 1/2 bytes recv’d from SSLread(). I am using my Mac OS for testing. 
Hope this is clear for further investigation if anyone would like to dig in.

Dave Tian
dave.jing.t...@gmail.com

> On Nov 16, 2014, at 2:38 AM, R. David Murray  wrote:
> 
> 
> R. David Murray added the comment:
> 
> I won't be the one, as I'm not conversant with the ssl C code.  What would be 
> helpful right now would be a recipe for reproducing the problem.
> 
> --
> nosy: +alex, pitrou
> 
> ___
> Python tracker 
> 
> ___

--

___
Python tracker 

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



[issue22079] Ensure in PyType_Ready() that base class of static type is static

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Here is a patch.

--
keywords: +needs review, patch
stage: needs patch -> patch review
Added file: http://bugs.python.org/file37211/issue22079.patch

___
Python tracker 

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



[issue22891] [patch]: code removal from urllib.parse.urlsplit()

2014-11-17 Thread Alexander Todorov

New submission from Alexander Todorov:

In the urllib.parse (or urlparse on Python 2.X) module there is this function:

157 def urlsplit(url, scheme='', allow_fragments=True):
158 """Parse a URL into 5 components:
159 :///?#
160 Return a 5-tuple: (scheme, netloc, path, query, fragment).
161 Note that we don't break the components up in smaller bits
162 (e.g. netloc is a single string) and we don't expand % escapes."""
163 allow_fragments = bool(allow_fragments)
164 key = url, scheme, allow_fragments, type(url), type(scheme)
165 cached = _parse_cache.get(key, None)
166 if cached:
167 return cached
168 if len(_parse_cache) >= MAX_CACHE_SIZE: # avoid runaway growth
169 clear_cache()
170 netloc = query = fragment = ''
171 i = url.find(':')
172 if i > 0:
173 if url[:i] == 'http': # optimize the common case
174 scheme = url[:i].lower()
175 url = url[i+1:]
176 if url[:2] == '//':
177 netloc, url = _splitnetloc(url, 2)
178 if allow_fragments and '#' in url:
179 url, fragment = url.split('#', 1)
180 if '?' in url:
181 url, query = url.split('?', 1)
182 v = SplitResult(scheme, netloc, url, query, fragment)
183 _parse_cache[key] = v
184 return v
185 for c in url[:i]:
186 if c not in scheme_chars:
187 break
188 else:
189 scheme, url = url[:i].lower(), url[i+1:]
190 
191 if url[:2] == '//':
192 netloc, url = _splitnetloc(url, 2)
193 if allow_fragments and '#' in url:
194 url, fragment = url.split('#', 1)
195 if '?' in url:
196 url, query = url.split('?', 1)
197 v = SplitResult(scheme, netloc, url, query, fragment)
198 _parse_cache[key] = v
199 return v



There is an issue here (or a few of them) as follows:

* if url[:1] is already lowercase (equals "http") (line 173) then .lower() on  
line 174 is reduntant:
174scheme = url[:i].lower() # <--- no need for .lower() b/c value is "http"


* OTOH line 173 could refactor the condition and match URLs where the scheme is 
uppercase. For example
173 if url[:i].lower() == 'http': # optimize the common case

* The code as is returns the same results (as far as I've tested it) for both:
urlsplit("http://github.com/atodorov/repo.git?param=value#myfragment";)
urlsplit("HTTP://github.com/atodorov/repo.git?param=value#myfragment")
urlsplit("HTtP://github.com/atodorov/repo.git?param=value#myfragment")

but the last 2 invocations also go through lines 185-199


* Lines 174-184 are essentially the same as lines 189-199. The only 
optimization I can see is avoiding the for loop around lines 185-187 which 
checks for valid characters in the URL scheme and executes only a few loops b/c 
scheme names are quite short usually.


My personal vote goes for removal of lines 173-184. 


Version-Release number of selected component (if applicable):

This is present in both Python 3 and Python 2 on all versions I have access to:

python3-libs-3.4.1-16.fc21.x86_64.rpm
python-libs-2.7.8-5.fc21.x86_64.rpm
python-libs-2.7.5-16.el7.x86_64.rpm
python-libs-2.6.6-52.el6.x86_64

Versions are from Fedora Rawhide and RHEL. Also the same code is present in the 
Mercurial repository.

Bug first reported as
https://bugzilla.redhat.com/show_bug.cgi?id=1160603

and now filing here for upstream consideration.

--
components: Library (Lib)
files: urlparse_refactor.patch
keywords: patch
messages: 231278
nosy: Alexander.Todorov
priority: normal
severity: normal
status: open
title: [patch]: code removal from urllib.parse.urlsplit()
type: enhancement
versions: Python 2.7, Python 3.2, Python 3.3, Python 3.4, Python 3.5, Python 3.6
Added file: http://bugs.python.org/file37212/urlparse_refactor.patch

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Francis MB

Francis MB added the comment:

I'm not sure if it's relevant but in the patch you changed
previous 'assert(check)' with 'if (not check) goto error'.
But the new patch code adds 'assert(len == 0 || Py_REFCNT(r1) == 1);'

Just curious, is there a reason why couldn't be in the same way?

--

___
Python tracker 

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



[issue20434] Fix error handler of _PyString_Resize() on allocation failure

2014-11-17 Thread Kristján Valur Jónsson

Kristján Valur Jónsson added the comment:

Nope, closing as fixed :)

--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thank you for your review Arigo.

Here is updated patch.

Note that the patch also fixes a reference leak if llen > INT_MAX.

--
Added file: http://bugs.python.org/file37213/issue11145_2.patch

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

> Just curious, is there a reason why couldn't be in the same way?

Old asserts depend on user code, new asserts check internal consistency.

--

___
Python tracker 

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



[issue22067] time_test fails after strptime()

2014-11-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
nosy: +belopolsky, pitrou

___
Python tracker 

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



[issue22891] code removal from urllib.parse.urlsplit()

2014-11-17 Thread Berker Peksag

Changes by Berker Peksag :


--
nosy: +orsenthil
stage:  -> patch review
title: [patch]: code removal from urllib.parse.urlsplit() -> code removal from 
urllib.parse.urlsplit()
versions:  -Python 2.7, Python 3.2, Python 3.3, Python 3.4, Python 3.6

___
Python tracker 

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



[issue22891] code removal from urllib.parse.urlsplit()

2014-11-17 Thread Senthil Kumaran

Senthil Kumaran added the comment:

Thanks for filing this. Does test cases pass after removal of those lines? (I 
will be surprised) and if the tests fail, then after analyzing it, this could 
only be considered a new change (thus change to made in latest python) in order 
not to break compatibility.

--

___
Python tracker 

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



[issue22892] Typo in Library's 'threading' module section

2014-11-17 Thread Martin Gignac

New submission from Martin Gignac:

There is an extraenous asterisk in the constructor description for class 
'threading.Thread' in section 17.1.2. "Thread Objects" of the 'threading' 
module in the Python Standard Library documenation.

(patch attached)

--
assignee: docs@python
components: Documentation
files: threading.rst.patch
keywords: patch
messages: 231284
nosy: docs@python, techstone
priority: normal
severity: normal
status: open
title: Typo in Library's 'threading' module section
versions: Python 3.4
Added file: http://bugs.python.org/file37214/threading.rst.patch

___
Python tracker 

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



[issue22892] Typo in Library's 'threading' module section

2014-11-17 Thread R. David Murray

R. David Murray added the comment:

Thanks for taking the time to make a report, but that is not a typo.  That 
asterisk indicates that daemon is a keyword only argument, and is standard 
python3 syntax.  You can see it if you follow the source link to the threading 
module.

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



[issue22892] Typo in Library's 'threading' module section

2014-11-17 Thread Martin Gignac

Martin Gignac added the comment:

Sorry for that. I've read up PEP 3102 and now understand what you meant.

Sorry for the noise.

--

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Armin Rigo

Armin Rigo added the comment:

+if (Py_REFCNT(result) == 1)
+buf[len] = '\0';

...and if the refcount is not equal to 1, then too bad, we won't null-terminate 
the string and hope that nobody crashes because of this.??

--

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

If the refcount is not equal to 1, we will copy the content to new null-
terminated string.

--

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Armin Rigo

Armin Rigo added the comment:

Ah, sorry.  Ok.  Now a different issue: the user-defined function can return an 
interned string.  If it has a refcount of 1, _PyString_FormatLong() will mutate 
it.  Then when we DECREF it, string_dealloc() will not find it any more in the 
interned dict and crash with a fatal error.

Note that I'm mostly having fun finding holes in delicate logic, like mutating 
strings in-place.  It would be much more simple to either (1) stop calling the 
user-defined functions and behave similarly to most other built-in types; or 
(2) stop trying to mutate that poor string in-place and always just create a 
new one. :-)

--

___
Python tracker 

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



[issue22889] set a timeout for DNS lookups

2014-11-17 Thread Kevin Burke

Kevin Burke added the comment:

Hi,
You are correct, there's no way to set it in the C API. Go works around this by 
resolving addresses in a goroutine. I was wondering if something similar would 
be possible in Python (for people who set a timeout in the interface).

--

___
Python tracker 

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



[issue22889] set a timeout for DNS lookups

2014-11-17 Thread R. David Murray

R. David Murray added the comment:

Oh, my apologies.  I totally missed your link to the go example when I first 
read your message.

Yes, Python supports the equivalent.  In the asyncio module, which is our 
closest equivalent to goroutines, the functionality exists implicitly: the base 
event loop has a getaddrinfo coroutine that is used for DNS lookup, and it is 
run in a separate thread to keep from blocking the event loop.  If you time out 
(wait_for with a timeout) a coroutine that ends up doing a DNS request, your 
wait_for call will time out whether or not the getaddrinfo DNS lookup has timed 
out.

Using asyncio isn't quite as simple as prefixing a function name with 'go', but 
it isn't all that hard, either.  Nevertheless, if you aren't using asyncio for 
the rest of your program, it probably makes more sense to write a function that 
launches a thread to do the getaddrinfo and does a wait on the thread with a 
timeout.  (But you might want to check out if asyncio applies to your overall 
problem.)

So yes, Python can do this, but I don't think it makes sense to build it in to 
the stdlib's socket module (say), since unlike go async and threading aren't 
part of the core language but are instead libraries themselves.  asyncio 
already has it built in.  For the thread based version, putting a recipe on one 
of the recipe sites might be good, if there isn't one already.

--
resolution:  -> rejected
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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Good catch! Here is a patch which fixes this issue too.

> (1) stop calling the user-defined functions and behave similarly to most 
> other built-in types;

This is done in 3.x.

> (2) stop trying to mutate that poor string in-place and always just create a 
> new one.

The patch can be simplified by removing 6 lines. But this will slow down 
integer formatting by few (about 2-7) percents in worst case. Not a big deal.

--
Added file: http://bugs.python.org/file37215/issue11145_3.patch

___
Python tracker 

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



[issue11145] '%o' % user-defined instance

2014-11-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


Added file: http://bugs.python.org/file37216/issue11145_3_simpler.patch

___
Python tracker 

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



[issue22536] subprocess should include filename in FileNotFoundError exception

2014-11-17 Thread Akira Li

Akira Li added the comment:

I can confirm that without the patch the filename attribute is None
despite being mentioned in strerror.

Travis, you should use `orig_executable` instead of `args[0]` to cover:

  subprocess.call("exit 0", shell=True, executable='/nonexistent bash')

case. 

And use `cwd` if `child_exec_never_called`, to be consistent with the error 
message (see if/else statements above the raise statement).

It seems appropriate to set filename even if errno is not ENOENT
but to be conservative, you could provide filename iff `err_msg` is also 
changed i.e., iff errno is ENOENT.

--
nosy: +akira

___
Python tracker 

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



[issue20662] Pydoc doesn't escape parameter defaults in html

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Here is a patch which fixes this issue. Html formatting was broken by 
issue19674.

--
keywords: +patch
nosy: +larry
stage:  -> patch review
versions: +Python 3.5
Added file: http://bugs.python.org/file37217/pydoc_escape_argspec.patch

___
Python tracker 

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



[issue20662] Pydoc doesn't escape parameter defaults in html

2014-11-17 Thread Larry Hastings

Larry Hastings added the comment:

LGTM

--

___
Python tracker 

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



[issue20450] hg touch fails on System Z Linux buildbot

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Seems it was misconfiguration issue and it is fixed now.

--
resolution:  -> out of date
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




[issue18688] Document undocumented Unicode object API

2014-11-17 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
versions: +Python 3.5 -Python 3.3

___
Python tracker 

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



[issue22536] subprocess should include filename in FileNotFoundError exception

2014-11-17 Thread Akira Li

Akira Li added the comment:

If the_oserror.filename is not None then str(the_oserror) appends the
filename twice:

  [Errno 2] No such file or directory: 'nonexistent': 'nonexistent'

You could remove `err_msg += ':' ...` statements to avoid the
repeatition. It may break the code that uses strerror attribute. But
exception error messages are explicitly excluded from backward
compatibility considirations therefore it might be ok to break it
here. I can't find the reference so it should probably be resolved as a
new issue (independent from providing the filename attribute value).

--

___
Python tracker 

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



[issue1038591] Python 2.3+ socket._fileobject handles EAGAIN with data loss

2014-11-17 Thread Craig

Craig added the comment:

Surely if there is data loss this *has* to be fixed in 2.x?
I'm seeing this a *lot* using Twisted which, I believe isn't fully 3.x ported 
yet, so we have to support 2.x for now.

--
nosy: +craigemery

___
Python tracker 

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



[issue1038591] Python 2.3+ socket._fileobject handles EAGAIN with data loss

2014-11-17 Thread Antoine Pitrou

Antoine Pitrou added the comment:

The simple fact of the matter is that socket.makefile() has never worked for 
non-blocking sockets on 2.x. I doubt Twisted would be so broken as to use it in 
that context, but if that's the case, you should report a bug to them. If it's 
your own code, just use the socket directly (and call recv() and friends).

3.x should work fine, in that read() will return a short read (or None if 
nothing could be read before EAGAIN). Still, more complex calls such as 
readline() may still give incorrect results.

--
resolution:  -> wont fix
status: languishing -> closed

___
Python tracker 

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



[issue1038591] Python 2.3+ socket._fileobject handles EAGAIN with data loss

2014-11-17 Thread Antoine Pitrou

Antoine Pitrou added the comment:

(closed as won't fix, sorry)

--

___
Python tracker 

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



[issue20662] Pydoc doesn't escape parameter defaults in html

2014-11-17 Thread Roundup Robot

Roundup Robot added the comment:

New changeset cf2e424e0413 by Serhiy Storchaka in branch '3.4':
Issue #20662: Argspec now is escaped in html output of pydoc.
https://hg.python.org/cpython/rev/cf2e424e0413

New changeset 1855b5c3da61 by Serhiy Storchaka in branch 'default':
Issue #20662: Argspec now is escaped in html output of pydoc.
https://hg.python.org/cpython/rev/1855b5c3da61

--
nosy: +python-dev

___
Python tracker 

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



[issue22888] ensurepip and distutils' build_scripts fails on Windows when path to Python contains accented characters

2014-11-17 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> On Windows, shouldn't copy_scripts use UTF-8 instead of os.fsencode
> (MBCS)? The Python launcher executes the shebang line on Windows, and 
> it defaults to UTF-8 if a script doesn't have a BOM.

Good catch! It seems you're right. Do you want to provide a patch + tests?

--
nosy: +pitrou

___
Python tracker 

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



[issue22888] ensurepip and distutils' build_scripts fails on Windows when path to Python contains accented characters

2014-11-17 Thread Antoine Pitrou

Changes by Antoine Pitrou :


--
stage:  -> needs patch
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



[issue20662] Pydoc doesn't escape parameter defaults in html

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thanks for the review Larry.

There is related minor issue. The formatvalue method is no longer used in 
HTMLDoc. This can break user code which inherits HTMLDoc and overrides 
formatvalue.

--
assignee:  -> serhiy.storchaka
resolution:  -> fixed
stage: patch review -> 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



[issue22893] Idle: __future__ does not work in startup code.

2014-11-17 Thread Terry J. Reedy

New submission from Terry J. Reedy:

https://stackoverflow.com/questions/26977236/how-can-i-use-future-division-in-the-idle-startup-file
 report what seems like possibly fixable perhaps buggy behavior with respect to 
__future__ imports.  More investigation is needed.

Any change here might interact with #5233 IDLE: exec IDLESTARTUP/PYTHONSTARTUP 
on restart

--
messages: 231304
nosy: terry.reedy
priority: normal
severity: normal
stage: needs patch
status: open
title: Idle: __future__ does not work in startup code.
type: behavior

___
Python tracker 

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



[issue22894] unittest.TestCase.subTest causes all subsequent tests to be skipped in failfast mode

2014-11-17 Thread Trey Cucco

New submission from Trey Cucco:

When running a test suite with the -f flag (--failfast), unittest seems to stop 
running tests once it exits a with self.subTest block.

In the attached script, run it without -f and test_b will run and fail. Run it 
with the -f flag and only the test_a test will run. test_b will not run and no 
errors will be reported.

I noticed this bug in 3.4.1 on OS X

--
components: Macintosh, Tests
files: utbug.py
messages: 231305
nosy: Trey.Cucco, ned.deily, ronaldoussoren
priority: normal
severity: normal
status: open
title: unittest.TestCase.subTest causes all subsequent tests to be skipped in 
failfast mode
type: behavior
versions: Python 3.4
Added file: http://bugs.python.org/file37218/utbug.py

___
Python tracker 

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



[issue22894] unittest.TestCase.subTest causes all subsequent tests to be skipped in failfast mode

2014-11-17 Thread Ned Deily

Changes by Ned Deily :


--
components:  -Macintosh
nosy: +ezio.melotti, michael.foord, rbcollins -ned.deily, ronaldoussoren

___
Python tracker 

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



[issue19895] Cryptic error when subclassing multiprocessing classes

2014-11-17 Thread Dan O'Reilly

Dan O'Reilly added the comment:

This is basically the same thing that issue21367 is reporting.

--
nosy: +dan.oreilly

___
Python tracker 

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



[issue22140] "python-config --includes" returns a wrong path (double prefix)

2014-11-17 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Do you want to provide a patch?

--
components: +Build -Demos and Tools
nosy: +serhiy.storchaka
stage:  -> needs patch

___
Python tracker 

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