[issue21346] typos in test_itertools.py

2014-04-24 Thread Brian Kearns

Changes by Brian Kearns :


--
files: test_itertools_typos-py27.patch
keywords: patch
nosy: bdkearns
priority: normal
severity: normal
status: open
title: typos in test_itertools.py
type: enhancement
versions: Python 2.7
Added file: http://bugs.python.org/file35025/test_itertools_typos-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-24 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file35030/fix_winreg_setvalueex-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-24 Thread Brian Kearns

Changes by Brian Kearns :


--
files: fix_winreg_setvalueex-py27.patch
keywords: patch
nosy: bdkearns
priority: normal
severity: normal
status: open
title: crash in winreg SetValueEx with memoryview
type: crash
versions: Python 2.7
Added file: http://bugs.python.org/file35030/fix_winreg_setvalueex-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-24 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file35031/fix_winreg_setvalueex-py27.patch

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



[issue21350] bug in file.writelines accepting buffers

2014-04-25 Thread Brian Kearns

New submission from Brian Kearns:

In file.writelines, the conditions in this if statement are bogus. If 
f->f_binary and AsReadBuffer succeeds (returns 0), AsCharBuf is still tried. 
So, for example, passing an array('c') to a file('wb').writelines fails, when 
it seems the intention of the code/comments was to have it succeed.

--
files: fix_file_writelines-py27.patch
keywords: patch
messages: 217162
nosy: bdkearns
priority: normal
severity: normal
status: open
title: bug in file.writelines accepting buffers
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file35036/fix_file_writelines-py27.patch

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



[issue21350] bug in file.writelines accepting buffers

2014-04-25 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file35036/fix_file_writelines-py27.patch

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



[issue21350] bug in file.writelines accepting buffers

2014-04-25 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file35037/fix_file_writelines-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-25 Thread Brian Kearns

Brian Kearns added the comment:

Oops, updated test.

--
Added file: http://bugs.python.org/file35038/fix_winreg_setvalueex-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-25 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file35031/fix_winreg_setvalueex-py27.patch

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



[issue21349] crash in winreg SetValueEx with memoryview

2014-04-25 Thread Brian Kearns

Brian Kearns added the comment:

Are you aware of the old/new buffer interfaces and their usages? Did you 
actually try the code? "crash" would be obvious.

Objects that support only the new buffer interface define tp_as_buffer with 
fields representing the old buffer interface as null.

So, everywhere that uses the old buffer interface usually checks both 
tp_as_buffer != NULL and tp_as_buffer->bf_getreadbuffer != NULL. That second 
check is missing here before calling bf_getreadbuffer.

--

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



[issue21350] bug in file.writelines accepting buffers

2014-05-07 Thread Brian Kearns

Brian Kearns added the comment:

So, for example:
>>> f = open('blah', 'wb')
>>> f.write(array.array('c', 'test'))
>>> f.writelines([array.array('c', 'test')])
Traceback (most recent call last):
  File "", line 1, in 
TypeError: writelines() argument must be a sequence of strings

While the comment in writelines says:
Check that all entries are indeed strings. If not,
apply the same rules as for file.write() and
convert the results to strings.

--

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-07-07 Thread Brian Kearns

Brian Kearns added the comment:

Updated patch, now it also caches the result of __hash__ like the C accelerator.

--
Added file: http://bugs.python.org/file35894/datetime-py35.patch

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



[issue22259] fdopen of directory causes segmentation fault

2014-08-23 Thread Brian Kearns

Changes by Brian Kearns :


--
files: fdopen-directory.patch
keywords: patch
nosy: bdkearns
priority: normal
severity: normal
status: open
title: fdopen of directory causes segmentation fault
type: crash
versions: Python 2.7
Added file: http://bugs.python.org/file36444/fdopen-directory.patch

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



[issue22259] fdopen of directory causes segmentation fault

2014-08-23 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file36444/fdopen-directory.patch

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



[issue22259] fdopen of directory causes segmentation fault

2014-08-23 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file36450/fdopen-directory.patch

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



[issue22259] fdopen of directory causes segmentation fault

2014-08-24 Thread Brian Kearns

Brian Kearns added the comment:

