Skip to content

Do not use shallow clones for source-repository-packages#10619

Closed
9999years wants to merge 2 commits into
haskell:masterfrom
9999years:fix-10605
Closed

Do not use shallow clones for source-repository-packages#10619
9999years wants to merge 2 commits into
haskell:masterfrom
9999years:fix-10605

Conversation

@9999years
Copy link
Copy Markdown
Collaborator

Fixes #10605

Includes a regression test.

@philderbeast
Copy link
Copy Markdown
Collaborator

philderbeast commented Dec 7, 2024

I checked out this branch, installed cabal-install from it and reran a timing test against amazonka, same as #10605 (comment). This gives slow results. I ran it twice after cleaning and got 82s and 84s. I reran the same test twice using cabal-install from the master branch, at 1f52963, and got times of, 16s each time.

@9999years
Copy link
Copy Markdown
Collaborator Author

@philderbeast Yes, that's what I'm expecting. It might be possible to keep the shallow clone behavior in some cases without introducing regressions, but let's fix the regressions first.

@alt-romes
Copy link
Copy Markdown
Collaborator

alt-romes commented Dec 13, 2024

I've commented this in #10605 (comment), but to re-iterate here:

It seems to me that we can easily fix the regression by only reverting to the previous behaviour (full clones) when the hash is not given in full. For all other users using the full hash, we keep the happy fast path.

@9999years
Copy link
Copy Markdown
Collaborator Author

@alt-romes That seems reasonable, although I do worry (as with all roll-forward fixes) that we'll be introducing another bug or missing some edge case as we do so. Would you put up a PR for it?

@alt-romes
Copy link
Copy Markdown
Collaborator

@alt-romes That seems reasonable, although I do worry (as with all roll-forward fixes) that we'll be introducing another bug or missing some edge case as we do so. Would you put up a PR for it?

I can appreciate that concern, and still think the cost of being that conservative here seems quite high. Since the regression seems well define, let's try fixing it specifically. I'll make a PR, including your regression test.

@alt-romes
Copy link
Copy Markdown
Collaborator

Closing in favor of #10639

@alt-romes alt-romes closed this Dec 13, 2024
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.

New git invocation changes the behaviour of source-repository-package

3 participants