Right now the function decodeUniqueId that validates the encoded UID logs an exception and implicitly returns None when something fails. This causes the validate_unique_id function to try and assign None to a pair of values, which causes and exception.
We should explicitly return None after an exception in decodeUniqueId and detect and handle it in validate_unique_id.