GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Create shortcut executables from registered entrypoints by zooba · Pull Request #225 · python/pymanager

Conversation

@zooba

@zooba zooba commented Nov 25, 2025

Copy link
Copy Markdown
Member

Fixes #121

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
zooba added 12 commits November 20, 2025 23:28
@zooba
[WIP] Start implementation of entrypoint support
fc64f28
@zooba
[WIP] Updated, implemented, and existing tests pass
8b83213
@zooba
Add test
7ff8626
@zooba
Improved script and fixed names
1263c28
@zooba
Fix tests
fc4793f
@zooba
Fix tests
bd20de5
@zooba
Add tests to improve coverage
36118d8
@zooba
More test coverage
81808f3
@zooba
Minor refactor, improved test coverage
2a3839b
@zooba
Remove unused import
16a60c1
@zooba
Add comment and update scratch key
52d27a7
@zooba
Add some missing log messages
e05fbad
@zooba
zooba marked this pull request as ready for review November 27, 2025 20:01
zooba added 2 commits November 27, 2025 20:27
@zooba
Minor bug fixes
e621dd4
@zooba
Properly handle launching script executable (not DLL)
5916e76
@zooba

zooba commented Dec 1, 2025

Copy link
Copy Markdown
Member Author

This won't be merged until after the next release, so it'll go out in 2026. The likelihood of it needing follow-up fixes is too high to do it right before the Christmas break.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

zooba added 13 commits December 2, 2025 13:41
@zooba
Ensure pip.exe exists
5be8d04
@zooba
Merge main
0a3924e
@zooba
Add welcome message
2069514
@zooba
Add refresh step to entrypoint test
fddc8cc
@zooba
Fix paths
c67f0e5
@zooba
Minor refactoring on alias creation
7f24d36
@zooba
Fix calls
ea6d7c7
@zooba
Merge main
935ab05
@zooba
Refactor and simplify code for aliases
198a73f
@zooba
Improved edge case handling and test
2eec6d2
@zooba
Update args
a36f76a
@zooba
Remove some dead code
fb9b7c0
@zooba
Naming conventions
13c57b7
@zooba
zooba requested a review from Copilot December 9, 2025 21:07
Copilot started reviewing on behalf of zooba December 9, 2025 21:07
View session
Copilot AI reviewed Dec 9, 2025
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds functionality to automatically create executable shortcuts from registered Python entrypoints (e.g., pip, pytest) found in installed packages. The implementation scans dist-info directories for entry_points.txt files, parses console_scripts and gui_scripts sections, and creates wrapper executables that launch these scripts through the appropriate Python runtime.

Key Changes:

  • New aliasutils module handles entrypoint scanning, alias calculation, and executable creation
  • Refactored install_command to delegate alias management to the new module
  • Enhanced launcher.cpp to support executing Python scripts via .__script__.py companion files
  • Fixed Path.stem and Path.suffix properties to handle multi-dot filenames correctly

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 16 comments.

Show a summary per file
File Description
src/manage/aliasutils.py New module implementing entrypoint scanning, alias creation, and cleanup logic
src/manage/install_command.py Refactored to use new aliasutils module; improved error handling for missing imports
src/manage/pathutils.py Fixed stem/suffix properties to correctly handle filenames without extensions
src/manage/exceptions.py Added NoLauncherTemplateError exception
src/pymanager/launcher.cpp Added get_script() to detect and inject script files into argv
src/pymanager/_launch.cpp Updated launch() signature to accept original command line and insert_args
src/pymanager/main.cpp Updated launch() call with new signature
tests/test_alias.py Comprehensive tests for new alias functionality
tests/test_install_command.py Updated tests for refactored preserve_site function
tests/test_pathutils.py Added tests for stem/suffix edge cases

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread src/pymanager/launcher.cpp Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/pymanager/launcher.cpp Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/manage/aliasutils.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/pymanager/_launch.cpp Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/pymanager/_launch.cpp Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread tests/test_alias.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread tests/test_alias.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/manage/aliasutils.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/manage/aliasutils.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread src/manage/aliasutils.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

zooba added 2 commits December 9, 2025 21:41
@zooba
Fixes and improvements suggested by reviewer
42b51bb
@zooba
Split names before testing
753b295
@zooba

zooba commented Dec 9, 2025

Copy link
Copy Markdown
Member Author

Going to merge now as I'm happy enough, and have pretty thoroughly tested scenarios I can think of, and there are no releases planned until next year. So it may as well sit in main and get more exercise. If we need to patch the current release again, we'll just have to branch before this.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@zooba
zooba merged commit e4a4451 into python:main Dec 9, 2025
4 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@zooba
zooba deleted the gh-121 branch December 9, 2025 23:09
@zooba zooba mentioned this pull request Dec 10, 2025
Is it stable to use for Python and Python packages installation? #233
Closed
@zooba zooba mentioned this pull request Jan 19, 2026
Create an App Execution Alias for pip to py -m pip #140
Closed
1 of 2 tasks
@Punisheroot Punisheroot mentioned this pull request Sep 10, 2026
The pip and py/python aliases refer to different installations whenever PYTHON_MANAGER_DEFAULT is anything but the most recent full release available. #413
Closed
1 of 4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

Copilot code review Copilot
Copilot review effort
Applies to this pull request for everyone.Learn more about Copilot code review.
Copilot left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Include pip in path

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@zooba
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.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.