finesse.utilities.misc.check_name

finesse.utilities.misc.check_name(name)[source]

Checks the validity of a component or node name.

A name is valid if it contains only alphanumeric characters and underscores, and is not empty.

Parameters:
namestr

The name to check.

Returns:
namestr

The name passed to this function if valid.

Raises:
ValueError

If name contains non-alphanumeric / underscore characters.