Serhiy Storchaka added the comment:
I don't see much sense in differences between bytea_slice2.patch and
bytea_slice3.patch, because bytea_slice3.patch is not smaller and simpler than
bytea_slice2.patch.
I meant that you can continue use self-ob_bytes instead of
PyByteArray_AS_STRING(self)
Changes by Ethan Furman et...@stoneleaf.us:
--
assignee: - ethan.furman
nosy: +ethan.furman
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19156
___
Serhiy Storchaka added the comment:
This is not a bug, str accepts the encoding argument in Python 3. And in
contrast to the decode method it works with arbitrary byte-like objects (i.e.
array.array).
--
nosy: +serhiy.storchaka
___
Python tracker
Antoine Pitrou added the comment:
I meant that you can continue use self-ob_bytes instead of
PyByteArray_AS_STRING(self) if self-ob_bytes points not to the
start of physical buffer, but to the start of logical byte array.
*This* will simplify the patch a lot.
It will make the diff smaller
Changes by Piotr Dobrogost p...@bugs.python.dobrogost.net:
--
nosy: +piotr.dobrogost
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10049
___
___
Changes by Piotr Dobrogost p...@bugs.python.dobrogost.net:
--
nosy: +piotr.dobrogost
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1673203
___
___
Changes by Piotr Dobrogost p...@bugs.python.dobrogost.net:
--
nosy: +piotr.dobrogost
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11011
___
___
New submission from Adam Davison:
If you pass an array containing nan to collections.Counter, rather than
counting the number of 'nan's it outputs 'nan': 1 n times into the
dictionary. I appreciate using this on an array of floats is a bit of an
unusual case but I don't think this is the
Mark Dickinson added the comment:
Presumably this relates to the fact that nan != nan.
Yep. What you're seeing is pretty much expected behaviour, and it matches how
NaNs behave with respect to containment in other Python contexts:
x = float('nan')
y = float('nan')
s = {x}
x in s
True
y
Adam Davison added the comment:
Thanks for the quick response. I'm really using a pandas Series, which is
effectively a numpy array behind the scenes as far as I understand, the example
I pasted was just to illustrate the behaviour. So the nans are being produced
elsewhere, I don't really
New submission from Filip Zyzniewski:
The datetime class provides a min datetime object which is not formattable:
on Python 2:
$ python
Python 2.7.3 (default, Apr 10 2013, 05:13:16)
[GCC 4.7.2] on linux2
Type help, copyright, credits or license for more information.
import datetime
New submission from hiroaki itoh:
http://docs.python.org/2.7/c-api/string.html#PyString_Format
The documents says `The args argument must be a tuple.',
But if format is like '%(key)s', PyString_Format claims
args must be mapping protocol.
(At least 2.7.3.)
--
assignee: docs@python
New submission from Marco Buccini:
When you try to use uuid.UUID() without arguments you get a TypeError exception
saying that you can actually use an integer (while you cannot).
Python 2.6.8 (default, Apr 26 2013, 16:24:53)
[GCC 4.6.3] on linux2
uuid.UUID()
Traceback (most recent call
tomasz.zaleski added the comment:
works correctly on python3.3:
Python 3.3.2 (default, Oct 4 2013, 12:21:07)
[GCC 4.2.1 20070831 patched [FreeBSD]] on freebsd9
Type help, copyright, credits or license for more information.
import datetime
datetime.datetime.min.strftime('%Y')
'0001'
issue on
Antoine Pitrou added the comment:
No custom builds. Every package from ubuntu repository. Psycopg2 installed by
pip
You may have to rebuild packages using the custom Python, not the system
Python, since the linker options have to be different (especially the shared
part: Ubuntu's Python is
Vajrasky Kok added the comment:
The exception message is correct. You can give an integer argument. But you
have to use keyword argument.
uuid.UUID(int=uuid.uuid4().int)
UUID('62ad61e5-b492-4f01-81e6-790049051c4f')
From the documentation:
__init__(self, hex=None, bytes=None, bytes_le=None,
Mark Dickinson added the comment:
perhaps collections.Counter should handle nans as a special case
I don't think that would be a good idea: I'd rather that collections.Counter
didn't special case NaNs in any way, but instead treated NaNs following the
same (admittedly somewhat awkward)
Richard Oudkerk added the comment:
Is BoundedSemaphore really supposed to be robust in the face of too many
releases, or does it just provide a sanity check?
I think that releasing a bounded semaphore too many times is a programmer
error, and the exception is just a debugging aid for the
R. David Murray added the comment:
I think we are unlikely to do this, as pdb is a very simple text interface.
I'm sure a patch would be considered if one was offered, but the increase in
complexity of the codebase would need to be minimal for it to be accepted, and
I suspect the feature
Ezio Melotti added the comment:
Agreed with David.
You can use https://bitbucket.org/antocuni/pdb/src instead.
--
nosy: +ezio.melotti
resolution: - rejected
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
R. David Murray added the comment:
Indeed, this is already fixed. This issue is a duplicate of issue 1777412.
The bug will not be fixed in earlier versions for the reasons discussed in that
issue.
--
nosy: +r.david.murray
resolution: - duplicate
stage: - committed/rejected
status:
Ronald Oussoren added the comment:
I'd really like to include this patch in 3.4, but haven't managed to do any
opensource work in the previous period and don't know when I'll be able to
actually commit this (and more importantly, be available when issues crop up)
:-(
--
Brett Cannon added the comment:
It looks like as long as you block _frozen_importlib and do a fresh import of
importlib you can make sure to use the source version of importlib._bootstrap
instead of _frozen_importlib.
from test.support import import_fresh_module
mod =
Changes by Brett Cannon br...@python.org:
--
title: Make test_importlib run tests under both _frozen_importlib and
importlib._bootstrap - Make test_import test_importlib run tests under both
_frozen_importlib and importlib._bootstrap
___
Python
Roundup Robot added the comment:
New changeset 405245885569 by Benjamin Peterson in branch '2.7':
dict is also allowed (closes #19163)
http://hg.python.org/cpython/rev/405245885569
--
nosy: +python-dev
resolution: - fixed
stage: - committed/rejected
status: open - closed
Georg Brandl added the comment:
Yeah, the first message should probably say one of the hex, bytes, bytes_le,
fields, or int arguments must be given
--
nosy: +georg.brandl
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19164
Changes by Brett Cannon br...@python.org:
--
resolution: - fixed
stage: test needed - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18716
___
Roundup Robot added the comment:
New changeset 04ff1cc40d62 by Brett Cannon in branch 'default':
Issue #18716: Deprecate the formatter module
http://hg.python.org/cpython/rev/04ff1cc40d62
--
nosy: +python-dev
___
Python tracker rep...@bugs.python.org
Changes by Brett Cannon br...@python.org:
--
assignee: brett.cannon
components: Library (Lib)
nosy: brett.cannon
priority: normal
severity: normal
status: open
title: Change formatter warning to DeprecationWarning in 3.5
versions: Python 3.5
___
New submission from Vajrasky Kok:
This is the test.
def test_keys(self):
d = {}
self.assertEqual(set(d.keys()), set())
d = {'a': 1, 'b': 2}
k = d.keys()
self.assertIn('a', d)
self.assertIn('b', d)
self.assertRaises(TypeError, d.keys,
Brett Cannon added the comment:
Turns out this isn't as clean-cut as simply using
test.support.import_fresh_module() as you end up with different instances of
importlib._bootstrap which kills any possible subclass checks, etc. between
e.g. importlib.abc and importlib.machinery as the source
Changes by Jesús Cea Avión j...@jcea.es:
--
nosy: +jcea
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6028
___
___
Python-bugs-list mailing list
Tim Peters added the comment:
Richard, that's a strange argument ;-) Since, e.g., a BoundedSemaphore(1) is
semantically equivalent to a mutex, it's like saying some_mutex.release()
usually raises an exception if the mutex isn't held at the time - but maybe it
won't. If the docs _say_ it's
Roundup Robot added the comment:
New changeset f0416b2b5654 by Brett Cannon in branch 'default':
Issue #16803: Run test.test_importlib.test_abc under both
http://hg.python.org/cpython/rev/f0416b2b5654
--
nosy: +python-dev
___
Python tracker
Rinat added the comment:
Or perhaps you can dlopen the CPython shared library with the RTLD_GLOBAL
flag. I don't know.
Yes, it works. I made it is my shared library before boost block like this
{
void* handle = dlopen(libpython2.7.so, RTLD_LAZY | RTLD_GLOBAL);
// boost wrapper for
Changes by Phil Connell pconn...@gmail.com:
--
nosy: +pconnell
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16195
___
___
Python-bugs-list
Antoine Pitrou added the comment:
Ok, making it a documentation issue in case it deserves clarification in the
docs.
--
assignee: - docs@python
components: +Documentation -Library (Lib)
nosy: +docs@python
___
Python tracker rep...@bugs.python.org
STINNER Victor added the comment:
@Xavier de Gaye: Nice, you found many similar issues. How did you find them?
Would it be possible to automate the detection of duplicated test names?
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
New submission from mpb:
On Win32, when I select from an SQLite view, and enclose the column name in
double quotes in the select query, the cursor description (erroneously?)
contains the double quotes.
On Linux (or on Win32 when selecting from a table rather than a view) the
cursor
Derek Wilson added the comment:
Any update on this? Just so you can see what my work around is, I'll paste in
the code I'm using. The major issue I have with this is that performance
doesn't scale to large strings.
This is also a bytes-to-bytes or str-to-str encoding, because this is the type
Gregory P. Smith added the comment:
Correct, my characterization above was wrong (I shouldn't write these up
without the interpreter right in front of me). What is wrong with the
conversion is:
unicode(, utf-8) in python 2.x should become either str(b, utf-8) or,
better, just in Python 3.x.
Xavier de Gaye added the comment:
It was proposed, in issue 16056, to enhance `make patchcheck` with the
detection of duplicate code names. This triggered the creation of issue 16079.
The script named duplicate_code_names_2.py, in issue 16079, listed about 20
duplicate names among all the
Serhiy Storchaka added the comment:
Just add the b prefix to literal string argument of unicode() in Python 2.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19159
___
New submission from Alexis Layton:
Documentation for 3.4 states that the compact keyword-only argument has been
added to 3.4. However:
Python 3.4.0a3 (default, Oct 2 2013, 14:05:02)
[GCC 4.6.3] on linux
Type help, copyright, credits or license for more information.
import pprint
pprint(3,
Changes by Raymond Hettinger raymond.hettin...@gmail.com:
--
assignee: - rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18986
___
___
Ezio Melotti added the comment:
This a very recent change, see #19132.
Python 3.4.0a3+ (default:f0416b2b5654, Oct 5 2013, 02:10:25)
[GCC 4.7.3] on linux
Type help, copyright, credits or license for more information.
import pprint
pprint.pprint(3, compact=True)
3
--
nosy:
Roundup Robot added the comment:
New changeset e4cec1116e5c by Raymond Hettinger in branch '3.3':
Issue #18594: Make the C code more closely match the pure python code.
http://hg.python.org/cpython/rev/e4cec1116e5c
--
___
Python tracker
Roundup Robot added the comment:
New changeset 92c2e76ca595 by Ezio Melotti in branch '2.7':
#19166: use an unused var in a test. Patch by Vajrasky Kok.
http://hg.python.org/cpython/rev/92c2e76ca595
New changeset 33bbc60705e8 by Ezio Melotti in branch '3.3':
#19166: use an unused var in a
Ezio Melotti added the comment:
Fixed, thanks for the report and the patch!
--
assignee: - ezio.melotti
nosy: +ezio.melotti
resolution: - fixed
stage: - committed/rejected
status: open - closed
type: - enhancement
versions: +Python 2.7, Python 3.3
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
stage: - needs patch
type: - enhancement
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19165
___
Changes by Terry J. Reedy tjre...@udel.edu:
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19111
___
___
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
keywords: +easy
nosy: +ezio.melotti
stage: - needs patch
versions: +Python 2.7 -Python 2.6
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19164
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
stage: - test needed
type: crash - behavior
versions: -Python 2.6, Python 3.1, Python 3.2
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19154
Terry J. Reedy added the comment:
In general, os module functions lightly wrap the corresponding operating system
calls. It does not mask differences between OSes, or between versions of an OS.
So the unix-windows difference is not a bug and the behavior will not change.
The difference
Changes by Terry J. Reedy tjre...@udel.edu:
--
stage: - needs patch
versions: +Python 2.7, Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19129
___
Roundup Robot added the comment:
New changeset db94fc7218fa by Ezio Melotti in branch 'default':
#19148: fix markup errors and wording in enum docs. Patch by Esa Peuha.
http://hg.python.org/cpython/rev/db94fc7218fa
--
nosy: +python-dev
___
Python
Ezio Melotti added the comment:
Fixed, thanks for the report and the patch!
I used a slightly different wording than the one you suggested because the rest
of the document doesn't seem to use you.
--
assignee: docs@python - ezio.melotti
nosy: +ezio.melotti
resolution: - fixed
stage:
Terry J. Reedy added the comment:
By default, Idle runs user code in a separate process from the idle process
that runs shell and edit windows. Because connecting the two processes
sometimes fails, there is a start-up option -N (No subprocess) that run your
code in the same process as idle
Changes by Eric Snow ericsnowcurren...@gmail.com:
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19152
___
___
Roundup Robot added the comment:
New changeset 62d045a873bb by Eric Snow in branch 'default':
[issue 19152] Ensure we have actually registered ExtensionFileLoader as an
ExecutionLoader.
http://hg.python.org/cpython/rev/62d045a873bb
New changeset e9554199620f by Eric Snow in branch 'default':
Terry J. Reedy added the comment:
Changing the API of HTTPResponse.fileno is a feature change, not a bug fix. I
do not think it should be changed as it would break existing code to no
purpose. Instead, calls should continue to wrapped in try: except ValueError
when failure is possible. And
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti, serhiy.storchaka
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19145
___
Terry J. Reedy added the comment:
This is the sort of issue that makes me think that there should be a single nan
object (perhaps an instance of a Nan(float) subclass with a special __eq__
method ;-). Pending that, I agree with closing as won't fix.
--
nosy: +terry.reedy
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
keywords: +easy
type: - enhancement
versions: -Python 2.7
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19129
___
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
stage: - needs patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19113
___
Changes by Raymond Hettinger raymond.hettin...@gmail.com:
--
resolution: - wont fix
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19161
___
Eric Snow added the comment:
Here's an initial patch. Some key things left to do:
* unit tests
* documentation
* implement exec_module() for the various importlib loaders.
Once that's squared away there are further things that will be addressed in new
tickets (or at least separate patches).
Eric Snow added the comment:
Here's a patch.
--
keywords: +patch
stage: test needed - patch review
Added file:
http://bugs.python.org/file31960/issue18862-importlib-abc-subclasshooks.diff
___
Python tracker rep...@bugs.python.org
68 matches
Mail list logo