Attribute reader shutdown failures to checks that read content
This commit is contained in:
@@ -19,6 +19,7 @@ type CandidateTree struct {
|
||||
byPath map[string]int
|
||||
directories map[string]struct{}
|
||||
blobReader *git.BlobReader
|
||||
blobReads uint64
|
||||
symlinkTargets map[string]string
|
||||
closed bool
|
||||
closeErr error
|
||||
@@ -113,6 +114,7 @@ func (tree *CandidateTree) readBlob(ctx context.Context, entry git.TreeEntry) ([
|
||||
}
|
||||
tree.blobReader = git.NewBlobReader(operationContext, tree.repositoryDir)
|
||||
}
|
||||
tree.blobReads++
|
||||
contents, err := tree.blobReader.Read(ctx, entry.ObjectID)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("read committed path %q: %w", entry.Path, err)
|
||||
|
||||
Reference in New Issue
Block a user