[issue26858] setting SO_REUSEPORT fails

2017-09-16 Thread Philip Jenvey

Philip Jenvey added the comment:

Note that this isn't an android specific issue: See issue19901, and 
9791c5d55f52 for an appropriate solution patch.

(Renaming title)

--
nosy: +pjenvey
title: android: setting SO_REUSEPORT fails -> setting SO_REUSEPORT fails

___
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue26858>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26800] Don't accept bytearray as filenames part 2

2016-04-20 Thread Philip Jenvey

Philip Jenvey added the comment:

Thanks Serhiy, I did not see the python-dev thread. This coincidentally came up 
recently in pypy3.

+1 for some kind of deprecation period needed

--

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26800>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26754] PyUnicode_FSDecoder() accepts arbitrary iterable

2016-04-18 Thread Philip Jenvey

Philip Jenvey added the comment:

See issue26800 for reasoning to go with #4

--
nosy: +pjenvey

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26754>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26800] Don't accept bytearray as filenames part 2

2016-04-18 Thread Philip Jenvey

New submission from Philip Jenvey:

Basically a reopen of the older issue8485 with the same name. It was decided 
there to drop support for bytearray filenames -- partly because of the 
complexity of handling buffers but it was also deemed to just not make much 
sense.

This regressed or crept back into the posix module with the big path_converter 
changes for 3.3:

https://hg.python.org/cpython/file/ee9921b29fd8/Lib/test/test_posix.py#l411

IMHO this functionality should be deprecated/removed per the original 
discussion, or does someone want to reopen the debate?

The os module docs (and path_converter's own docs) explicitly advertise 
handling of str or bytes, not bytearrays or buffers. Even os.fsencode rejects 
bytearrays/buffers.

Related to issue26754 -- further inconsistencies around filename handling

--
assignee: larry
components: Interpreter Core
keywords: 3.3regression
messages: 263694
nosy: Ronan.Lamy, haypo, larry, pitrou, pjenvey, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Don't accept bytearray as filenames part 2
type: behavior
versions: Python 3.6

___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26800>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19725] Richer stat object

2014-12-08 Thread Philip Jenvey

Philip Jenvey added the comment:

I can't find the paper trail of what I originally thought was a consensus or 
even that many clear pronouncements about it, but I recall Nick being 
originally opposed to it but he later changed his mind, you can see his 
approval here:

https://mail.python.org/pipermail/python-dev/2013-May/125809.html

'It's also quite likely the rich stat object API will be pursued for 3.5'

https://mail.python.org/pipermail/python-dev/2013-November/130582.html

https://mail.python.org/pipermail/python-dev/2013-November/130588.html

Antoine seems ok w/ it, encouraging others to make it happen:

https://mail.python.org/pipermail//python-dev/2013-September/128708.html

You can probably find a bit more discussion within those threads

--

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



[issue21173] WeakKeyDictionary.__len__ fragile w/ _IterationGuards

2014-04-07 Thread Philip Jenvey

New submission from Philip Jenvey:

len() on WeakKeyDictionarys can fail with ValueErrors when _IterationGuards are 
kept alive

Attached is a test showing this:

==
ERROR: test_weak_keys_len_destroy_while_iterating (__main__.MappingTestCase)
--
Traceback (most recent call last):
  File Lib/test/test_weakref.py, line 1336, in 
test_weak_keys_len_destroy_while_iterating
self.assertEqual(len(dict), 0)
ValueError: __len__() should return = 0


One probably shouldn't keep them alive like this, but __len__ shouldn't be 
blowing up either. On non ref counting GC platforms this situation is easier to 
trigger unintentionally

--
components: Library (Lib)
messages: 215716
nosy: pitrou, pjenvey
priority: normal
severity: normal
status: open
title: WeakKeyDictionary.__len__ fragile w/ _IterationGuards
type: behavior
versions: Python 3.2, Python 3.3, Python 3.4

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



[issue21173] WeakKeyDictionary.__len__ fragile w/ _IterationGuards

2014-04-07 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
keywords: +patch
Added file: http://bugs.python.org/file34751/issue21173-test.diff

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



[issue19725] Richer stat object

2013-11-22 Thread Philip Jenvey

New submission from Philip Jenvey:

With discussion of the new Pathlib API there's been suggestion (and maybe even 
already consensus) that some of the convenience APIs provided by it should 
exist on stat result objects.

It's maybe too late for 3.4, but let's track exactly what additions are wanted

--
components: Library (Lib)
messages: 203892
nosy: ncoghlan, pitrou, pjenvey
priority: normal
severity: normal
status: open
title: Richer stat object
type: enhancement
versions: Python 3.4

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



