Skip to content

Commit

Permalink
bumped version to 0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
bmuller committed Jun 27, 2015
1 parent 30dd820 commit 89f04cf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion kademlia/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""
Kademlia is a Python implementation of the Kademlia protocol for `Twisted <http://twistedmatrix.com>`_.
"""
version_info = (0, 4)
version_info = (0, 5)
version = '.'.join(map(str, version_info))
4 changes: 2 additions & 2 deletions kademlia/node.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def push(self, nodes):
nodes = [nodes]

for node in nodes:
if node not in self:
if node not in self:
distance = self.node.distanceTo(node)
heapq.heappush(self.heap, (distance, node))

Expand All @@ -109,7 +109,7 @@ def __contains__(self, node):
for distance, n in self.heap:
if node.id == n.id:
return True
return False
return False

def getUncontacted(self):
return [n for n in self if n.id not in self.contacted]

0 comments on commit 89f04cf

Please sign in to comment.