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

Re: [PATCH 7/7] t: invert `GIT_TEST_WRITE_REV_INDEX`

From
Taylor Blau <me@ttaylorr.com>
Date
Apr 11, 2023, 21:33 UTC
Message-ID
<ZDXSHal5IBynUTMX@nand.local>
In-Reply-To
<18a54c6e-7357-42ca-779f-2ba3e6653880@github.com>
On Tue, Apr 11, 2023 at 09:51:06AM -0400, Derrick Stolee wrote:
Show 10 quoted lines
> On 4/10/2023 6:53 PM, Taylor Blau wrote:
> > Instead of getting rid of the option, invert its meaning to instead
> > disable writing ".rev" files, thereby running the test suite in a mode
> > where the reverse index is generated from scratch.
> >
> > This ensures that we are still running and exercising Git's behavior
> > when forced to generate reverse indexes from scratch.
>
> I don't think this is true because you remove the environment
> variable from the following test.

This is intentional; I wrote that last sentence ("This ensures...") with an implied "[When set], this ensures..." at the beginning of it. IOW, if you wanted to run the test suite with primarily in-memory reverse indexes, you still could.

Show 14 quoted lines
> Replacing the line with GIT_TEST_NO_WRITE_REV_INDEX=1 would keep us
> testing the from-scratch case as a side-effect in other tests.
>
> > diff --git a/ci/run-build-and-tests.sh b/ci/run-build-and-tests.sh
> > index b098e10f52..e9fbfb6345 100755
> > --- a/ci/run-build-and-tests.sh
> > +++ b/ci/run-build-and-tests.sh
> > @@ -27,7 +27,6 @@ linux-TEST-vars)
> >  	export GIT_TEST_MULTI_PACK_INDEX=1
> >  	export GIT_TEST_MULTI_PACK_INDEX_WRITE_BITMAP=1
> >  	export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=master
> > -	export GIT_TEST_WRITE_REV_INDEX=1
> >  	export GIT_TEST_CHECKOUT_WORKERS=2
> >  	;;

I wasn't quite sure what to do here. On one hand, sticking GIT_TEST_NO_WRITE_REV_INDEX=1 here would ensure that the linux-TEST-vars test is still exercising the old code.

Is that desirable? I dunno. On one hand it increases our coverage, but on the other hand I've always treated this suite as for experimental features, not older ones.

But I think all things being equal, I'd rather have more CI coverage than not, so I'll add it back in. Thanks for a sanity check on this one.

Thanks, Taylor

Previous: Derrick StoleeNext: Derrick Stolee
Message 16 of 29 in “pack-revindex: enable on-disk reverse indexes by default”
  1. 0/7 pack-revindex: enable on-disk reverse indexes by defaultTaylor Blau, Apr 10, 2023
  2. 1/7 pack-write.c: plug a leak in stage_tmp_packfiles()Taylor Blau, Apr 10, 2023
  3. Derrick StoleeApr 11, 2023
  4. Taylor BlauApr 11, 2023
  5. 2/7 t5325: mark as leak-freeTaylor Blau, Apr 10, 2023
  6. 3/7 pack-revindex: make `load_pack_revindex` take a repositoryTaylor Blau, Apr 10, 2023
  7. Derrick StoleeApr 11, 2023
  8. Taylor BlauApr 11, 2023
  9. Derrick StoleeApr 12, 2023
  10. 4/7 pack-revindex: introduce GIT_TEST_REV_INDEX_DIE_ON_DISKTaylor Blau, Apr 10, 2023
  11. 5/7 pack-revindex: introduce `pack.readReverseIndex`Taylor Blau, Apr 10, 2023
  12. 6/7 config: enable `pack.writeReverseIndex` by defaultTaylor Blau, Apr 10, 2023
  13. Junio C HamanoApr 13, 2023
  14. 7/7 t: invert `GIT_TEST_WRITE_REV_INDEX`Taylor Blau, Apr 10, 2023
  15. Derrick StoleeApr 11, 2023
  16. Taylor BlauApr 11, 2023
  17. Derrick StoleeApr 12, 2023
  18. Derrick StoleeApr 11, 2023
  19. Taylor BlauApr 11, 2023
  20. Derrick StoleeApr 12, 2023
  21. 0/7 pack-revindex: enable on-disk reverse indexes by defaultTaylor Blau, Apr 12, 2023
  22. 1/7 pack-write.c: plug a leak in stage_tmp_packfiles()Taylor Blau, Apr 12, 2023
  23. 2/7 t5325: mark as leak-freeTaylor Blau, Apr 12, 2023
  24. 3/7 pack-revindex: make `load_pack_revindex` take a repositoryTaylor Blau, Apr 12, 2023
  25. 4/7 pack-revindex: introduce GIT_TEST_REV_INDEX_DIE_ON_DISKTaylor Blau, Apr 12, 2023
  26. 5/7 pack-revindex: introduce `pack.readReverseIndex`Taylor Blau, Apr 12, 2023
  27. 7/7 t: invert `GIT_TEST_WRITE_REV_INDEX`Taylor Blau, Apr 12, 2023
  28. 6/7 config: enable `pack.writeReverseIndex` by defaultTaylor Blau, Apr 12, 2023
  29. Derrick StoleeApr 13, 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.