[issue19516] segmentation fault using a dict as a key

2013-11-06 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +ned.deily

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



[issue14805] Support display of both __cause__ and __context__

2013-04-20 Thread Philip Jenvey

Philip Jenvey added the comment:

and the code module (after #17442 is resolved)

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14805
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17442] code.InteractiveInterpreter doesn't display the exception cause

2013-04-18 Thread Philip Jenvey

Philip Jenvey added the comment:

PyPy's fixed this here:

https://bitbucket.org/pypy/pypy/commits/1341a432e134

The tests just need to be adapted to the stdlib test suite

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17442
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17442] code.InteractiveInterpreter doesn't display the exception cause

2013-03-16 Thread Philip Jenvey

New submission from Philip Jenvey:

The code module claims to emulate Python's interactive interpreter but it fails 
to emulate displaying of the exception cause.

It can utilize traceback._iter_chain to do this (see traceback.print_exception)

--
components: Library (Lib)
messages: 184355
nosy: pjenvey
priority: normal
severity: normal
status: open
title: code.InteractiveInterpreter doesn't display the exception cause
type: behavior
versions: Python 3.2, Python 3.3, Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17442
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17032] Misleading error message: global name 'X' is not defined

2013-02-19 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17032
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17198] dbm.whichdbm references non-existent 'ndbm'

2013-02-12 Thread Philip Jenvey

New submission from Philip Jenvey:

There are a couple references to an 'ndbm' variable/module in this function on 
Python 3.2 and above (and just one reference on default). It appears to be 
leftover from the 3.x reworking of this module

--
components: Library (Lib)
messages: 181990
nosy: georg.brandl, pjenvey
priority: normal
severity: normal
stage: needs patch
status: open
title: dbm.whichdbm references non-existent 'ndbm'
type: behavior
versions: Python 3.2, Python 3.3, Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17198
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15881] multiprocessing 'NoneType' object is not callable

2013-01-22 Thread Philip Jenvey

Philip Jenvey added the comment:

Targeting this for 2.7.4. If Alexander doesn't get to it, ping me and I'll do it

--
nosy: +benjamin.peterson, georg.brandl, larry, pjenvey
priority: normal - release blocker

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15881
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16835] Update PEP 399 to allow for test discovery

2013-01-02 Thread Philip Jenvey

Philip Jenvey added the comment:

Hey Ezio, you forgot to attach the patch

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16835
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16651] Find out what stdlib modules lack a pure Python implementation

2012-12-21 Thread Philip Jenvey

Philip Jenvey added the comment:

The guidelines for this are in PEP 399. Basically, adding 'accelerated' 
implementations when necessary isn't a bad thing as long as there are pure 
Python equivalents (unless it's a special case) and both are tested.

issue14373's latest patch seems to be following the PEP

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16651
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16651] Find out what stdlib modules lack a pure Python implementation

2012-12-14 Thread Philip Jenvey

Philip Jenvey added the comment:

PyPy had a pure python itertools until recently (it's been deleted):

https://bitbucket.org/pypy/pypy/src/c1aa74c06e86/lib_pypy/itertools.py?at=py3k

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16651
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16651] Find out what stdlib modules lack a pure Python implementation

2012-12-10 Thread Philip Jenvey

Philip Jenvey added the comment:

zipimport

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16651
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15031] Split .pyc parsing from module loading

2012-12-03 Thread Philip Jenvey

Philip Jenvey added the comment:

From the perspective of Jython we'd want the easiest way to hook into this as 
possible of course, but I think that overriding marshal to handle a $py.class 
or whatever format would be a misappropriation of the marshal module

Jython actually has a slow, preliminary .pyc bytecode interpreter, so it needs 
marshal the way it is. Correct me if I'm wrong but I think the overriding a 
method of a Loader option could allow you to even have the import system 
support .pyc *and* $py.class at the same time in Jython (just by addding 
another Loader into the mix)

I'm not sure anyone would ever want to do that in practice, but it's probably 
worth considering.

Overriding a Loader method is probably the 'most work' for alternative 
implementations, right? But it's still fairly trivial

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15031
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16585] surrogateescape broken w/ multibytecodecs' encode

2012-11-30 Thread Philip Jenvey

New submission from Philip Jenvey:

surrogateescape claims to be implemented by all standard Python codecs

http://docs.python.org/3/library/codecs.html#codec-base-classes

However it fails w/ multibytecodecs on encode:

Python 3.2.3+ (3.2:eb999002916c, Oct 26 2012, 16:11:03) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type help, copyright, credits or license for more information.
 \u30fb.encode('gb18030')
