libgit2 / libgit2/libgit2sharp
Out of memory error when identifying changed files. The repository has over 4 lakh files.
Nessuno ha ancora preso questa issue.
- Lingua principale
- C#
- Stelle
- 3.5k
- Fork
- 925
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Out of memory error while trying to find the changes in a repo.
Reproduction steps
Finding out untracked/modified files in the repo with over 4 lakh files is causing out of memory error.
Expected behavior
It should be optimized for memory use while trying to find out changes.
Actual behavior
out of memory error in the code below.
Class: Index
Method : AllIndexEntries( )
It is enumerating all entries and tries to fill the list, instead it could have been implemented as callback to reduce the memory pressure.
Version of LibGit2Sharp (release number or SHA1)
0.26.2
Operating system(s) tested; .NET runtime tested
Windows 10, .NET 4.8
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia dal metodo Index.AllIndexEntries menzionato nel report e traccia il codice che enumera i file non tracciati e modificati. Riproduci il comportamento con un repository contenente oltre 400.000 file, quindi verifica che il rilevamento delle modifiche non esaurisca più la memoria, mantenendo invariati i risultati dei file segnalati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- csharp, git
- Ambito
- tooling
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 42/100