diff --git a/cli/genpolicy/genpolicy.go b/cli/genpolicy/genpolicy.go index 21af4a3af..8adfce53d 100644 --- a/cli/genpolicy/genpolicy.go +++ b/cli/genpolicy/genpolicy.go @@ -62,7 +62,7 @@ func (r *Runner) Run(ctx context.Context, yamlPath string, logger *slog.Logger) genpolicy := exec.CommandContext(ctx, r.genpolicy.Path(), args...) genpolicy.Env = os.Environ() if _, hasRustLog := os.LookupEnv("RUST_LOG"); !hasRustLog { - genpolicy.Env = append(genpolicy.Env, "RUST_LOG=info") + genpolicy.Env = append(genpolicy.Env, "RUST_LOG=debug") } if _, hasRustBacktrace := os.LookupEnv("RUST_BACKTRACE"); !hasRustBacktrace { genpolicy.Env = append(genpolicy.Env, "RUST_BACKTRACE=1") diff --git a/cli/genpolicy/logtranslator.go b/cli/genpolicy/logtranslator.go index 8587f5c3d..8f7d58534 100644 --- a/cli/genpolicy/logtranslator.go +++ b/cli/genpolicy/logtranslator.go @@ -51,7 +51,9 @@ func (l logTranslator) startTranslate() { l.logger.Error(match[3], "position", match[2]) case "WARN": l.logger.Warn(match[3], "position", match[2]) - case "INFO": // prints quite a lot, only show on debug + case "INFO": + fallthrough // prints quite a lot, only show on debug + case "DEBUG": l.logger.Debug(match[3], "position", match[2]) } }