Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions pyalloc/allocator.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ def allocate(self) -> str:
ip_str = str(ip)
if ip_str not in self.allocated:
self.allocated.add(ip_str)
logger.info(f"Allocated IP: {ip_str}")
logger.info("Allocated IP %s", ip_str)
return ip_str
raise RuntimeError(f"No free IP addresses in {self.network}")

raise RuntimeError("No free IP addresses")

def release(self, ip: str) -> bool:
"""Release an allocated IP address.
Expand Down