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

Re: [PATCH v3 3/3] ls-files: use and update the untracked cache

From
AGAniket Gupta <aniketgupta3001@gmail.com>
Date
Nov 20, 2026, 17:24 UTC
Message-ID
<20261120172420.47728-1-aniketgupta3001@gmail.com>
In-Reply-To
<20261023-ls-files-untracked-cache-v3-3-292260e95f53@gmail.com>
Hi Tamir,
Thanks for working on this.
> +	 * With index.skipHash, the checksum cannot detect concurrent index
> +	 * changes. Lock the index before reading it.

With core.untrackedCache=true and a cold cache this holds index.lock for the whole scan, so a concurrent git add will fail. With 60k untracked files, a background "git ls-files -o --exclude-standard" and "git add new1" 30ms later give

    fatal: Unable to create '.git/index.lock': File exists.

master doesnt do this and cmd_status() locks only after collecting. Does the lock need to be taken before reading? verify_index_from() seems to handle skipHash and locking after fill_directory() is working except for the t7519 skiphash test.

Previous: Tamir Duberstein
Message 14 of 14 in “ls-files: reuse the untracked cache”
  1. 0/2 ls-files: reuse the untracked cacheTamir Duberstein, Sep 23, 2026
  2. 1/2 dir: hash ignore files before adding parser LFTamir Duberstein, Sep 23, 2026
  3. 2/2 ls-files: reuse cached untracked listingsTamir Duberstein, Sep 23, 2026
  4. Tamir DubersteinSep 23, 2026
  5. 0/3 ls-files: reuse and update the untracked cacheTamir Duberstein, Sep 23, 2026
  6. 1/3 dir: hash ignore files before appending newlineTamir Duberstein, Sep 23, 2026
  7. 2/3 dir: share untracked caches across output modesTamir Duberstein, Sep 23, 2026
  8. 3/3 ls-files: use and update the untracked cacheTamir Duberstein, Sep 23, 2026
  9. Tamir DubersteinOct 23, 2026
  10. 0/3 ls-files: reuse and update the untracked cacheTamir Duberstein, Oct 23, 2026
  11. 1/3 dir: hash ignore files before appending newlineTamir Duberstein, Oct 23, 2026
  12. 2/3 dir: share untracked caches across output modesTamir Duberstein, Oct 23, 2026
  13. 3/3 ls-files: use and update the untracked cacheTamir Duberstein, Oct 23, 2026
  14. Aniket GuptaNov 20, 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.