b'\x819\xa79'
 \u30fb\udc80.encode('gb18030', 'surrogateescape')
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: encoding error handler must return (unicode, int) tuple

The problem being that multibytecodec.c forces error handler return results to 
always be unicode and surrogateescape returns bytes here.

(surrogatepass also similarly returns bytes but it claims to be utf-8 only)

The error handler spec seems to imply that error handlers should always return 
unicode, because The encoder will encode the replacement

http://docs.python.org/3/library/codecs.html#codecs.register_error

but obviously that's not really the case: some codecs special case bytes 
results and copy them directly to the output, e.g.:

http://hg.python.org/cpython/file/ce3f0399ea33/Objects/unicodeobject.c#l6305

--
components: Interpreter Core
messages: 176711
nosy: pjenvey
priority: normal
severity: normal
status: open
title: surrogateescape broken w/ multibytecodecs' encode
versions: Python 3.2, Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16585
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16389] re._compiled_typed's lru_cache causes significant degradation of the mako_v2 bench

2012-11-02 Thread Philip Jenvey

New submission from Philip Jenvey:

#9396 replaced a few caches in the stdlib w/ lru_cache, this made the mako_v2 
benchmark on Python 3 almost 3x slower than 2.7

The benchmark results are good now that Mako was changed to cache the re 
itself, but the problem still stands that lru_cache seems to hurt the perf of 
inline res compared to 2.7. The fix for Mako did not affect the 2.7 benchmark 
numbers

See more info here:

http://mail.python.org/pipermail/python-dev/2012-November/122521.html

--
components: Library (Lib)
messages: 174550
nosy: brett.cannon, ncoghlan, pjenvey, rhettinger, zzzeek
priority: normal
severity: normal
status: open
title: re._compiled_typed's lru_cache causes significant degradation of the 
mako_v2 bench
type: performance
versions: Python 3.2, Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16389
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16390] re compilation slow in Python 3.3 due to functools.lru_cache overhead

2012-11-02 Thread Philip Jenvey

Philip Jenvey added the comment:

Sorry Brett, beat you to it w/ #16389 =P

--
resolution:  - duplicate
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16390
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16336] Check input in surrogatepass error handler

2012-10-29 Thread Philip Jenvey

Philip Jenvey added the comment:

Thanks for picking this and the warning/slowdown up, Serhiy. The patch LGTM, 
for whatever that's worth =]

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16336
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Philip Jenvey

New submission from Philip Jenvey pjen...@underboss.org:

The __length_hint__ optimization was broken a while ago for many iterators due 
to a bug introduced in 44c090c74202. It only accepts longs as valid hints, not 
ints

This affects 2.6 too (but that's in security-only fix mode), but not 3.x

--
assignee: pjenvey
messages: 165474
nosy: pjenvey
priority: normal
severity: normal
status: open
title: _PyObject_LengthHint only accepts longs
type: performance
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15354
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

attached a fix for review

--
keywords: +patch
Added file: http://bugs.python.org/file26383/lengthhint-fix.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15354
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com




[issue14895] test_warnings.py EnvironmentVariableTests is a bad test

2012-05-23 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Jython's sys.warnoptions should probably just contain strs instead of unicode. 
Otherwise I suspect unicode values could break the warnings module's usage of it

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14895
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14609] can't modify sys.modules during import with importlib

2012-04-17 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

__import__ needs the actual module on hand so it can e.g. attach it to its 
parent module

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14609
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14126] Speed up list comprehensions by preallocating the list where possible

2012-03-03 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

iter(range(1)) should also see a speedup because range's iter supports 
__length_hint__

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14126
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14161] python2 file __repr__ does not escape filename

2012-03-02 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

I think you want to decref the result of PyObject_Repr after the fact, too

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14161
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13405] Add DTrace probes

2012-02-29 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy:  -pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13405
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13405] Add DTrace probes

2012-02-28 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Actually 10.5 was the last PowerPC release

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13405
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13988] Expose the C implementation of ElementTree by default when importing ElementTree

2012-02-13 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

DeprecationWarnings aren't that annoying anymore now that they're silent by 
default. It should at least have a PendingDeprecationWarning

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13988
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13903] New shared-keys dictionary implementation

2012-01-29 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13903
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13575] old style classes still alive

2011-12-15 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Is mro_internal's second call to type_mro_modified still needed? Its comment 
makes me suspect that it's not:

type_mro_modified(type, type-tp_mro);
/* corner case: the old-style super class might have been hidden
   from the custom MRO */
type_mro_modified(type, type-tp_bases);

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13575
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13402] Document absoluteness of sys.executable

2011-12-14 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

sys.executable can be None on Jython (and I believe IronPython) when ran in an 
'embedded' mode

