Skip to content

Reuse existing checkouts for pinned commits - #495

Open
maurycy wants to merge 2 commits into
python:mainfrom
maurycy:fix-git-clone-sha
Open

maurycy wants to merge 2 commits into
python:mainfrom
maurycy:fix-git-clone-sha

Conversation

@maurycy

@maurycy maurycy commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

git.clone() currently compares a full commit SHA with the abbreviated hash returned by get_git_hash(). This causes an existing checkout at the requested commit to be deleted and cloned again. The PR compares the full SHA instead and adds a regression test.

@savannahostrowski savannahostrowski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hmmm, I’m trying to understand where reuse happens in practice, though. The standard workflows use actions/checkout with cleanup enabled by default, and I can see it removing cpython/, pyperformance/, and pyston-benchmarks/ in my runner logs at the start of each job. Is there a particular workflow where you’re seeing unnecessary re-cloning?

@maurycy

maurycy commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor Author

@savannahostrowski Not really, found through code inspection, not runner logs. Fine to close if you want!

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants