Skip to content

Commit

Permalink
Use address instead of name+host
Browse files Browse the repository at this point in the history
  • Loading branch information
bnaul committed Feb 16, 2020
1 parent b93ef94 commit 3cf2bab
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions distributed/scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -276,13 +276,10 @@ def __init__(
self.extra = extra or {}

def __hash__(self):
return hash((self.name, self.host))
return hash(self.address)

def __eq__(self, other):
return type(self) == type(other) and (self.name, self.host) == (
other.name,
other.host,
)
return type(self) == type(other) and self.address == other.address

@property
def host(self):
Expand Down

0 comments on commit 3cf2bab

Please sign in to comment.