--
nosy: +dino.viehland, pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13402
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13597] Improve documentation of stdout/stderr buffering in Python 3.x

2011-12-13 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

I'm surprised to hear that stderr is line buffered by default. Historically 
stderr is never buffered (at least on POSIX) and for good reason: errors should 
be seen immediately

Was this an oversight in migrating stdin/out/err to the new io module?

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13597
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13512] ~/.pypirc created insecurely

2011-12-01 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

2.5 is done 
http://mail.python.org/pipermail/python-committers/2011-October/001844.html

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13512] ~/.pypirc created insecurely

2011-11-30 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Something along these lines (untested) should do it. 2.6 and 3.x need the fix 
as well

--
keywords: +patch
nosy: +pjenvey
Added file: http://bugs.python.org/file23824/pypirc-secure.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13512] ~/.pypirc created insecurely

2011-11-30 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

It probably still needs to catch OSErrors which my patch doesn't do

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13512
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1724822] provide a shlex.split alternative for Windows shell syntax

2011-03-05 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

The code I linked to above implements those semantics in pure Python. It 
follows Microsoft's Parsing C Command-Line Arguments rules like 
CommandLineToArgvW does

Here's updated links, the older links seemed to have broken:

https://fisheye3.atlassian.com/browse/jython/trunk/jython/Lib/subprocess.py?r=6636#to566

tests: 
https://fisheye3.atlassian.com/browse/jython/trunk/jython/Lib/test/test_subprocess_jy.py?r=6464#to41

This code is basically the inverse of subprocess's list2cmdline

I don't mind incorporating this code into the stdlib, but we need to figure out 
where it would go. There was a discussion on stdlib-sig last year related to 
this topic, about the need for quoting and unquoting command lines.

We have some of this functionality for posix systems scattered throughout shlex 
and the pipes module, and then there's subprocess.list2cmdline. I think we 
could use a new module with all this functionality in one place.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1724822
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7334] ElementTree: file locking in Jython 2.5 (OSError on Windows)

2010-12-24 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Florent, any chance of signing off on this for 3.2? I was waiting for the patch 
to go through your authorized elementtree fork

--
assignee: pjenvey - flox

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7334
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8685] set(range(100000)).difference(set()) is slow

2010-11-30 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8685
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10073] calendar.isleap() not checking parameter type

2010-10-18 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy:  -pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10073
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10073] calendar.isleap() not checking parameter type

2010-10-12 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Another option is to wrap the operations in a try/except. When a TypeError is 
raised have it throw a new TypeError with an improved error message and the 
original chained to it

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10073
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9988] test_warnings fails with PYTHONFSENCODING=latin-1 on UNIX/BSD

2010-09-29 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9988
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9988] test_warnings fails with PYTHONFSENCODING=latin-1 on UNIX/BSD

2010-09-29 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

It sounds like you had PYTHONWARNINGS using the fs encoding before r84694, but 
reverted it due to bootstrapping issues.

Indeed, the fs encoding isn't initialized until later in Py_InitializeEx. Maybe 
the PYTHONWARNINGS code should be moved there instead?

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9988
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9992] Command line arguments are not correctly decoded if locale and fileystem encodings are different

2010-09-29 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9992
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8632] subprocess doesn't handle Windows built-in commands as os.system() does

2010-05-05 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

shell commands don't work because you're not specifying the shell=True argument 
to Popen. This is covered in the subprocess Replacing os.system documentation

--
nosy: +pjenvey
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8632
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-14 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

py3k should be taken care of as of r80066+r80075

--
resolution: accepted - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-11 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

The pending patch for py3k fixes the modification of the env value (trunk 
already has a fix for that).

That patch is also doing the conversion to wchar_t via the char2wchar function 
now, with that reusing a single buffer seems out of the question

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7334] ElementTree: file locking in Jython 2.5 (OSError on Windows)

2010-04-09 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Patch with tests (which can only really test it on Windows) here

http://bitbucket.org/pjenvey/et-2009-provolone/changeset/8292a06090a3/

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7334
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8347] string capitalize erroneously lower-case any non-first letters

2010-04-08 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

S.capitalize() - string

Return a copy of the string S with only its first character
capitalized.

You've misunderstood the docs, only the first character is indeed capitalized. 
You want string.capwords instead

--
nosy: +pjenvey
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8347
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-07 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

I committed a somewhat different version of this patch to py3k to handle the 
warn options now calling for wchars, but this needs more work. Some of the 
buildbots are unhappy

Seems like the py3k version either needs to fully decode the env values to a 
unicode obj via the file system encoding (which I doubt is initialized at this 
point)/surrogateescape, or use something along the lines of char2wchar in 
python.c

