code: def _wrap_exceptions(repo, url):
      from dvc.config import NoRemoteError
      from dvc.exceptions import (
          NoOutputInExternalRepoError,
          NoRemoteInExternalRepoError,
      )
  
      try:
          yield
      except NoRemoteError as exc:
          raise NoRemoteInExternalRepoError(url) from exc
      except OutputNotFoundError as exc:
          if exc.repo is repo:
              raise NoOutputInExternalRepoError(
                  exc.output, repo.root_dir, url
              ) from exc
          raise
      except FileMissingError as exc:
          raise PathMissingError(exc.path, url) from exc
  
file_path: dvc/dvc/api/data.py
imports: from contextlib import _GeneratorContextManager
  from contextlib import contextmanager
  from typing import Any, Dict, Optional
  from funcy import reraise
  from dvc.exceptions import FileMissingError, OutputNotFoundError, PathMissingError
  from dvc.repo import Repo
label_desc: Use image node_id 1 for calling a global function with example usage: _wrap_exceptions(repo, url) without return types