{"record":{"id":"e63183448b3a7198","repo":"dagger/dagger","slug":"list-before-directories-w","errorCode":null,"errorMessage":"list before directories: %w","messagePattern":"list before directories: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/changeset.go","lineNumber":268,"sourceCode":"\t\t}\n\t\tif _, ok := seen[parent]; ok {\n\t\t\tcontinue\n\t\t}\n\t\tseen[parent] = struct{}{}\n\t\tcollapsed = append(collapsed, parent)\n\t}\n\treturn collapsed\n}\n\nfunc computeChangesetPaths(ctx context.Context, beforeDir, afterDir string) (*ChangesetPaths, error) {\n\tfc, err := compareDirectories(ctx, beforeDir, afterDir)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tbeforeDirs, err := listSubdirectories(beforeDir)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"list before directories: %w\", err)\n\t}\n\tafterDirs, err := listSubdirectories(afterDir)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"list after directories: %w\", err)\n\t}\n\taddedDirs, removedDirs := diffStringSlices(beforeDirs, afterDirs)\n\n\t// Expand renames into Added/Removed so addedPaths/removedPaths stay complete.\n\trenamedNew := make([]string, 0, len(fc.Renamed))\n\trenamedOld := make([]string, 0, len(fc.Renamed))\n\tfor newPath, oldPath := range fc.Renamed {\n\t\trenamedNew = append(renamedNew, newPath)\n\t\trenamedOld = append(renamedOld, oldPath)\n\t}\n\n\t// Sort to match computeChangesetPathsDelta: both paths must emit one\n\t// canonical order, or which order a caller observes silently depends on\n\t// whether the metadata delta walk succeeded on the underlying mounts.","sourceCodeStart":250,"sourceCodeEnd":286,"githubUrl":"https://github.com/dagger/dagger/blob/82ba2681dbe30d3547a1dc50ea495900ab5b6047/core/changeset.go#L250-L286","documentation":"computeChangesetPaths walks the mounted before-directory tree via listSubdirectories to find added/removed directories. This error fires when listing subdirectories of the before mount fails (I/O error on the bind-mounted snapshot), aborting path diff computation.","triggerScenarios":"Thrown at core/changeset.go:268 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the wrapped filesystem error on the mounted before directory","Retry; the mount is recreated per invocation","Verify the before snapshot ref is still valid and mountable"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"82ba2681dbe30d3547a1dc50ea495900ab5b6047","analyzedAt":"2026-09-05T07:21:37.930Z","contentChangedAt":"2026-09-05T07:21:37.930Z","schemaVersion":2},"datasetVersion":"2026-09-12T12:17:11.808Z"}