Updated to use assertEqual

--
Added file: http://bugs.python.org/file36452/fdopen-directory.patch

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



[issue22259] fdopen of directory causes segmentation fault

2014-08-24 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file36450/fdopen-directory.patch

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



[issue22265] fix reliance on refcounting in test_itertools

2014-08-24 Thread Brian Kearns

New submission from Brian Kearns:

The test fails on Python implementations with non-refcounted GCs without this 
line.

--
files: test_itertools.patch
keywords: patch
messages: 225835
nosy: bdkearns
priority: normal
severity: normal
status: open
title: fix reliance on refcounting in test_itertools
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file36455/test_itertools.patch

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-24 Thread Brian Kearns

New submission from Brian Kearns:

tarfile.gzopen relies on refcounting to close the fileobj when the fileobj is 
created during the call to gzopen (when it is not passed in). Since the fileobj 
is created outside of GzipFile, GzipFile does not take responsibility for 
closing the fileobj (so no one does, aside from the GC, which leads to 
unexpected behavior when using a non-refcounted GC).

This is fixed by having GzipFile open the fileobj itself, so it does take 
responsibility for closing it when necessary. The same approach is taken in 
tarfile.py in py3k branch.

--
files: tarfile.patch
keywords: patch
messages: 225836
nosy: bdkearns
priority: normal
severity: normal
status: open
title: fix reliance on refcounting in tarfile.gzopen
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file36456/tarfile.patch

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



[issue22265] fix reliance on refcounting in test_itertools

2014-08-24 Thread Brian Kearns

Brian Kearns added the comment:

Should go on py3k branches too...

--

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



[issue22267] fix reliance on refcounting in test_weakref

2014-08-24 Thread Brian Kearns

New submission from Brian Kearns:

The test fails on Python implementations with non-refcounted GCs without these 
lines. Should go on py3k branches also.

--
files: test_weakref.patch
keywords: patch
messages: 225839
nosy: bdkearns
priority: normal
severity: normal
status: open
title: fix reliance on refcounting in test_weakref
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file36457/test_weakref.patch

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



[issue22267] fix reliance on refcounting in test_weakref

2014-08-24 Thread Brian Kearns

Brian Kearns added the comment:

Possibly. But if so then one would argue there are plenty of other instances 
where gc_collect "should" be used, both within test_weakref and the rest of the 
test suite. Chose gc.collect here as it was used all over test_weakref.py, 
gc_collect never being used, and it fixed the test on PyPy.

--

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-24 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file36456/tarfile.patch

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-24 Thread Brian Kearns

Brian Kearns added the comment:

Yes, I guess that makes sense (though this behavior is undocumented and 
untested...)

--
Added file: http://bugs.python.org/file36462/tarfile.patch

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-25 Thread Brian Kearns

Brian Kearns added the comment:

Updated to backport all the cases where 3.x handles this issue.

--
Added file: http://bugs.python.org/file36468/tarfile2.patch

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-25 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file36468/tarfile2.patch

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



[issue22266] fix reliance on refcounting in tarfile.gzopen

2014-08-25 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file36469/tarfile2.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

New submission from Brian Kearns:

This patch brings the pure-python datetime more in-line with the C module. We 
have been running these modifications in PyPy2 stdlib for more than a year with 
no issue.

Includes:
- General PEP8/cleanups
- Better testing of argument types passed to constructors
- Removal of duplicate operations (in some paths values were checked twice for 
validity)
- Optimization of timedelta creation (brings it from 8-9usec to ~6 usec on 
CPython 3.3 on local machine)
- Enhancements/bug fixes in tests

--
files: datetime-py34.patch
keywords: patch
messages: 212832
nosy: bdkearns
priority: normal
severity: normal
status: open
title: Enhancements/fixes to pure-python datetime module
type: behavior
Added file: http://bugs.python.org/file34293/datetime-py34.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file34294/datetime-py33.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Brian Kearns added the comment:

Also includes bug fixes/tests for certain rounding cases (doesn't apply to the 
3.4 version).

--

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file34295/datetime-py33-v2.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file34296/datetime-py34-v2.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Brian Kearns added the comment:

