openfl.utilities.utils.is_fqdn

openfl.utilities.utils.is_fqdn(hostname: str) bool

Check if a hostname is a fully qualified domain name.

This function checks if a hostname is a fully qualified domain name (FQDN) according to the rules specified on Wikipedia. https://en.m.wikipedia.org/wiki/Fully_qualified_domain_name.

Parameters:

hostname (str) – The hostname to check.

Returns:

boolTrue if the hostname is a FQDN, False otherwise.