1. Dev/update python bindings for port pr (#813)

* updated python bindings for port update from int to uint16_t

* user friendly error message for exception when python arg does not match uint16_t for ports
This commit is contained in:
2023-09-29 11:12:02 +02:00
committed by GitHub
parent 88c39ba702
commit 72bec5d62e
3 changed files with 44 additions and 25 deletions

View File

@ -278,3 +278,9 @@ def hostname_list(args):
return hosts
else:
raise ValueError("hostname needs to be string or list of strings")
def validate_port(value):
if value <= 0 or value > 65535:
raise ValueError("port must be in range 1 - 65535")