git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v4 0/3] refs: report old OIDs for batched deletions

From
Maciej Ciemborowicz <maciej.ciemborowicz@gmail.com>
Date
Sep 23, 2026, 12:49 UTC
Message-ID
<20260923124931.39424-1-maciej.ciemborowicz@gmail.com>
In-Reply-To
<CAOLa=ZTN1TU2A1sgEhiw=ymMYr6Ge11cMEubSaeKqr4WNU=2EQ@mail.gmail.com>
Hi Junio,
> Can we avoid REF_TRANSACTION_FLAG_SKIP_HOOK by changing the call chain
> instead of exposing a general mechanism for skipping hooks?

I looked into that, but I do not think it removes the distinction cleanly. The packed-refs transaction is an internal, physical part of one logical files-backend update: it needs the normal transaction machinery, while the reference-transaction hook must observe only the outer logical update.

Restructuring the call chain would either duplicate the prepare/finish/abort lifecycle or hide the same hook-suppression decision in a less explicit helper. I do agree that this should not be a public escape hatch, though. I will keep it internal to the refs implementation and limit its use to these internal transactions.

> Should the int copy parameter simply be bool copy, given that the
> function has only two modes?

Yes, agreed. It is a two-state mode, so bool copy expresses the contract more clearly. I will change it in the next reroll.

Thanks, Maciej

Previous: Maciej Ciemborowicz
Message 35 of 35 in “[BUG] reference-transaction hook misses destination of git branch -m”
  1. Maciej CiemborowiczSep 19, 2026
  2. Karthik NayakSep 19, 2026
  3. refs: run copy and rename through transactionsMaciej Ciemborowicz, Sep 20, 2026
  4. Junio C HamanoSep 21, 2026
  5. Junio C HamanoSep 21, 2026
  6. Maciej CiemborowiczSep 22, 2026
  7. refs: run copy and rename through transactionsMaciej Ciemborowicz, Sep 23, 2026
  8. Maciej CiemborowiczSep 30, 2026
  9. Patrick SteinhardtOct 2, 2026
  10. Maciej CiemborowiczOct 2, 2026
  11. Patrick SteinhardtOct 5, 2026
  12. 0/4 refs: run copy and rename through transactionsMaciej Ciemborowicz, Oct 7, 2026
  13. 1/4 refs: distinguish internal transactions from logical updatesMaciej Ciemborowicz, Oct 7, 2026
  14. 2/4 refs: support replacing reflogs in a transactionMaciej Ciemborowicz, Oct 7, 2026
  15. 3/4 refs: run copy and rename through ordinary transactionsMaciej Ciemborowicz, Oct 7, 2026
  16. 4/4 refs: remove backend-specific copy and rename callbacksMaciej Ciemborowicz, Oct 7, 2026
  17. Junio C HamanoOct 7, 2026
  18. 0/4 refs: run copy and rename through transactionsMaciej Ciemborowicz, Oct 8, 2026
  19. 1/4 refs: distinguish internal transactions from logical updatesMaciej Ciemborowicz, Oct 8, 2026
  20. 2/4 refs: support replacing reflogs in a transactionMaciej Ciemborowicz, Oct 8, 2026
  21. 3/4 refs: run copy and rename through ordinary transactionsMaciej Ciemborowicz, Oct 8, 2026
  22. 4/4 refs: remove backend-specific copy and rename callbacksMaciej Ciemborowicz, Oct 8, 2026
  23. Patrick SteinhardtOct 8, 2026
  24. Maciej CiemborowiczOct 8, 2026
  25. Maciej CiemborowiczOct 8, 2026
  26. Junio C HamanoOct 8, 2026
  27. Maciej CiemborowiczOct 8, 2026
  28. Kristoffer HaugsbakkOct 8, 2026
  29. Maciej CiemborowiczOct 8, 2026
  30. Patrick SteinhardtOct 9, 2026
  31. brian m. carlsonOct 10, 2026
  32. Junio C HamanoOct 8, 2026
  33. Karthik NayakOct 9, 2026
  34. Maciej CiemborowiczOct 10, 2026
  35. Maciej CiemborowiczSep 23, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.