255 argument limit?

Michael Yanowitz m.yanowitz at kearfott.com
Wed Oct 25 09:14:54 EDT 2006


Hello:

   It appears that there is a 255 argument limit in Python 2.4.3?

>>> packed_data = struct.pack("260i",
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21
,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,
47,4
8,49,50,1,1,1,1,1,1,1,1,1,60,1,2,3,4,5,6,7,8,9,70,1,2,3,4,5,6,7,8,9,80,1,2,3
,4,5
,6,7,8,9,90,1,2,3,4,5,6,7,8,9,100,1,2,3,4,5,6,7,8,9,110,1,2,3,4,5,6,7,8,9,12
0,1,
2,3,4,5,6,7,8,9,130,1,2,3,4,5,6,7,8,9,140,1,2,3,4,5,6,7,8,9,150,1,2,3,4,5,6,
7,8,
9,160,1,2,3,4,5,6,7,8,9,170,1,2,3,4,5,6,7,8,9,180,1,2,3,4,5,6,7,8,9,190,1,2,
3,4,
5,6,7,8,9,200,1,2,3,4,5,6,7,8,9,210,1,2,3,4,5,6,7,8,9,220,1,2,3,4,5,6,7,8,9,
230,
1,2,3,4,5,6,7,8,9,240,1,2,3,4,5,6,7,8,9,250,1,2,3,4,5,6,7,8,9)
SyntaxError: more than 255 arguments

   Is there a way to increase this limit?
(This is just a made up example, I would not normally do this).

Thanks in advance:
Michael Yanowitz





More information about the Python-list mailing list