the forums at degreez.net

It is currently Thu Mar 28, 2024 11:11 pm

All times are UTC - 7 hours [ DST ]




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
PostPosted: Wed Mar 31, 2004 5:04 am 
I got this error using the python stuff on linux.
Code:
Complete trace:
# Traceback (most recent call last):
  File "BitTornado/RawServer.py", line 128, in listen_forever
    self.sockethandler.handle_events(events)
  File "BitTornado/SocketHandler.py", line 257, in handle_events
    s.handler.data_came_in(s, data)
  File "BitTornado/BT1/Encrypter.py", line 156, in data_came_in
    x = self.next_func(m)
  File "BitTornado/BT1/Encrypter.py", line 122, in read_message
    self.connecter.got_message(self, s)
  File "BitTornado/BT1/Connecter.py", line 208, in got_message
    b = Bitfield(self.numpieces, message[1:])
  File "BitTornado/bitfield.py", line 21, in __init__
    counts = [sum([(i >> j) & 1 for j in xrange(8)]) for i in xrange(256)]
NameError: global name 'sum' is not defined


I googled and added the following line to bitfield.py at line 21:
Code:
sum=lambda numberlist:reduce(lambda x,y:x+y,numberlist,0.0)

Don't know if thats correct, cause my python knowledge is zero.
But i can start it up without errors.
Just wanting you to know this.
It seems to work when you add this line.


Top
  
 
 Post subject:
PostPosted: Wed Mar 31, 2004 8:00 am 
Offline

Joined: Sun Mar 07, 2004 10:05 am
Posts: 1212
Thanks. This will be fixed in the next version.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 7 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 45 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group