--
assignee:  - pjenvey
resolution: fixed - accepted
status: closed - open

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-07 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Here's a patch for py3k using the same char2wchar as the argv decoder for 
posix, and better windows handling. Plus an additional nonascii value test. 
Patch is against r79980 for clarity

--
Added file: http://bugs.python.org/file16810/issue7301-py3k.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-06 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Looks good to me. Updated patch with a couple whitespace changes

--
Added file: http://bugs.python.org/file16791/issue7301-2.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2010-04-06 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

applied in r79878 - r79881, thanks!

--
resolution: accepted - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7697] os.getcwd() should raise UnicodeDecodeError for arbitrary bytes

2010-01-13 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Right, this is an intentional change in behavior in Python 3.1, non-decodable 
characters are now decoded to utf8b (via the surrogateescape error handler). 
The unicode string returned from getcwd furthermore can be passsed around to 
other fs functions, they simply encode back to the original bytes via 
surrogateescape on POSIX

See PEP 383

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7697
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7177] Unclear warning for subprocess.call

2009-12-02 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Improved in r76640 / r76641 to explicitly mention this applies to 
stdout/err=PIPE

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7177
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7349] StringIO.StringIO, io.BytesIO, and io.StringIO accept None in places where other file-like objects don't

2009-11-18 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

The original pure-python impl. of io accepted None, and still does. This 
is a regression in C impl.

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7349
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7333] Add initgroups to the posix/os modules

2009-11-16 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

The test should skip when not hasattr(os, 'initgroups') since it's 
optional

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7333
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1757126] [PATCH] Fix ptcp154 encoding cyrillic_asian alias

2009-11-16 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

fixed in r76337, r76338

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1757126
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7334] XML file locking in Jython 2.5 (OSError on Windows)

2009-11-16 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
assignee:  - pjenvey
nosy: +pjenvey
versions: +Python 2.7, Python 3.2 -Python 2.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7334
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2009-11-13 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

test_warnings is probably the best place since test_cmd_line ignores 
environment variables

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7301] Add environment variable $PYTHONWARNINGS

2009-11-10 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7240] subprocess.Popen.stdout.flush fails os OS-X 10.6.1

2009-11-03 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7240
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7240] subprocess.Popen.stdout.flush fails os OS-X 10.6.1

2009-10-30 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

Why are you flushing stdout? It's read-only and flush is for writing. This 
behavior is dependent on the underlying platform's fflush, which really 
*should* be raising EBADF when fflushing a read only file, anyway

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7240
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7146] [PATCH] platform.uname()[4] returns 'amd64' on Windows and 'x86-64' on Linux

2009-10-15 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +lemburg, loewis

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7146
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7120] 2.6.4rc1 regression

2009-10-13 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

App engine shows up after every import statement, so it must have some 
kind of import hook -- which can do evil things

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7120
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7120] 2.6.4rc1 regression

2009-10-13 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +vinay.sajip

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7120
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1724822] provide a shlex.split alternative for Windows shell syntax

2009-10-10 Thread Philip Jenvey

Philip Jenvey pjen...@underboss.org added the comment:

FYI I've implemented a Windows command line parser for use by subprocess 
on Jython, it's available here:

http://fisheye3.atlassian.com/browse/jython/trunk/jython/Lib/subprocess.
py?r=6636#l554

tests:

http://fisheye3.atlassian.com/browse/jython/trunk/jython/Lib/test/test_s
ubprocess_jy.py?r=6464#l41

like shlex, it wasn't built to handle ;  || to join multiple commands 
as #1521950 requests. But other than that it's complete

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1724822
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6990] threading.local subclasses don't cleanup their state and it gets recycled

2009-09-24 Thread Philip Jenvey

New submission from Philip Jenvey pjen...@users.sourceforge.net:

When threading.local subclasses are cleared during a reference cycle the 
local's internal key is nulled before the local is deallocated. That's a 
problem because local only deletes its state (ldicts) from threads 
during deallocation, and doesn't do so at all when its key is null.

So leaving ldicts around is one thing, but what's worse is they can be 
recycled by new local objects later -- since ldicts are mapped to 
threadstates by said key, and said key is based on the local's pointer. 
If a new local is malloced at the old one's address it can end up with 
the original's ldicts (depending on which thread it's allocated from).

Attached is a test against trunk showing this. Should we delete the 
ldicts during clear, recreate the key during dealloc, or something else?

