diff --git a/lang/golang/parser/pkg.go b/lang/golang/parser/pkg.go index 7481650b..7137b1fe 100644 --- a/lang/golang/parser/pkg.go +++ b/lang/golang/parser/pkg.go @@ -245,6 +245,10 @@ func (p *GoParser) loadPackages(mod *Module, dir string, pkgPath PkgPath) (err e if skip { continue } + if filePath == "" { + fmt.Fprintf(os.Stderr, "filename is empty, pkg: %s\n", pkg.ID) + continue + } bs := p.getFileBytes(filePath) ctx := &fileContext{ repoDir: p.homePageDir,