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

Re: [PATCH v2] index-pack: clarify the breached limit

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Feb 24, 2022, 00:14 UTC
Message-ID
<220224.86wnhl9ky8.gmgdl@evledraar.gmail.com>
In-Reply-To
<pull.1158.v2.git.1645661240356.gitgitgadget@gmail.com>
On Thu, Feb 24 2022, Matt Cooper via GitGitGadget wrote:
Show 5 quoted lines
> From: Matt Cooper <vtbassmatt@gmail.com>
> [...]
> +test_expect_success 'too-large packs report the breach' '
> +	pack=$(git pack-objects --all pack </dev/null) &&
> +	sz="$(test_file_size pack-$pack.pack)" &&

I don't think this needs a re-roll, but FWIW I have an old-ish local patch I haven't submitted yet to s/test_file_size/test-tool path-utils file-size/g in the test suite.

I.e. we've been moving more in the direction of using test-tool directly, which some tests already do in that case, with some using test_file_size.

> +	test "$sz" -gt 20 &&
> +	test_must_fail git index-pack --max-input-size=20 pack-$pack.pack 2>err &&
> +	grep "maximum allowed size (20 bytes)" err
> +'

Maybe this is covered by another test, but in case we don't have a test for this error already: This doesn't cover that we don't error on packs smaller than the limit, so in terms of black-box testing it's indistinguishable from us erroring out about this all the time.

But that's probably too paranoid in the first place, and maybe we do have that other test...

Previous: Matt Cooper via GitGitGadget
Message 9 of 9 in “Specify the actual pack size limit which is breached”
  1. 0/2 Specify the actual pack size limit which is breachedMatt Cooper via GitGitGadget, Feb 23, 2022
  2. 1/2 index-pack: clarify the breached limitMatt Cooper via GitGitGadget, Feb 23, 2022
  3. 2/2 t5302: confirm that large packs mention limitMatt Cooper via GitGitGadget, Feb 23, 2022
  4. Taylor BlauFeb 23, 2022
  5. Junio C HamanoFeb 23, 2022
  6. Taylor BlauFeb 23, 2022
  7. Taylor BlauFeb 23, 2022
  8. index-pack: clarify the breached limitMatt Cooper via GitGitGadget, Feb 24, 2022
  9. Ævar Arnfjörð BjarmasonFeb 24, 2022

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.