--
components: Interpreter Core
files: derived_local_cycle_dealloc.diff
keywords: patch
messages: 93099
nosy: amaury.forgeotdarc, pjenvey
severity: normal
status: open
title: threading.local subclasses don't cleanup their state and it gets recycled
type: security
versions: Python 2.4, Python 2.5, Python 2.6, Python 2.7, Python 3.0, Python 
3.1, Python 3.2
Added file: http://bugs.python.org/file14969/derived_local_cycle_dealloc.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6990
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5329] os.popen2 and os.popen3 in python 2.6 incompatible with os.popen* in python 2.5

2009-09-03 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

The subprocess docs (in Doc/library/subprocess.rst and the module itself) 
need to also reflect this change

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5329
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5329] os.popen2 and os.popen3 in python 2.6 incompatible with os.popen* in python 2.5

2009-09-03 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

Sorry, I meant the docs describing how to convert os.popen* calls to 
subprocess calls. They assume the shell arg is always True regardless of 
the cmd arg type. Those docs are probably the original source of this bug

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5329
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6301] Error in tutorial section 7.2

2009-06-18 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

Jython 2.5 behaves in the same way

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6301
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6226] Inconsistent 'file' vs 'stream' kwarg in pprint, other stdlibs

2009-06-06 Thread Philip Jenvey

New submission from Philip Jenvey pjen...@users.sourceforge.net:

It'd be nice to eventually standardize on the kwarg name used for basic 
file-like args in the stdlib. print, warnings.showwarning and some 
others take a file= argument whereas pprint, getpass.getpass take 
stream=

print and pprint in particular should match -- though they do have a 
different option set, when you're using the same options this 
consistency would ease replacing:

print(obj, file=sys.stderr)
with
pprint(obj, stream=sys.stderr)

--
components: Library (Lib)
messages: 89020
nosy: pjenvey
severity: normal
status: open
title: Inconsistent 'file' vs 'stream' kwarg in pprint, other stdlibs
type: feature request

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6226
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6217] Add _io._TextIOWrapper.errors

2009-06-05 Thread Philip Jenvey

New submission from Philip Jenvey pjen...@users.sourceforge.net:

_pyio.TextIOWrapper provides the encoding and associated errors values, 
but _io._TextIOWrapper only provides encoding. Patch adds errors and has 
it show up in repr in both places, against py3k

--
components: IO
files: textiowrapper-errors.diff
keywords: patch
messages: 88986
nosy: pitrou, pjenvey
severity: normal
status: open
title: Add _io._TextIOWrapper.errors
type: behavior
versions: Python 2.7, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file14201/textiowrapper-errors.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6217
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1704474] optparse tests fail under Jython

2009-06-01 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

This looks like it was against Jython 2.2? Jython 2.5 passes 2.5's 
test_optparse with only fixing __builtins__ and disabling the weakref test

So uses of __builtins__ should should be importing __builtin__ and use 
that instead. sys.platform.startswith('java') should be 
test_support.is_jython instead. And on 2.6/3.2 you can now decorate 
test_refleak with @test_support.impl_check('Relies on sys.getrefcount', 
cpython=True) to skip it

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1704474
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1559298] test_popen fails on Windows if installed to Program Files

2009-05-25 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

subprocess also needs this fix applied

Does the w9xopen command line below not need this?

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1559298
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6107] Subprocess.Popen output fails on Windows

2009-05-25 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

Exactly what command line are you passing to subprocess? Does stderr 
contain anything?

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6107
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6082] os.path.sameopenfile reports that standard streams are the same

2009-05-21 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

They are the same file, namely your tty

Python 2.6 (r26:66714, Oct  8 2008, 22:16:30) 
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type help, copyright, credits or license for more information.
 import os, sys
 [os.ttyname(fp.fileno()) for fp in sys.stdin, sys.stdout, sys.stderr]
['/dev/ttys002', '/dev/ttys002', '/dev/ttys002']

--
nosy: +pjenvey

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6082
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue4351] [PATCH] Better stacklevel for GzipFile.filename DeprecationWarning

2009-05-07 Thread Philip Jenvey

Philip Jenvey pjen...@users.sourceforge.net added the comment:

this and more applied in r72458

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue4351
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1757126] [PATCH] Fix ptcp154 encoding cyrillic_asian alias

2009-02-04 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@users.sourceforge.net:


--
title: Fix ptcp154 encoding cyrillic_asian alias - [PATCH] Fix ptcp154 
encoding cyrillic_asian alias

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1757126
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue4702] [PATCH] msvc9compiler raises IOError when no compiler found instead of DistutilsError

2008-12-19 Thread Philip Jenvey

New submission from Philip Jenvey pjen...@users.sourceforge.net:

Python 2.6's new msvc9compiler misbehaves when it can't find a compiler 
(actually a utility of the missing compiler) in its query_vcvarsall() -- 
it raises an IOError instead of a typical distutils error

