(self)
| 154 | self.new_node_port = new_node_port |
| 155 | |
| 156 | def __repr__(self) -> str: |
| 157 | expiry_time = self.expire_at |
| 158 | remaining = max(0, expiry_time - time.monotonic()) |
| 159 | |
| 160 | return ( |
| 161 | f"{self.__class__.__name__}(" |
| 162 | f"id={self.id}, " |
| 163 | f"new_node_host='{self.new_node_host}', " |
| 164 | f"new_node_port={self.new_node_port}, " |
| 165 | f"ttl={self.ttl}, " |
| 166 | f"creation_time={self.creation_time}, " |
| 167 | f"expires_at={expiry_time}, " |
| 168 | f"remaining={remaining:.1f}s, " |
| 169 | f"expired={self.is_expired()}" |
| 170 | f")" |
| 171 | ) |
| 172 | |
| 173 | def __eq__(self, other) -> bool: |
| 174 | """ |
nothing calls this directly
no test coverage detected