Update uninstall package link pointer path
@@ -526,7 +526,9 @@ class UninstallPathSet:
# PEP 660 modern editable is handled in the ``.dist-info`` case
# above, so this only covers the setuptools-style editable.
with open(develop_egg_link) as fh:
- link_pointer = os.path.normcase(fh.readline().strip())
+ link_pointer = os.path.normcase(
+ os.path.realpath(fh.readline().strip())
+ )
assert link_pointer == dist_location, (
f"Egg-link {link_pointer} does not match installed location of "
f"{dist.raw_name} (at {dist_location})"
