[Python-bugs-list] [ python-Bugs-481761 ] test_format fails
noreply@sourceforge.net
noreply@sourceforge.net
Wed, 14 Nov 2001 10:12:01 -0800
Bugs item #481761, was opened at 2001-11-14 09:46
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=481761&group_id=5470
Category: Build
Group: Python 2.2
>Status: Closed
>Resolution: Duplicate
Priority: 5
Submitted By: James Richardson (jamesrichardson)
>Assigned to: Michael Hudson (mwh)
Summary: test_format fails
Initial Comment:
OS: Tru64 4.0F
python: 2.2a3
gcc: 2.95.2
Any ideas?
viper.htc.com> ./python ./Lib/test/test_format.py
'%.1d' % (1,) =? '1' ... yes
u'%.1d' % (1,) =? '1' ... yes
'%.*d' % (9223372036854775807, 1) works? ... yes
u'%.*d' % (9223372036854775807, 1) works? ... yes
'%.100d' % (1,)
=? '000000000000000000000000000000000000000000000000000
000000000
0000000000000000000000000000000000000001' ... yes
u'%.100d' % (1,)
=? '000000000000000000000000000000000000000000000000000
00000000
00000000000000000000000000000000000000001' ... yes
'%#.117x' % (1,)
=? '0x0000000000000000000000000000000000000000000000000
00000000
0000000000000000000000000000000000000000000000000000000
00001' ... yes
u'%#.117x' % (1,)
=? '0x0000000000000000000000000000000000000000000000000
0000000
0000000000000000000000000000000000000000000000000000000
000001' ... yes
'%#.118x' % (1,)
=? '0x0000000000000000000000000000000000000000000000000
00000000
0000000000000000000000000000000000000000000000000000000
000001' ... overflow (thi
s is fine)
u'%#.118x' % (1,)
=? '0x0000000000000000000000000000000000000000000000000
0000000
0000000000000000000000000000000000000000000000000000000
0000001' ... overflow (th
is is fine)
'%f' % (1.0,) =? '1.000000' ... yes
u'%f' % (1.0,) =? '1.000000' ... yes
'%#.*g' % (109, -3.3333333333333334e+48) works? ... yes
u'%#.*g' % (109, -3.3333333333333334e+48) works? ...
yes
'%#.*g' % (110, -3.3333333333333334e+48) works? ...
overflow (this is fine)
u'%#.*g' % (110, -3.3333333333333334e+48) works? ...
overflow (this is fine)
'%#.*g' % (110, -3.3333333333333332e+99) works? ...
overflow (this is fine)
u'%#.*g' % (110, -3.3333333333333332e+99) works? ...
overflow (this is fine)
'%12.*f' % (123456, 1.0) works? ... overflow (this is
fine)
u'%12.*f' % (123456, 1.0) works? ... overflow (this is
fine)
'%x' % 10L =? 'a' ... yes
u'%x' % 10L =? 'a' ... yes
'%x' % 100000000000L =? '174876e800' ... yes
u'%x' % 100000000000L =? '174876e800' ... yes
'%o' % 10L =? '12' ... yes
u'%o' % 10L =? '12' ... yes
'%o' % 100000000000L =? '1351035564000' ... yes
u'%o' % 100000000000L =? '1351035564000' ... yes
'%d' % 10L =? '10' ... yes
u'%d' % 10L =? '10' ... yes
'%d' % 100000000000L =? '100000000000' ... yes
u'%d' % 100000000000L =? '100000000000' ... yes
'%d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' ... y
es
u'%d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' ...
yes
'%d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890' ...
yes
u'%d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890' ..
. yes
'%5d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890' ..
. yes
u'%5d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890' .
.. yes
'%31d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890' .
.. yes
u'%31d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890'
... yes
'%32d' % -123456789012345678901234567890L =? ' -
123456789012345678901234567890'
... yes
u'%32d' % -123456789012345678901234567890L =? ' -
123456789012345678901234567890'
... yes
'%-32d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890 '
... yes
u'%-32d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890
' ... yes
'%032d' % -123456789012345678901234567890L =? '-
0123456789012345678901234567890'
... yes
u'%032d' % -123456789012345678901234567890L =? '-
0123456789012345678901234567890
' ... yes
'%-032d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890
' ... yes
u'%-032d' % -123456789012345678901234567890L =? '-
123456789012345678901234567890
' ... yes
'%034d' % -123456789012345678901234567890L =? '-
00012345678901234567890123456789
0' ... yes
u'%034d' % -123456789012345678901234567890L =? '-
0001234567890123456789012345678
90' ... yes
'%034d' % 123456789012345678901234567890L
=? '0000123456789012345678901234567890
' ... yes
u'%034d' % 123456789012345678901234567890L
=? '000012345678901234567890123456789
0' ... yes
'%0+34d' % 123456789012345678901234567890L
=? '+00012345678901234567890123456789
0' ... yes
u'%0+34d' % 123456789012345678901234567890L
=? '+0001234567890123456789012345678
90' ... yes
'%+34d' % 123456789012345678901234567890L =? '
+123456789012345678901234567890
' ... yes
u'%+34d' % 123456789012345678901234567890L =? '
+12345678901234567890123456789
0' ... yes
'%34d' % 123456789012345678901234567890L =? '
123456789012345678901234567890'
... yes
u'%34d' % 123456789012345678901234567890L =? '
123456789012345678901234567890
' ... yes
'%.2d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' ...
yes
u'%.2d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' ..
. yes
'%.30d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' ..
. yes
u'%.30d' % 123456789012345678901234567890L
=? '123456789012345678901234567890' .
.. yes
'%.31d' % 123456789012345678901234567890L
=? '0123456789012345678901234567890' .
.. yes
u'%.31d' % 123456789012345678901234567890L
=? '0123456789012345678901234567890'
... yes
'%32.31d' % 123456789012345678901234567890L =? '
0123456789012345678901234567890
' ... yes
u'%32.31d' % 123456789012345678901234567890L =? '
012345678901234567890123456789
0' ... yes
'%x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
u'%x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
'%x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
u'%x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
'%5x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
u'%5x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
'%22x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
u'%22x' % -1375488932362216742658885L =? '-
1234567890abcdef12345' ... yes
'%23x' % -1375488932362216742658885L =? ' -
1234567890abcdef12345' ... yes
u'%23x' % -1375488932362216742658885L =? ' -
1234567890abcdef12345' ... yes
'%-23x' % -1375488932362216742658885L =? '-
1234567890abcdef12345 ' ... yes
u'%-23x' % -1375488932362216742658885L =? '-
1234567890abcdef12345 ' ... yes
'%023x' % -1375488932362216742658885L =? '-
01234567890abcdef12345' ... yes
u'%023x' % -1375488932362216742658885L =? '-
01234567890abcdef12345' ... yes
'%-023x' % -1375488932362216742658885L =? '-
1234567890abcdef12345 ' ... yes
u'%-023x' % -1375488932362216742658885L =? '-
1234567890abcdef12345 ' ... yes
'%025x' % -1375488932362216742658885L =? '-
0001234567890abcdef12345' ... yes
u'%025x' % -1375488932362216742658885L =? '-
0001234567890abcdef12345' ... yes
'%025x' % 1375488932362216742658885L
=? '00001234567890abcdef12345' ... yes
u'%025x' % 1375488932362216742658885L
=? '00001234567890abcdef12345' ... yes
'%0+25x' % 1375488932362216742658885L
=? '+0001234567890abcdef12345' ... yes
u'%0+25x' % 1375488932362216742658885L
=? '+0001234567890abcdef12345' ... yes
'%+25x' % 1375488932362216742658885L =? '
+1234567890abcdef12345' ... yes
u'%+25x' % 1375488932362216742658885L =? '
+1234567890abcdef12345' ... yes
'%25x' % 1375488932362216742658885L =? '
1234567890abcdef12345' ... yes
u'%25x' % 1375488932362216742658885L =? '
1234567890abcdef12345' ... yes
'%.2x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
u'%.2x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
'%.21x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
u'%.21x' % 1375488932362216742658885L
=? '1234567890abcdef12345' ... yes
'%.22x' % 1375488932362216742658885L
=? '01234567890abcdef12345' ... yes
u'%.22x' % 1375488932362216742658885L
=? '01234567890abcdef12345' ... yes
'%23.22x' % 1375488932362216742658885L =? '
01234567890abcdef12345' ... yes
u'%23.22x' % 1375488932362216742658885L =? '
01234567890abcdef12345' ... yes
'%-23.22x' % 1375488932362216742658885L
=? '01234567890abcdef12345 ' ... yes
u'%-23.22x' % 1375488932362216742658885L
=? '01234567890abcdef12345 ' ... yes
'%X' % 1375488932362216742658885L
=? '1234567890ABCDEF12345' ... yes
u'%X' % 1375488932362216742658885L
=? '1234567890ABCDEF12345' ... yes
'%#X' % 1375488932362216742658885L
=? '0X1234567890ABCDEF12345' ... yes
u'%#X' % 1375488932362216742658885L
=? '0X1234567890ABCDEF12345' ... yes
'%#x' % 1375488932362216742658885L
=? '0x1234567890abcdef12345' ... yes
u'%#x' % 1375488932362216742658885L
=? '0x1234567890abcdef12345' ... yes
'%#x' % -1375488932362216742658885L =? '-
0x1234567890abcdef12345' ... yes
u'%#x' % -1375488932362216742658885L =? '-
0x1234567890abcdef12345' ... yes
'%#.23x' % -1375488932362216742658885L =? '-
0x001234567890abcdef12345' ... yes
u'%#.23x' % -1375488932362216742658885L =? '-
0x001234567890abcdef12345' ... yes
'%#+.23x' % 1375488932362216742658885L
=? '+0x001234567890abcdef12345' ... yes
u'%#+.23x' % 1375488932362216742658885L
=? '+0x001234567890abcdef12345' ... yes
'%# .23x' % 1375488932362216742658885L =? '
0x001234567890abcdef12345' ... yes
u'%# .23x' % 1375488932362216742658885L =? '
0x001234567890abcdef12345' ... yes
'%#+.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... yes
u'%#+.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... yes
'%#-+.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... yes
u'%#-+.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... yes
'%#-+26.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... ye
s
u'%#-+26.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345' ... y
es
'%#-+27.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345 ' ... y
es
u'%#-+27.23X' % 1375488932362216742658885L
=? '+0X001234567890ABCDEF12345 ' ...
yes
'%#+27.23X' % 1375488932362216742658885L =? '
+0X001234567890ABCDEF12345' ... ye
s
u'%#+27.23X' % 1375488932362216742658885L =? '
+0X001234567890ABCDEF12345' ... y
es
'%#+027.23X' % 1375488932362216742658885L
=? '+0X0001234567890ABCDEF12345' ... y
es
u'%#+027.23X' % 1375488932362216742658885L
=? '+0X0001234567890ABCDEF12345' ...
yes
'%#+27.23X' % 1375488932362216742658885L =? '
+0X001234567890ABCDEF12345' ... ye
s
u'%#+27.23X' % 1375488932362216742658885L =? '
+0X001234567890ABCDEF12345' ... y
es
'%o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' ...
yes
u'%o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' ...
yes
'%o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670' ..
. yes
u'%o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670' .
.. yes
'%5o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670' .
.. yes
u'%5o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670'
... yes
'%33o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670'
... yes
u'%33o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670'
... yes
'%34o' % -12935167030485801517351291832L =? ' -
12345670123456701234567012345670'
... yes
u'%34o' % -12935167030485801517351291832L =? ' -
12345670123456701234567012345670
' ... yes
'%-34o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670
' ... yes
u'%-34o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670
' ... yes
'%034o' % -12935167030485801517351291832L =? '-
012345670123456701234567012345670
' ... yes
u'%034o' % -12935167030485801517351291832L =? '-
01234567012345670123456701234567
0' ... yes
'%-034o' % -12935167030485801517351291832L =? '-
12345670123456701234567012345670
' ... yes
u'%-034o' % -12935167030485801517351291832L =? '-
1234567012345670123456701234567
0 ' ... yes
'%036o' % -12935167030485801517351291832L =? '-
000123456701234567012345670123456
70' ... yes
u'%036o' % -12935167030485801517351291832L =? '-
00012345670123456701234567012345
670' ... yes
'%036o' % 12935167030485801517351291832L
=? '00001234567012345670123456701234567
0' ... yes
u'%036o' % 12935167030485801517351291832L
=? '0000123456701234567012345670123456
70' ... yes
'%0+36o' % 12935167030485801517351291832L
=? '+000123456701234567012345670123456
70' ... yes
u'%0+36o' % 12935167030485801517351291832L
=? '+00012345670123456701234567012345
670' ... yes
'%+36o' % 12935167030485801517351291832L =? '
+1234567012345670123456701234567
0' ... yes
u'%+36o' % 12935167030485801517351291832L =? '
+123456701234567012345670123456
70' ... yes
'%36o' % 12935167030485801517351291832L =? '
12345670123456701234567012345670
' ... yes
u'%36o' % 12935167030485801517351291832L =? '
1234567012345670123456701234567
0' ... yes
'%.2o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' ..
. yes
u'%.2o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' .
.. yes
'%.32o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' .
.. yes
u'%.32o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670'
... yes
'%.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
u'%.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
'%34.33o' % 12935167030485801517351291832L =? '
01234567012345670123456701234567
0' ... yes
u'%34.33o' % 12935167030485801517351291832L =? '
0123456701234567012345670123456
70' ... yes
'%-34.33o' % 12935167030485801517351291832L
=? '01234567012345670123456701234567
0 ' ... yes
u'%-34.33o' % 12935167030485801517351291832L
=? '0123456701234567012345670123456
70 ' ... yes
'%o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' ...
yes
u'%o' % 12935167030485801517351291832L
=? '12345670123456701234567012345670' ...
yes
'%#o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670' ..
. yes
u'%#o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670' .
.. yes
'%#o' % -12935167030485801517351291832L =? '-
012345670123456701234567012345670'
... yes
u'%#o' % -12935167030485801517351291832L =? '-
012345670123456701234567012345670'
... yes
'%#.34o' % -12935167030485801517351291832L =? '-
00123456701234567012345670123456
70' ... yes
u'%#.34o' % -12935167030485801517351291832L =? '-
0012345670123456701234567012345
670' ... yes
'%#+.34o' % 12935167030485801517351291832L
=? '+00123456701234567012345670123456
70' ... yes
u'%#+.34o' % 12935167030485801517351291832L
=? '+0012345670123456701234567012345
670' ... yes
'%# .34o' % 12935167030485801517351291832L =? '
00123456701234567012345670123456
70' ... yes
u'%# .34o' % 12935167030485801517351291832L =? '
0012345670123456701234567012345
670' ... yes
'%#+.34o' % 12935167030485801517351291832L
=? '+00123456701234567012345670123456
70' ... yes
u'%#+.34o' % 12935167030485801517351291832L
=? '+0012345670123456701234567012345
670' ... yes
'%#-+.34o' % 12935167030485801517351291832L
=? '+0012345670123456701234567012345
670' ... yes
u'%#-+.34o' % 12935167030485801517351291832L
=? '+001234567012345670123456701234
5670' ... yes
'%#-+37.34o' % 12935167030485801517351291832L
=? '+00123456701234567012345670123
45670 ' ... yes
u'%#-+37.34o' % 12935167030485801517351291832L
=? '+0012345670123456701234567012
345670 ' ... yes
'%#+37.34o' % 12935167030485801517351291832L =? '
+0012345670123456701234567012
345670' ... yes
u'%#+37.34o' % 12935167030485801517351291832L =? '
+001234567012345670123456701
2345670' ... yes
'%.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
u'%.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
'%#.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
u'%#.33o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670
' ... yes
'%#.32o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670'
... yes
u'%#.32o' % 12935167030485801517351291832L
=? '012345670123456701234567012345670
' ... yes
'%034.33o' % 12935167030485801517351291832L
=? '00123456701234567012345670123456
70' ... yes
u'%034.33o' % 12935167030485801517351291832L
=? '0012345670123456701234567012345
670' ... yes
'%0#34.33o' % 12935167030485801517351291832L
=? '0012345670123456701234567012345
670' ... yes
u'%0#34.33o' % 12935167030485801517351291832L
=? '001234567012345670123456701234
5670' ... yes
'%d' % 42 =? '42' ... yes
u'%d' % 42 =? '42' ... yes
'%d' % -42 =? '-42' ... yes
u'%d' % -42 =? '-42' ... yes
'%d' % 42L =? '42' ... yes
u'%d' % 42L =? '42' ... yes
'%d' % -42L =? '-42' ... yes
u'%d' % -42L =? '-42' ... yes
'%#x' % 1 =? '0x1' ... yes
u'%#x' % 1 =? '0x1' ... yes
'%#x' % 1L =? '0x1' ... yes
u'%#x' % 1L =? '0x1' ... yes
'%#X' % 1 =? '0X1' ... yes
u'%#X' % 1 =? '0X1' ... yes
'%#X' % 1L =? '0X1' ... yes
u'%#X' % 1L =? '0X1' ... yes
'%#o' % 1 =? '01' ... yes
u'%#o' % 1 =? '01' ... yes
'%#o' % 1L =? '01' ... yes
u'%#o' % 1L =? '01' ... yes
'%#o' % 0 =? '0' ... no
'%#o' % 0 == '00' != '0'
u'%#o' % 0 =? '0' ... no
u'%#o' % 0 == u'00' != '0'
'%#o' % 0L =? '0' ... yes
u'%#o' % 0L =? '0' ... yes
'%o' % 0 =? '0' ... yes
u'%o' % 0 =? '0' ... yes
'%o' % 0L =? '0' ... yes
u'%o' % 0L =? '0' ... yes
'%d' % 0 =? '0' ... yes
u'%d' % 0 =? '0' ... yes
'%d' % 0L =? '0' ... yes
u'%d' % 0L =? '0' ... yes
'%#x' % 0 =? '0x0' ... yes
u'%#x' % 0 =? '0x0' ... yes
'%#x' % 0L =? '0x0' ... yes
u'%#x' % 0L =? '0x0' ... yes
'%#X' % 0 =? '0X0' ... yes
u'%#X' % 0 =? '0X0' ... yes
'%#X' % 0L =? '0X0' ... yes
u'%#X' % 0L =? '0X0' ... yes
'%x' % 66 =? '42' ... yes
u'%x' % 66 =? '42' ... yes
'%x' % 66L =? '42' ... yes
u'%x' % 66L =? '42' ... yes
'%x' % -66L =? '-42' ... yes
u'%x' % -66L =? '-42' ... yes
'%o' % 34 =? '42' ... yes
u'%o' % 34 =? '42' ... yes
'%o' % 34L =? '42' ... yes
u'%o' % 34L =? '42' ... yes
'%o' % -34L =? '-42' ... yes
u'%o' % -34L =? '-42' ... yes
Testing exceptions
'abc %a' % 1 works? ... yes
u'abc %\u3000' % 1 works? ... yes
viper.htc.com>
----------------------------------------------------------------------
>Comment By: Michael Hudson (mwh)
Date: 2001-11-14 10:12
Message:
Logged In: YES
user_id=6656
Dup of #422339.
Executive summary: your libc is bust. Complain to
Digital^WCompaq^WHP^Wwhoever.
You could have trimmed that a bit, you know. It was hard to
find the failing bit (even though I knew what it was
probably going to be).
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=481761&group_id=5470