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 — gh-97669: Remove outdated example scripts (#97675) by vstinner · Pull Request #98167 · python/cpython

Conversation

@vstinner

@vstinner vstinner commented Oct 10, 2022 •
edited by bedevere-bot
Loading

Uh oh!

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

Copy link
Copy Markdown
Member

Remove outdated example scripts of the Tools/scripts/ directory:

  • gprof2html.py
  • md5sum.py
  • nm2def.py
  • pathfix.py
  • win_add2path.py

Remove test_gprof2html, test_md5sum and test_pathfix of test_tools.

  • Issue: Remove outdated Tools/scripts/ example scripts #97669

Sorry, something went wrong.

Uh oh!

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

CAM-Gerlach reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@vstinner
gh-97669: Remove outdated example scripts (#97675)
0597500
Remove outdated example scripts of the Tools/scripts/ directory:

* gprof2html.py
* md5sum.py
* nm2def.py
* pathfix.py
* win_add2path.py

Remove test_gprof2html, test_md5sum and test_pathfix of test_tools.
@vstinner vstinner added the skip news label Oct 10, 2022
@vstinner
vstinner requested review from a team and tiran as code owners October 10, 2022 22:37
@bedevere-bot bedevere-bot added the awaiting core review label Oct 10, 2022
@vstinner

vstinner commented Oct 10, 2022

Copy link
Copy Markdown
Member Author

gprof2html.py

Created in 2002 by @gvanrossum. Following changes are mostly coding styles changes, no feature or bugfix.

I didn't use gprof format for a long time. There are now many tools to profile programs with nice UI. I don't think that maintaining such tool in Python with a HTML output is still relevant today.

md5sum.py

If someone wants such feature as part of Python, I would suggest to add a command line interface (CLI) to the hashlib module instead.

The script doesn't support multithreading, whereas Python releases the GIL in hashlib. The script uses the old getopt module.

@gvanrossum wrote in 2001:

This is a trivial command line utility to print MD5 checksums.
I published it on the web as http://www.python.org/2.1/md5sum.py
so I thought I might as well check it in.

Well, I don't think that it's still relevant in 2022. There are now many ways to easily distribute Python scripts (pip, GitHub, whatever works).

nm2def.py

Helpers to extract symbols from Unix libs and auto-generate
Windows definition files from them. Depends on nm(1). Tested
on Linux and Solaris only (-p option to nm is for Solaris only).

@malemburg: if you still use this script, it should be maintained outside Python. Python doesn't use it.

pathfix.py

@hroncok: Script used by Fedora, see: https://discuss.python.org/t/remove-outdated-tools-scripts-scripts/19571/35

It can be maintained somewhere else.

win_add2path.py

Not used by the Windows installer: https://discuss.python.org/t/remove-outdated-tools-scripts-scripts/19571/20

All reactions

Sorry, something went wrong.

Uh oh!

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

@vstinner vstinner mentioned this pull request Oct 10, 2022
Remove outdated Tools/scripts/ example scripts #97669
Closed
gvanrossum
gvanrossum approved these changes Oct 11, 2022
View reviewed changes

@gvanrossum gvanrossum left a comment

Copy link
Copy Markdown
Member

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.

Kill 'em with fire!

Sorry, something went wrong.

Uh oh!

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

All reactions
@bedevere-bot bedevere-bot added awaiting merge and removed awaiting core review labels Oct 11, 2022
@vstinner
Fix test_tools on Windows
5619918
@vstinner
vstinner merged commit e0ae9dd into python:main Oct 11, 2022
@bedevere-bot bedevere-bot removed the awaiting merge label Oct 11, 2022
@vstinner
vstinner deleted the remove_scripts2 branch October 11, 2022 08:08
This was referenced Nov 30, 2022
Make win_add2path.py take effect without having to log off #74559
Closed
bpo-30374: Fixed several bugs in win_add2path.py #1645
Closed
@learnwithsomya

learnwithsomya commented Aug 26, 2026

Copy link
Copy Markdown

Hi @vstinner ,
Is there any alternate ways to use the pathfix.py or patch updates for consuming the file? Refer: https://gitlab.com/redhat/centos-stream/rpms/python3.14/-/blob/c10s/python3.14.spec?ref_type=heads#L1325

hroncok reacted with confused emoji
All reactions
  • 😕 1 reaction

Sorry, something went wrong.

Uh oh!

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

@gvanrossum

gvanrossum commented Aug 27, 2026

Copy link
Copy Markdown
Member

Is there any alternate ways to use the pathfix.py or patch updates for consuming the file?

Yes, by copying the script out of an old branch into your repo.

All reactions

Sorry, something went wrong.

Uh oh!

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

@vstinner

vstinner commented Aug 31, 2026

Copy link
Copy Markdown
Member Author

Is there any alternate ways to use the pathfix.py or patch updates for consuming the file? Refer: https://gitlab.com/redhat/centos-stream/rpms/python3.14/-/blob/c10s/python3.14.spec?ref_type=heads#L1325

The python3.14.spec that you linked refers to %{_rpmconfigdir}/redhat/pathfix.py which gets pathfix.py from /usr/lib/rpm/redhat/pathfix.py. The file is installed by python-rpm-macros on my Fedora. So pathfix.py is now maintained by the python-rpm-macros project.

The CentOS Stream package doesn't get pathfix.py from Python but from python-rpm-macros.

All reactions

Sorry, something went wrong.

Uh oh!

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

@vstinner

vstinner commented Aug 31, 2026 •
edited
Loading

Uh oh!

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

Copy link
Copy Markdown
Member Author

Update: Ah, in fact pathfix.py is maintained in the fedora-python/pathfix repository.

All reactions

Sorry, something went wrong.

Uh oh!

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@gvanrossum gvanrossum gvanrossum approved these changes
@tiran tiran Awaiting requested review from tiran

Uh oh!

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

Assignees

No one assigned

Labels

skip news

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

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

4 participants

@vstinner @learnwithsomya @gvanrossum @bedevere-bot
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.