build tools expect a consistent set of potential exceptions from the 
compiler suites, such as CCompilerError, DistutilsExecError, 
DistutilsPlatformError, etc. Distributions like simplejson, Genshi, etc. 
look for these errors when compiling their optional C extension speedups 
as an indication that there's no compiler, and to fallback to their pure 
python counterparts

An IOError in this case just doesn't make sense

This patch changes them to DistutilsExecErrors. Maybe it should be 
DistutilsPlatformError -- whatever, just not IOError

I think this should be included in 2.6.2

--
components: Distutils
files: msvc9_ioerror.diff
keywords: patch
messages: 78070
nosy: pjenvey
severity: normal
status: open
title: [PATCH] msvc9compiler raises IOError when no compiler found instead of 
DistutilsError
type: behavior
versions: Python 2.6
Added file: http://bugs.python.org/file12404/msvc9_ioerror.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue4702
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue4351] [PATCH] Better stacklevel for GzipFile.filename DeprecationWarning

2008-11-18 Thread Philip Jenvey

New submission from Philip Jenvey [EMAIL PROTECTED]:

This should be a stacklevel of 2 so we're told who accessed the attribute

--
components: Library (Lib)
files: gzip-deprecation_r67276.diff
keywords: patch
messages: 76031
nosy: pjenvey
severity: normal
status: open
title: [PATCH] Better stacklevel for GzipFile.filename DeprecationWarning
type: behavior
versions: Python 2.6
Added file: http://bugs.python.org/file12051/gzip-deprecation_r67276.diff

___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue4351
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3888] [PATCH] Document more deprecated modules in What's New in Python 2.6

2008-09-17 Thread Philip Jenvey

New submission from Philip Jenvey [EMAIL PROTECTED]:

The What's New doc is missing a few of these, I've added the ones 
mentioned in PEP 361 that weren't already there.

I also corrected popen2's entry; it's always deprecated in 2.6, not just 
in the 3.0 warnings mode

--
assignee: georg.brandl
components: Documentation
files: whatsnew-depmod2.6-r66484.diff
keywords: patch
messages: 73323
nosy: georg.brandl, pjenvey
severity: normal
status: open
title: [PATCH] Document more deprecated modules in What's New in Python 2.6
versions: Python 2.6
Added file: http://bugs.python.org/file11508/whatsnew-depmod2.6-r66484.diff

___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3888
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3386] distutils.sysconfig.get_python_lib prefix argument broken

2008-07-16 Thread Philip Jenvey

New submission from Philip Jenvey [EMAIL PROTECTED]:

get_python_lib supports an optional prefix argument:

If 'prefix' is supplied, use it instead of sys.prefix or
sys.exec_prefix -- i.e., ignore 'plat_specific'.

However the NT and OS2 platforms don't use the prefix argument when 
specified.

This problem was brought up a while ago here: 
http://mail.python.org/pipermail/distutils-sig/2002-November/003099.html

Andrew (the OS2 maintainer) claimed in the thread that fixing this would 
break OS2, but I don't see how. All callers of get_python_lib in the 
stdlib don't specify a prefix anyway. Anyone calling it with a prefix 
and expecting it not to be used is broken.

--
components: Distutils
files: get_python_lib-r65033.diff
keywords: patch
messages: 69836
nosy: pjenvey
severity: normal
status: open
title: distutils.sysconfig.get_python_lib prefix argument broken
type: behavior
versions: Python 2.6, Python 3.0
Added file: http://bugs.python.org/file10917/get_python_lib-r65033.diff

___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3386
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3389] [PATCH] Allow custom logging Handlers in logging config files

2008-07-16 Thread Philip Jenvey

New submission from Philip Jenvey [EMAIL PROTECTED]:

Python 2.5 added support for specifying a custom logging Formatter class 
in logging configuration files. Handler classes can also be specified, 
but your choice is limited to classes that live in the logging module. 

A current workaround this is to manually add your custom Handler class 
to the logging module prior to loading the logging config file, but then 
you're no longer driving logging configuration purely from a config file 
(which is the entire point). This is particularly important for apps 
that are driven entirely from a config file that also includes logging 
information (such as Pylons applications)

The following patch will cause Handler classes to be resolved just like 
Formatter classes if the check for the Handler class in the logging 
module fails.

FYI this patch has been used in Paste (in particular for Pylons apps) 
for over a year so I consider it stable

--
components: Library (Lib)
files: logging-custom-Handler_r65033.diff
keywords: patch
messages: 69858
nosy: pjenvey, vsajip
severity: normal
status: open
title: [PATCH] Allow custom logging Handlers in logging config files
type: feature request
versions: Python 2.6, Python 3.0
Added file: http://bugs.python.org/file10921/logging-custom-Handler_r65033.diff

