Skip to content

Commit

Permalink
Merge branch 'main' into symlinked-packages-work
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Jun 18, 2023
2 parents e50ebd7 + 1c4b328 commit 67662d8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions importlib_metadata/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -992,12 +992,12 @@ def _get_toplevel_name(name: PackagePath) -> str:
'foo'
>>> _get_toplevel_name(PackagePath('foo.pyc'))
'foo'
>>> _get_toplevel_name(PackagePath('foo.dist-info'))
'foo.dist-info'
>>> _get_toplevel_name(PackagePath('foo.pth'))
'foo.pth'
>>> _get_toplevel_name(PackagePath('foo/__init__.py'))
'foo'
>>> _get_toplevel_name(PackagePath('foo.pth'))
'foo.pth'
>>> _get_toplevel_name(PackagePath('foo.dist-info'))
'foo.dist-info'
"""
return _topmost(name) or (
# python/typeshed#10328
Expand Down

0 comments on commit 67662d8

Please sign in to comment.