Repository navigation
Explain how package and installed CLI entry points share a callable - #2205
Closed
cloudgpuapp wants to merge 1 commit into
Closed
cloudgpuapp wants to merge 1 commit into
cloudgpuapp wants to merge 1 commit into
Conversation
Contributor
|
Closing, AI spam. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The command-line tools guide already shows a
__main__.pywrapper and a[project.scripts]entry, but it leaves the package layout guidance as a TODO.Explain the import and
python -mroles of the two special files using theexisting example, show where to import the shared CLI callable, and link to
Python's
__main__documentation for more detail.Addresses #1508 using the scoped approach suggested in the issue discussion.
Validation:
python -m sphinx -b html -W --keep-going source _build/htmlpassed on Python 3.13.18 with the project's pinned Sphinx 9.2.0. Extracted and
executed the guide's Python snippets with Typer 0.12.3.
python -m greetingsand the configured script callable printed the same greeting. Importing the
package and its entry module produced no CLI output.
git diff --checkpassed.AI assistance was used to prepare and test this documentation change.
📚 Documentation preview 📚: https://python-packaging-user-guide--2205.org.readthedocs.build/en/2205/