New submission from Neil Schemenauer nas-pyt...@arctrix.com:
ihooks in 2.6 does not support relative imports. The attached patch was
impired by Brett's import in Python code.
--
assignee: brett.cannon
components: Library (Lib)
files: ihooks_relimport.txt
messages: 92345
nosy:
New submission from Tarek Ziadé ziade.ta...@gmail.com:
I am proposing this feature for an issue we have in Distutils: being
able to set the uid/gid of files added in a tar archive using tarfile.
Here's what I am proposing:
- adding two methods to TarInfo: set_uid and set_gid, that are able to
Tarek Ziadé ziade.ta...@gmail.com added the comment:
#6856 created.
--
dependencies: +allow settong uid and gid when creating tar files
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6516
___
Changes by Tarek Ziadé ziade.ta...@gmail.com:
--
title: allow settong uid and gid when creating tar files - allow setting uid
and gid when creating tar files
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6856
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Can you explain the reason why you need to change the distribution name,
and not use the name+version metadata to do it ?
Thanks
--
___
Python tracker rep...@bugs.python.org
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Ok so, just to make sure, the final patch for both changes should be:
{{{
...
elif sys.platform[:5] == hp-ux:
if compiler.find('gcc'):
return [-Wl,+s, -L + dir]
return [+s, -L + dir]
...
}}}
--
Tarek Ziadé ziade.ta...@gmail.com added the comment:
We can add two options to the commands that create tarballs:
- owner
- group
but we first need to add this capacity to the tarfile module because
right now the API doesn't allow you to add files with custom uid and gid.
I am going to add
Tarek Ziadé ziade.ta...@gmail.com added the comment:
I think there's no consensus at this point in the best format for all
platform.
I am closing this issue as wontfix. Maybe a new format will rule them
all in a few years.
Michael, can you create a specific issue for the CRLF problem ? Thanks
Ravon Jean-Michel jean-michel.ra...@gemalto.com added the comment:
It works in python 2.5. Why not in jython?
--
nosy: +jmravon
title: IDLE - configDialog - new layout for key config - Cannot write an array
in a file opened in r+b mode.
___
Python
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Thanks for the patch.
I need to look at how read_setup_file is actually used in the community,
then apply the patch in consequence.
--
type: - behavior
versions: -Python 2.4, Python 2.5, Python 2.6, Python 3.0
Changes by Tarek Ziadé ziade.ta...@gmail.com:
--
priority: - normal
resolution: - accepted
versions: +Python 2.7, Python 3.1, Python 3.2 -Python 2.5
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6114
Changes by Tarek Ziadé ziade.ta...@gmail.com:
--
priority: - high
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6377
___
___
Python-bugs-list
Changes by Martin v. Löwis mar...@v.loewis.de:
--
assignee: - lars.gustaebel
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6856
___
___
Michael Haubenwallner michael.haubenwall...@salomon.at added the comment:
Basically yes, two minor ones:
*) also look for 'g++',
*) string.find() returns the index where found, -1 when not found,
so:
{{{
...
elif sys.platform[:5] == hp-ux:
if compiler.find('gcc') = 0 or compiler.find('g++')
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Two lines below already is another search for 'gcc' or 'g++',
which also should be changed from 'compiler[:3]' to 'compiler.find()'
But compiler[:3] implies that the compiler string starts *with* 'gcc'.
so are you sure we're looking for
anatoly techtonik techto...@gmail.com added the comment:
How about:
Error running metaclass bases
(attempt to inherit from object that is not a class)
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6829
anatoly techtonik techto...@gmail.com added the comment:
Or just:
Error inheriting from object that is not a class
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6829
___
anatoly techtonik techto...@gmail.com added the comment:
Or with more info if possible:
Error when inheriting class %s - parent is not a class.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6829
Michael Haubenwallner michael.haubenwall...@salomon.at added the comment:
But compiler[:3] implies that the compiler string starts *with* 'gcc'.
so are you sure we're looking for 'gcc' anywhere in the string,
or at the beginning of it ?
It is very common to use the host triplet in the
Ezio Melotti ezio.melo...@gmail.com added the comment:
Can you paste the traceback of the error?
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6854
___
Lars Gustäbel l...@gustaebel.de added the comment:
TarInfo does not need set_uid() or set_gid() methods, both can be set
using the uid and gid attributes.
If the list of files to add to the archive is known you can do this:
tar = tarfile.open(foo.tar.gz, w:gz)
for filename in filenames:
Duncan Grisby duncan-pyt...@grisby.org added the comment:
This affects my application too. We have a large body of code that uses
exception classes automatically generated from CORBA IDL, with
attributes named message. It is infeasible for us to change to use a
different attribute name. We've
Tarek Ziadé ziade.ta...@gmail.com added the comment:
TarInfo does not need set_uid() or set_gid() methods,
both can be set using the uid and gid attributes.
I was thinking about the set_ methods to be able to use
root (str) instead of 0 (int) for example, like
what the tar command seems to
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
I suppose this update should have been directed to bugs.jython.org.
Something is probably wrong with the jython issue tracker...
--
nosy: +amaury.forgeotdarc, loewis
title: Cannot write an array in a file opened in r+b mode. -
Changes by Eric Smith e...@trueblade.com:
--
nosy: +eric.smith
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6713
___
___
Python-bugs-list mailing
Changes by Eric Smith e...@trueblade.com:
--
nosy: +eric.smith
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6850
___
___
Python-bugs-list mailing
Eric Smith e...@trueblade.com added the comment:
The test as written will always give an error for None. I think the
better fix is to change it to be:
if format_dict['type'] is None or format_dict['type'] in 'gG':
That fixes this particular exception, but since the format specifier
is invalid,
Changes by Eric Smith e...@trueblade.com:
--
components: +Library (Lib)
type: - behavior
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6850
___
R. David Murray rdmur...@bitdance.com added the comment:
It is possible that a TypeError could arise during the execution of the
metaclass bases that is not the result of inheriting from something
other than a class/type. It might, however, be possible to enhnace the
message with the name of
Stefan Krah stefan-use...@bytereef.org added the comment:
Eric Smith rep...@bugs.python.org wrote:
The test as written will always give an error for None. I think the
better fix is to change it to be:
if format_dict['type'] is None or format_dict['type'] in 'gG':
That fixes this
Stefan Krah stefan-use...@bytereef.org added the comment:
[...]
But in Python this error condition *can* 'otherwise be indicated', by
raising a suitable Python exception. So I propose changing the decimal
module in 2.7 and 3.2 so that int(Decimal('nan')) and
long(Decimal('nan')) raise
Eric Smith e...@trueblade.com added the comment:
The format string is valid. Sorry for the noise. The fill character of
'a' threw me off.
With my suggested change to decimal.py, line 5595, in py3k:
from decimal import *
format(Decimal(0.12345), a=-7.0)
'0.1'
format(0.12345, a=-7.0)
New submission from Stefan Krah stefan-use...@bytereef.org:
format(float(0.12345), 7.0) - '0.1'
The default alignment should be 'left-aligned'.
--
messages: 92370
nosy: skrah
severity: normal
status: open
title: float().__format__() default alignment
versions: Python 2.6, Python
Stefan Krah stefan-use...@bytereef.org added the comment:
Yes, I'll do that. - The tracker has eaten my examples, so hopefully
this goes through:
1. format(Decimal(0.12345), 7.1) - '0.1'
2. format(Decimal(0.12345), 7.0g) - '0.1'
3. format(Decimal(0.12345), 7.0)
Traceback (most
Changes by Stefan Krah stefan-use...@bytereef.org:
--
nosy: +eric.smith
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6857
___
___
Mark Dickinson dicki...@gmail.com added the comment:
Thanks for the report. I've fixed the order of the checks as Eric
suggested in r74704 (trunk), r74705 (release26-maint), r74706 (py3k) and
r74707 (release31-maint).
--
resolution: - fixed
stage: - committed/rejected
status: open
Lars Gustäbel l...@gustaebel.de added the comment:
I do not quite see the benefit from the set_* methods. Although the
attribute access I proposed may be slightly more complicated (because
you might need the pwd and grp modules) it offers the most freedom.
Let's take the set_uid() method as an
Chris Frantz frant...@gmail.com added the comment:
I believe the attached patch provides the desired functionality.
By default, the SSL library selects appropriate ciphers. If the user
creates an SSLSocket with a cipher_list, the string is passed directly
to SSL_CTX_set_cipher_list().
Tarek Ziadé ziade.ta...@gmail.com added the comment:
I do not quite see the benefit from the set_* methods.
.. some explanations of the underlying complexity...
The only benefit I can see for the set_* method is to hide
the underlying complexity you've explained.
In Distutils, I'd like to
OG7 ony...@users.sourceforge.net added the comment:
In most cases, a distribution named foo becomes and rpm named
python-foo, so it can't be the same name for both.
I'm using bdist_rpm to generate rpms from eggs I didn't write myself, so
an option to give external control works best.
Benjamin Peterson benja...@python.org added the comment:
Could you expand a little on what you expect to happen, please?
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6831
Mark Dickinson dicki...@gmail.com added the comment:
Hmm. PEP 3101 does indeed say that left-aligned is the default, but it's
a bit of a strange default for numeric types. I'd expect integers (at
least) to be right-aligned by default.
I'd be inclined to say that the current float formatting
Eric Smith e...@trueblade.com added the comment:
That is interesting. I'd agree that it's a bug in the PEP. Note that
%-formatting right aligns floats by default:
'%7.0g' % 0.12345
'0.1'
I'll raise the issue on python-dev.
Eric.
--
assignee: - eric.smith
Mark Dickinson dicki...@gmail.com added the comment:
Fixed __long__ bug and changed behaviour of int(Decimal('nan')) in r74708
(trunk), r74709 (py3k). I still need to fix the __long__ bug in the
release branches.
--
___
Python tracker
Mark Dickinson dicki...@gmail.com added the comment:
On second thoughts, I'm going to call this a bug and backport to 2.6 and
3.1.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6795
___
Mark Dickinson dicki...@gmail.com added the comment:
I don't think this is a Python bug; it has to do with the stdout
encoding. When connected to a terminal, sys.stdout.encoding is
(probably, on Ubuntu) UTF-8, but when you're using this as a cgi script
it's likely to be defaulting to ascii
Seamus O'Shea os...@uleth.ca added the comment:
(1) When running python (/usr/bin/python) in Terminal I am able to
import objc successfully. I printed the directory to be sure it's
complete
Seamuss-MacBook:~ seamus$ /usr/bin/python
Python 2.6.1 (r261:67515, Jul 7 2009, 23:51:51)
[GCC 4.2.1
Changes by Brett Cannon br...@python.org:
--
nosy: +brett.cannon
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6844
___
___
Python-bugs-list
Brett Cannon br...@python.org added the comment:
If someone can come up w/ a patch to make this work for all of you I would
be happy to review it and backport to 2.6. But the deprecation warning
cannot go away as it's needed for anyone who came to rely on the feature
in their 2.5 code from
loveminix lovemi...@yahoo.com.cn added the comment:
Here is the trackback (the uploaded file is a PDF file):
UnicodeDecodeError Python 3.1.1: /home/chu7/software/bin/python3
Mon Sep 7 12:31:07 2009
A problem occurred in a Python script. Here is the sequence of function
calls leading up to
Jean-Paul Calderone exar...@divmod.com added the comment:
After looking at this more carefully, I find myself wondering what
exactly is being deprecated at all.
Brett said:
it's needed for anyone who came to rely on the feature in their 2.5
code from Python.
Can someone help me understand
Brett Cannon br...@python.org added the comment:
On Mon, Sep 7, 2009 at 12:35, Jean-Paul Calderonerep...@bugs.python.org wrote:
Jean-Paul Calderone exar...@divmod.com added the comment:
After looking at this more carefully, I find myself wondering what
exactly is being deprecated at all.
Jean-Paul Calderone exar...@divmod.com added the comment:
Hm. That PEP is marked as rejected, though. I guess it was partially
implemented, those changes included in the Python 2.5 release, and then
it was decided that it was a bad idea, rejected, and the changes undone
for 3.x (what about
Ilya Sandler ilya.sand...@gmail.com added the comment:
Here is what's happening: when pdb starts up it sets tracing and several
trace events happen before the pdb reaches the first line of the
debugged program. So, pdb has some logic to ignore certain events on
startup (_wait_for_main_pyfile).
Brett Cannon br...@python.org added the comment:
On Mon, Sep 7, 2009 at 13:01, Jean-Paul Calderonerep...@bugs.python.org wrote:
Jean-Paul Calderone exar...@divmod.com added the comment:
Hm. That PEP is marked as rejected, though. I guess it was partially
implemented, those changes
Changes by Georg Brandl ge...@python.org:
--
nosy: +georg.brandl
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6844
___
___
Python-bugs-list
Georg Brandl ge...@python.org added the comment:
I've already renamed the message attribute in the 2.x tutorial in trunk.
--
nosy: +georg.brandl
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6849
Alan Isaac alan.is...@gmail.com added the comment:
The 'message' attribute itself is deprecated
as it didn't exist prior to being introduced in 2.5.
That seems to me to be the wrong way to phrase it, and indeed that kind
of phrasing implies the current bug. For example, it leads to the
Jean-Paul Calderone exar...@divmod.com added the comment:
Alright. So in Python 3.1, this is the behavior:
BaseException().message
(attribute error)
BaseException(foo).message
(attribute error)
BaseException(foo, bar).message
(attribute error)
x = BaseException()
x.message = foo
Brett Cannon br...@python.org added the comment:
On Mon, Sep 7, 2009 at 14:57, Jean-Paul Calderonerep...@bugs.python.org wrote:
Jean-Paul Calderone exar...@divmod.com added the comment:
Alright. So in Python 3.1, this is the behavior:
BaseException().message
(attribute error)
Changes by STINNER Victor victor.stin...@haypocalc.com:
Added file: http://bugs.python.org/file14857/bench_long_format.py
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6713
___
New submission from gert cuykens gert.cuyk...@gmail.com:
http://groups.google.be/group/comp.lang.python/browse_thread/thread/252fa1ccd0251977#
Menu option please, so I can highlight .wsgi .txt .xml files with python
code in it, does not matter if non python code gets wrongly highlighted too.
Changes by Frank Wierzbicki fwierzbi...@gmail.com:
--
nosy: +fwierzbicki
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6811
___
___
STINNER Victor victor.stin...@haypocalc.com added the comment:
Would it be possible to share some constant data between intobject.c and
longobject.c? There is already static const unsigned char BitLengthTable[32]
(32 bytes), and the patch introduces static const char _decimal_digit_table[]
(100
STINNER Victor victor.stin...@haypocalc.com added the comment:
@boya: It's maybe better to open a new issue for posix_lchown.
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5705
STINNER Victor victor.stin...@haypocalc.com added the comment:
+10. It would fix the os.urandom(1.2) bug. On Linux, os.urandom() displays
the following warnings and then go into an unlimited loop...
/usr/lib/python2.5/os.py:734: DeprecationWarning: integer argument expected,
got float
bytes
STINNER Victor victor.stin...@haypocalc.com added the comment:
Your patch is mixing tabs and spaces :-/
A free(tmpbuf); is missing in if (res == NULL) return posix_error();.
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
STINNER Victor victor.stin...@haypocalc.com added the comment:
By benchmark should be reproduced on a 64 bits CPU with 2^15 and 2^30
bases for the long type.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6713
STINNER Victor victor.stin...@haypocalc.com added the comment:
I wrote a dummy script to generate a big number (2568 decimal digits, 8530
bits) and then benchmark str(n). Results on my computer:
Python 2.7a0, Pentium4 @ 3.0 GHz (32 bits), long base=2^15
Smallest value of 5 runs:
original =
STINNER Victor victor.stin...@haypocalc.com added the comment:
The #ifdef MS_WINDOWS is not a the right place in posix_getcwdu(): buf and
res are declared but unused, and there is dead code on Windows.
The patch only fixes the UNIX implementation, not the Windows
implementation.
In the py3k
Changes by Frank Wierzbicki fwierzbi...@gmail.com:
--
nosy: +fwierzbicki
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6816
___
___
New submission from STINNER Victor victor.stin...@haypocalc.com:
It would be nice to have (at least) some stdint.h types in ctypes:
- uint8_t, int8_t
- int16_t, uint16_t
- int32_t, uint32_t
- uint64_t, int64_t
Attached fle is a Python implementation of that.
stdint.h contains much more types,
STINNER Victor victor.stin...@haypocalc.com added the comment:
Oooh. I just see that ctypes already includes ctypes.c_(u)int(8|16|32|64)
types... Sorry for the noise :-)
--
status: open - closed
___
Python tracker rep...@bugs.python.org
Changes by STINNER Victor victor.stin...@haypocalc.com:
--
resolution: - invalid
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6859
___
___
Changes by Chris Rebert pyb...@rebertia.com:
--
nosy: +cvrebert
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6858
___
___
Python-bugs-list
Changes by Gabriel Genellina gagsl-...@yahoo.com.ar:
--
nosy: +gagenellina
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6858
___
___
New submission from Patrick Näf herzb...@herzbube.ch:
The attached setup.py file defines a custom command named test, which
is implemented in a class named TestClass. Try to run both of the
following:
1) ./setup.py test -h
2) ./setup.py --help-commands
In case 1, Distutils will use the class
New submission from kai zhu kaizhu...@gmail.com:
# a00.py
parent = bytearray # fails
# parent = bytes # works
# parent = str # works
class Foo(parent):
def __new__(klass, x): return parent.__new__(klass, x)
Foo(x = None)
$ python3.1 -c import a00
Traceback (most recent call last):
Brandon Height bmhei...@gmail.com added the comment:
This behavior is also found inside of version 2.6.2
--
nosy: +lasko
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6861
___
Benjamin Peterson benja...@python.org added the comment:
That's because bytearray is mutable, so it uses __init__ instead of __new__.
--
nosy: +benjamin.peterson
resolution: - invalid
status: open - closed
___
Python tracker rep...@bugs.python.org
Changes by Chris Miles miles.ch...@gmail.com:
--
nosy: +chrismiles
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2320
___
___
Python-bugs-list
81 matches
Mail list logo