___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3389
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3386] [PATCH] distutils.sysconfig.get_python_lib prefix argument broken

2008-07-16 Thread Philip Jenvey

Changes by Philip Jenvey [EMAIL PROTECTED]:


--
title: distutils.sysconfig.get_python_lib prefix argument broken - [PATCH] 
distutils.sysconfig.get_python_lib prefix argument broken

___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3386
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue2750] Add simplejson to Python 2.6/3.0 standard library

2008-05-04 Thread Philip Jenvey

Philip Jenvey [EMAIL PROTECTED] added the comment:

Bob, all of the simplejson tests have actually been passing on Jython 
trunk -- at least up until recently when you added a couple tests that 
utilize the 2.4 decimal module.

I can also import simplejson.scanner with a recent build of pypy, so it at 
least has those sre imports you're using.

--
nosy: +pjenvey

__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue2750
__
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1703] getpass broken in Py3k: must flush()

2007-12-27 Thread Philip Jenvey

New submission from Philip Jenvey:

getpass (in particular _raw_input, used by unix_getpass and 
default_getpass) prints out a password prompt to a stream (by default 
stdout) but doesn't flush that stream. It assumes calling 
sys.stdin.readline() to read the password causes stdout to be flushed 
(probably a libc file buffering behavior)

This is a problem in Py3k where file buffering is done by Python; 
getpass needs to manually flush the stream it prints the prompt to. 
Otherwise the prompt isn't printed until after the password is entered 
e.g.:

Python 3.0a2 (py3k:59601, Dec 27 2007, 14:28:14) 
[GCC 4.1.3 20071209 (prerelease) (Debian 4.1.2-18)] on linux2
Type help, copyright, credits or license for more information.
 import getpass
 getpass.getpass()

no prompt is printed, i type 'foo\n', and only afterwards is the prompt 
printed

Password: 
'foo'


Windows doesn't use _raw_input so it wouldn't see this issue.

Attached is a patch to flush the stream. There's no getpass tests so I 
didn't get around to creating one for this issue. Ideally we'd test 
getpass via spawning a python subprocess and ensuring its I/O looked 
correct.

This was noticed on Jython as its file object is now based off Py3k's

--
components: Library (Lib)
files: getpass_flush-r59601.diff
messages: 59011
nosy: pjenvey
severity: normal
status: open
title: getpass broken in Py3k: must flush()
versions: Python 3.0
Added file: http://bugs.python.org/file9031/getpass_flush-r59601.diff

__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1703
__Index: Lib/getpass.py
===
--- Lib/getpass.py  (revision 59601)
+++ Lib/getpass.py  (working copy)
@@ -78,6 +78,7 @@
 prompt = str(prompt)
 if prompt:
 stream.write(prompt)
+stream.flush()
 line = sys.stdin.readline()
 if not line:
 raise EOFError
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1188] universal newlines doesn't identify CRLF during tell()

2007-09-21 Thread Philip Jenvey


Philip Jenvey
 added the comment:

make that against r58227

__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1188
__
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1188] universal newlines doesn't identify CRLF during tell()

2007-09-21 Thread Philip Jenvey

Changes by 
Philip Jenvey
:


--
type:  - behavior

__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1188
__
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1188] universal newlines doesn't identify CRLF during tell()

2007-09-21 Thread Philip Jenvey

New submission from 
Philip Jenvey
:

tell() will skip the next LF (after a CR sets f_skipnextlf) when 
universal newline support is enabled; essentially doing part of the work 
of read(). However it does not identify CRLF as a newline, as read() 
would, e.g.:

 open('/tmp/crlf', 'wb').write('CRLF\r\nEOF')
 fp = open('/tmp/crlf', 'U')
 fp.read()
'CRLF\nEOF'
 fp.newlines # correct when read()ing
'\r\n'
 fp = open('/tmp/crlf', 'U')
 fp.readline()
'CRLF\n'
 fp.newlines
 fp.tell()
6L
 fp.newlines # tell() skipped ahead..
 fp.readline()
'EOF'
 fp.newlines # ..but never identified CRLF
 

The following patch makes tell() mark CRLF as a newline in this case, 
and ensures so with an added test to test_univnewlines.py. It's against 
trunk, r28227

--
components: Library (Lib)
files: univnewline_tell-r58227.diff
messages: 56085
nosy: pjenvey
severity: normal
status: open
title: universal newlines doesn't identify CRLF during tell()
versions: Python 2.6

__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1188
__

univnewline_tell-r58227.diff
Description: Binary data
___
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com