(self)
return self
Return a new path with expanded ~ and ~user constructs
        (as returned by os.path.expanduser)
Return a new path with expanded ~ and ~user constructs
        (as returned by os.path.expanduser)
Return a new path with expanded ~ and ~user constructs ( as returned by os . path . expanduser )
def expanduser(self):
        """ Return a new path with expanded ~ and ~user constructs
        (as returned by os.path.expanduser)
        """
        if (not (self._drv or self._root) and
            self._parts and self._parts[0][:1] == '~'):
            homedir = self._accessor.expanduser(self._parts[0])
            if homedir[:1] == "~":
                raise RuntimeError("Could not determine home directory.")
            return self._from_parts([homedir] + self._parts[1:])

        return self
def expanduser ( self ) : if ( not ( self . _drv or self . _root ) and self . _parts and self . _parts [ 0 ] [ : 1 ] == '~' ) : homedir = self . _accessor . expanduser ( self . _parts [ 0 ] ) if homedir [ : 1 ] == "~" : raise RuntimeError ( "Could not determine home directory." ) return self . _from_parts ( [ homedir ] + self . _parts [ 1 : ] ) return self