def dirname(path: Optional[str]) -> Optional[str]:
if path is not None:<EOL><INDENT>return os.path.dirname(path)<EOL><DEDENT>
Returns the directory component of a pathname and None if the argument is None