'Return a dataset\'s path if available.
:param UUID dataset_id: The dataset to lookup.
:return: ``Deferred`` that fires with the mountpoint ``FilePath``,
``None`` if the dataset is not locally mounted, or errbacks
with ``_NotFound`` if it is does not exist at all.'

def _get_path_from_dataset_id(self, dataset_id):

    d = self._flocker_client.list_datasets_state()
    def got_state(datasets):
        datasets = [dataset for dataset in datasets if (dataset.dataset_id == dataset_id)]
        if (datasets and (datasets[0].primary == self._node_id)):
            return datasets[0].path
        else:
            return None
    d.addCallback(got_state)
    return d