Updated patch to v2 with another test/fix for type checking of __format__ 
argument to match the C module.

--

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Brian Kearns added the comment:

The C datetime module uses the 'i' code for parsing these args, not 'n' (which 
would correspond to operator.index). Using operator.index fails a test case I 
added (cases for classes like decimal.Decimal, implementing __int__ but not 
__index__).

--

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Brian Kearns added the comment:

Right, that's the behavior as it stands, so I hope this patch can be considered 
independently of that issue (and if such a change is made to the C 
implementation, then a corresponding change could be made in the python 
implementation).

--

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Brian Kearns added the comment:

Yes, I am the PyPy developer who worked on these datetime improvements there -- 
just finally got around to pushing them upstream.

--

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



[issue20861] datetime argument handling inconsistent; should accept logical integers, not coercible values

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


--
nosy: +bdkearns

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file34297/datetime-py33-v3.patch

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



[issue20858] Enhancements/fixes to pure-python datetime module

2014-03-06 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file34298/datetime-py34-v3.patch

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



[issue20887] stdlib compatibility with pypy, test_zipfile.py

2014-03-10 Thread Brian Kearns

Changes by Brian Kearns :


--
nosy: +bdkearns

___
Python tracker 
<http://bugs.python.org/issue20887>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://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

2013-03-08 Thread Brian Kearns

Changes by Brian Kearns :


--
nosy: +brian.kearns

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



[issue23090] fix test_doctest relying on refcounting to close files

2014-12-19 Thread Brian Kearns

Changes by Brian Kearns :


--
files: fix_test_doctest.patch
keywords: patch
nosy: bdkearns
priority: normal
severity: normal
status: open
title: fix test_doctest relying on refcounting to close files
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file37508/fix_test_doctest.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-24 Thread Brian Kearns

New submission from Brian Kearns:

Brings timedelta creation up to par with the (simpler) C equivalent. Gives a 
nice speed boost on the pure-py version (not worth much on CPython but useful 
on other implementations like PyPy).

Included in a few other small bug fixes/cleanups, should be self-explanatory.

--
files: timedelta.patch
keywords: patch
messages: 255322
nosy: bdkearns
priority: normal
severity: normal
status: open
title: update pure python datetime.timedelta creation
versions: Python 3.4, Python 3.5, Python 3.6
Added file: http://bugs.python.org/file41158/timedelta.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-24 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file41158/timedelta.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-24 Thread Brian Kearns

Changes by Brian Kearns :


Added file: http://bugs.python.org/file41159/timedelta.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-25 Thread Brian Kearns

Changes by Brian Kearns :


Removed file: http://bugs.python.org/file41159/timedelta.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-25 Thread Brian Kearns

Brian Kearns added the comment:

Correct patch uploaded

--
Added file: http://bugs.python.org/file41160/timedelta.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-25 Thread Brian Kearns

Brian Kearns added the comment:

Bug fixes are to the test suite itself, and the name cleanup, minor. Best 
classified as enhancement, apply where applicable.

--

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



[issue25729] update pure python datetime.timedelta creation

2015-11-25 Thread Brian Kearns

Brian Kearns added the comment:

Updated patch per review

--
Added file: http://bugs.python.org/file41164/timedelta2.patch

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



[issue25729] update pure python datetime.timedelta creation

2015-11-25 Thread Brian Kearns

Brian Kearns added the comment:

Updated again

--
Added file: http://bugs.python.org/file41165/timedelta3.patch

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



[issue23521] OverflowError from timedelta * float in datetime.py

2015-02-25 Thread Brian Kearns

Brian Kearns added the comment:

Maybe we should also use divide_and_round for __truediv__ to match the C 
implementation calling divide_nearest there as well?

--

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



[issue23521] OverflowError from timedelta * float in datetime.py

2015-02-25 Thread Brian Kearns

Brian Kearns added the comment:

td = timedelta(seconds=1)
print(td / (1/0.6112295))

--

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



[issue23521] OverflowError from timedelta * float in datetime.py

2015-02-26 Thread Brian Kearns

Brian Kearns added the comment:

You saw the demo python implementation of divmod_near in Objects/longobject.c? 
Maybe it's worth using a common implementation?

--

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