def get_container_fields(self, path):
        """

        :param path: str or Path instance
        :return:
        :rtype: dict[str,str]
        :raises ValueError: A component of path is a field name.
        :raises KeyError: A component of path doesn't exist.
        """
        container = self.get_container(path)
        fields = {}
        for name,value in container._values.items():
            if isinstance(value, str) or isinstance(value, list):
                fields[name] = value
        return fields
def get_container_fields ( self , path ) : container = self . get_container ( path ) fields = { } for name , value in container . _values . items ( ) : if isinstance ( value , str ) or isinstance ( value , list ) : fields [ name ] = value return fields
:param path: str or Path instance
        :return:
        :rtype: dict[str,str]
        :raises ValueError: A component of path is a field name.
        :raises KeyError: A component of path doesn't exist.