def install(self, candidate: Candidate) -> Distribution:
        """Install a candidate into the environment, return the distribution"""
        prepared = candidate.prepare(self.environment)
        dist_info = install_wheel(
            prepared.build(),
            self.environment,
            direct_url=prepared.direct_url(),
            install_links=self.use_install_cache and not candidate.req.editable,
            rename_pth=self.rename_pth,
            requested=candidate.requested,
        )
        return Distribution.at(dist_info)
Install a candidate into the environment, return the distribution
src/pdm/installers/manager.py