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

[PATCH 0/6] some "commit-graph verify" fixes for chains

From
Jeff King <peff@peff.net>
Date
Sep 26, 2023, 05:54 UTC
Message-ID
<20230926055452.GA1341109@coredump.intra.peff.net>

While yak-shaving another topic, I noticed that there are a bunch of error cases that "git commit-graph verify" does not notice when checking chained graph files. This series should make it more robust.

Some of these cases are actually covered in t5324 already, but the tests expect the verify command not to fail, which just seems wrong. I don't see anything in the commit message or mailing list explaining it, so I think it was just "well, this is how it behaves now", and not some clever scheme.

  [1/6]: commit-graph: factor out chain opening function
  [2/6]: commit-graph: check mixed generation validation when loading chain file
  [3/6]: t5324: harmonize sha1/sha256 graph chain corruption
  [4/6]: commit-graph: detect read errors when verifying graph chain
  [5/6]: commit-graph: tighten chain size check
  [6/6]: commit-graph: report incomplete chains during verification
 builtin/commit-graph.c        |  31 +++++++---
 commit-graph.c                | 109 ++++++++++++++++++++++------------
 commit-graph.h                |   4 ++
 t/t5324-split-commit-graph.sh |  48 +++++++++++++--
 4 files changed, 141 insertions(+), 51 deletions(-)
-Peff
PS If you are curious about the yak-shave, it is:
     3. "commit-graph verify" fails to propagate some errors (this
	series)
     2. we are missing a bunch of bounds checks on commit-graph files;
	fixing that makes the tests inconsistent because of (3)
     1. there are some unused parameters that should be used for bounds
	checks, hence (2)
  Just in case anybody thought there was a part of my life that was not
  motivated by removing -Wunused-parameter warnings.
Next: Jeff King
Message 1 of 16 in “some "commit-graph verify" fixes for chains”
  1. 0/6 some "commit-graph verify" fixes for chainsJeff King, Sep 26, 2023
  2. 1/6 commit-graph: factor out chain opening functionJeff King, Sep 26, 2023
  3. 2/6 commit-graph: check mixed generation validation when loading chain fileJeff King, Sep 26, 2023
  4. 3/6 t5324: harmonize sha1/sha256 graph chain corruptionJeff King, Sep 26, 2023
  5. 4/6 commit-graph: detect read errors when verifying graph chainJeff King, Sep 26, 2023
  6. 5/6 commit-graph: tighten chain size checkJeff King, Sep 26, 2023
  7. 6/6 commit-graph: report incomplete chains during verificationJeff King, Sep 26, 2023
  8. Jeff KingSep 28, 2023
  9. 0/6 some "commit-graph verify" fixes for chainsJeff King, Sep 28, 2023
  10. 1/6 commit-graph: factor out chain opening functionJeff King, Sep 28, 2023
  11. 2/6 commit-graph: check mixed generation validation when loading chain fileJeff King, Sep 28, 2023
  12. 3/6 t5324: harmonize sha1/sha256 graph chain corruptionJeff King, Sep 28, 2023
  13. 4/6 commit-graph: detect read errors when verifying graph chainJeff King, Sep 28, 2023
  14. 5/6 commit-graph: tighten chain size checkJeff King, Sep 28, 2023
  15. 6/6 commit-graph: report incomplete chains during verificationJeff King, Sep 28, 2023
  16. Taylor BlauOct 5, 2023

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.