Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package ktop for openSUSE:Factory checked in at 2026-11-16 12:30:09 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ktop (Old) and /work/SRC/openSUSE:Factory/.ktop.new.1251 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ktop" Mon Nov 16 12:30:09 2026 rev:10 rq:1397846 version:0.7.1 Changes: -------- --- /work/SRC/openSUSE:Factory/ktop/ktop.changes 2026-11-07 23:35:57.601847644 +0100 +++ /work/SRC/openSUSE:Factory/.ktop.new.1251/ktop.changes 2026-11-16 12:31:12.546628522 +0100 @@ -1,0 +2,368 @@ +Mon Nov 16 05:48:25 UTC 2026 - Johannes Kastl <[email protected]> + +- Update to version 0.7.1: + ktop v0.7.1 introduces scriptable non-interactive (--noui) + execution for CI/CD gates, cron jobs, and telemetry pipelines, + incorporates OOMKilled and CrashLoopBackOff container states into + the composite 0–100 cluster health score alongside window-level + health_score_stats, and defines structured operational exit codes + (0–5) and log sink routing (--log). + Passing --noui bypasses terminal UI allocation, synchronizes + Kubernetes informers and initial Prometheus scrape cycles, and + writes indented single-document JSON (-o json) or line-delimited + streaming snapshots (-o jsonl) to stdout while keeping readiness + diagnostics on stderr (or suppressed with --quiet) and structured + logs in ~/.ktop/ktop.log. + * Non-Interactive (--noui) Collection & Output Pipeline + - Headless Application Runner and Synchronous Snapshot + Collector + - Problem / Context: ktop previously required an interactive + TTY (tview/tcell) to observe cluster state and metrics, + preventing automated scripts, CI deployment gates, and + headless jobs from capturing structured cluster snapshots. + - Implementation Details: Added package application/headless + (headless.NewRunner, headless.App, headless.Options in + application/headless/app.go) implementing + application.Runner without terminal screen dependencies, + backed by collector.Collector and + collector.K8sSnapshotProvider (collector/collector.go, + collector/k8s_provider.go). Added synchronous informer + startup (Controller.StartInformers in + k8s/client_controller.go), exported + Controller.BuildClusterSummary (k8s/summary_controller.go), + and added scrape-cycle synchronization + (Controller.WaitForCycles in prom/controller.go and + PromMetricsSource.WaitForWarmup in + metrics/prom/prom_source.go) so Prometheus counter rates + warm up across two completed scrape cycles before sampling. + - Impact & Behavioral Notes: Single-shot runs (-d 0s, + default) wait for core informer cache sync and metrics + warmup, emit one collector.Aggregate document (metadata, + cluster, summary, health_score_stats, nodes, pods), and + exit. Timed runs (-d > 0) sample every -i (--interval, + default 5s), include the ordered samples slice in -o json, + and handle SIGINT/SIGTERM cleanly by flushing all samples + collected prior to cancellation. When + --prometheus-scrape-interval is not explicitly set in + --noui mode, single-shot runs tune the internal scrape + cadence to 1500ms (or -i when smaller) so rate metrics warm + up promptly. + - JSON and Streaming JSONL Output Formatters + - Problem / Context: Automation consumers need both complete + end-of-window reports for post-deployment assertions and + real-time line-delimited streams for continuous pipelines. + - Implementation Details: Added package output + (output.Formatter, output.NewFormatter, + output.JSONFormatter, output.JSONLFormatter in + output/formatter.go, output/json.go, output/jsonl.go). + JSONFormatter encodes a single indented collector.Aggregate + document upon completion, while JSONLFormatter encodes one + minified snapshot.Snapshot line per interval tick with HTML + escaping disabled and immediate buffer flushing. + - Impact & Behavioral Notes: stdout receives strictly valid + JSON or JSONL with canonical numeric units (millis for CPU, + bytes for memory and storage, and 0.0–100.0 percentages for + PSI stall and CFS throttling). + * Cluster Health Score & Window Aggregations + - OOMKilled and CrashLoopBackOff Detection and HealthScoreStats + - Problem / Context: Pods in Running or Pending phase with + containers restarting due to OOMKilled or CrashLoopBackOff + were not reflected in the cluster summary's pod-failure + health score deduction, and multi-sample runs lacked + window-level health score summaries. + - Implementation Details: Added CrashLoopPods + (json:"crashloop_pods") to model.ClusterSummary + (views/model/summary_model.go) and snapshot.SummaryData + (internal/snapshot/snapshot.go, + internal/snapshot/builder.go). Updated + Controller.BuildClusterSummary (k8s/summary_controller.go) + to inspect both InitContainerStatuses and ContainerStatuses + for OOMKilled (State.Terminated and + LastTerminationState.Terminated) and CrashLoopBackOff + (State.Waiting), and updated model.CalculateHealthScore to + apply the -15 pod-health deduction when FailedPods > 0 || + OOMKillCount > 0 || CrashLoopPods > 0. Added + collector.HealthScoreStats (min, max, avg, latest) to + collector.Aggregate. + - APIs / Signatures: + + # Capture a single JSON snapshot + ktop --noui | jq . + + # Gate a CI pipeline on point-in-time health_score or OOM/crashloop counts + ktop --noui --quiet | jq -e '.summary.health_score >= 80 and .summary.oom_kill_count == 0 and .summary.crashloop_pods == 0' + + # Gate on sustained window statistics over a 30s soak period + ktop --noui -d 30s -i 5s --quiet | jq -e '.health_score_stats.min >= 70 and .health_score_stats.avg >= 85' + + # Stream minified JSONL snapshots every 5s + ktop --noui -d 5m -i 5s -o jsonl --quiet + + - Impact & Behavioral Notes: Both the interactive TUI Cluster + Summary header and --noui JSON/JSONL snapshots reflect + OOMKilled and CrashLoopBackOff containers in health_score, + while downstream scripts express custom pass/fail + thresholds against summary.health_score and + health_score_stats. + * CLI Flags, Logging Isolation & Operational Exit Codes + - Headless Flags, --log Destination Control, and Exit Codes 0–5 + - Problem / Context: Automated callers need deterministic + process exit codes to separate invalid flags from cluster + connectivity, missing metrics backends, and readiness + timeouts, as well as explicit control over stderr progress + output and structured log destinations. + - Implementation Details: Added --noui, -d/--duration, + -i/--interval, -o/--output, --quiet, and --log (file or + stderr) in cmd/ktop.go (NewKtopCmd), along with + logging.Validate (internal/logging/logger.go). Added + cmd/exitcode.go defining ExitOK (0), ExitGeneralError (1), + ExitInvalidFlags (2), ExitK8sConnectError (3), + ExitMetricsUnavailable (4), and ExitCollectionTimeout (5), + mapped via cmd.ExitError, cmd.WrapExitError, and + cmd.ExitCode in main.go. + - Impact & Behavioral Notes: Invalid CLI flags, negative + --duration, non-positive --interval, unsupported --output + formats, or unknown --log destinations fail before cluster + connection with exit code 2. API connection or RBAC + preflight failures return 3; unavailable explicitly + requested metrics sources (--metrics-source=prometheus or + --metrics-source=metrics-server) return 4; informer sync or + warmup timeouts (--request-timeout) return 5. + * Upgrade & Compatibility Notes + - Backward Compatibility: Fully backward compatible with + existing interactive ktop CLI invocations, kubectl ktop + plugin usage, kubeconfig setups, and ~/.ktop/config.yaml + files. Running ktop without --noui launches the interactive + terminal UI unchanged. + - Deprecations & Retractions: None. + - Migration Actions: None required. Note that CLI flag + validation errors now exit with status code 2 + (ExitInvalidFlags) rather than 1, and clusters with active + OOMKilled or CrashLoopBackOff containers now include the -15 + deduction in health_score. +- Update to version 0.7.0: + ktop v0.7.0 introduces an adaptive terminal theme engine with + automatic background luminance and color-depth detection, + refactors cluster state delivery around an immutable Snapshot + pipeline and application.Runner boundary, and aligns Prometheus + CPU rate and history calculations across overview and detail + views. + Operators can run ktop across dark, light, 16-color ANSI, and + $NO_COLOR / monochrome terminals without manual configuration, or + set explicit --theme and --color-mode preferences on the command + line and in ~/.ktop/config.yaml. Under the hood, overview tables + and drill-down detail views render from lock-free point-in-time + Snapshot projections, while the Prometheus metrics pipeline + preserves upstream cAdvisor sample timestamps and series + semantics to eliminate rate drift and transient 0m CPU drops. + * Adaptive Terminal Themes & UI Styling + - Semantic Palette Engine and Built-in Themes + - Problem / Context: UI widgets, tables, sparklines, + saturation gauges, and modal dialogs previously relied on + hardcoded colors tuned only for dark TrueColor terminals, + causing low-contrast text on light backgrounds, + inconsistent highlights on 16-color profiles, and residual + color escapes in monochrome sessions. + - Implementation Details: Added package ui/theme + (ui/theme/palette.go, ui/theme/builtins.go, + ui/theme/format.go) defining a 33-token semantic Palette + (CanvasBg, HeaderBg, RowSelectedBg, StatusOK..StatusError, + GaugeLow..GaugeHigh, SparklineNormal, + ToastInfoBg..ToastErrorBg, etc.) with four built-in themes: + DarkPalette, LightPalette, ANSIPalette, and + MonochromePalette. Migrated overview panels, + node/pod/container detail panels, sparklines, bargraphs, + filter inputs, help/column modals, and *ui.ToastModal + notifications (ui/toast.go) to resolve colors dynamically + from the active palette while maintaining WCAG AA contrast + (>= 4.5:1). + - Impact & Behavioral Notes: Tables, headers, summary + bargraphs, resource gauges, and interactive toast modals + (Retry / Quit actions and severity borders) render legibly + across all four built-in palettes. When monochrome (or + --color-mode=none) is active, ktop emits zero ANSI color + sequences and distinguishes focus, headers, selection, and + error states using AttrBold, AttrUnderline, AttrReverse, + and ! prefixes (ui.ErrorMarkup). + - Automatic Terminal Background Detection and 4-Tier Color + Quantization + - Problem / Context: Terminal emulators vary in background + luminance and color capability across local consoles, tmux, + SSH sessions, TERM=dumb, and $NO_COLOR environments. + - Implementation Details: Implemented theme.Resolve + (ui/theme/detect.go) with deterministic auto-detection + precedence: explicit theme override -> $NO_COLOR or + TERM=dumb (monochrome) -> $COLORFGBG background index + parsing (ParseCOLORFGBG) -> non-blocking 50ms OSC 11 + background query (ProbeTerminalLightBg / + ParseOSC11Luminance using ITU-R BT.709 relative luminance) + -> dark default. Implemented ResolveColor + (ui/theme/palette.go) to quantize 24-bit RGB palette tokens + to the 6x6x6 xterm-256 cube and 24-step grayscale ramp + (ColorMode256), nearest 16-color ANSI (ColorMode16), or + tcell.ColorDefault (ColorModeNone). + - Impact & Behavioral Notes: --theme=auto selects an + appropriate light, dark, or monochrome theme at startup + without blocking non-interactive streams or character + devices that do not support read deadlines, and + automatically maps palette tokens to the terminal's + supported color tier. + * CLI & Persistent Configuration + - --theme and --color-mode Flags and ~/.ktop/config.yaml Persistence + - Problem / Context: Users needed session-scoped CLI + overrides and persistent user defaults for theme selection + and terminal color-depth degradation. + - Implementation Details: Added --theme and --color-mode + flags in cmd/ktop.go (NewKtopCmd), validated by + config.NormalizeTheme and config.NormalizeColorMode + (config/config.go). Extended config.UIConfig (ui.theme, + ui.color_mode) in ~/.ktop/config.yaml with auto defaults. + - APIs / Signatures: + + # Automatic background and color-depth detection (default) + ktop + + # Force light or monochrome theme + ktop --theme=light + ktop --theme=monochrome + + # Override terminal color depth for SSH or multiplexer sessions + ktop --theme=dark --color-mode=256 + + # ~/.ktop/config.yaml + ui: + theme: auto + color_mode: auto + + - Impact & Behavioral Notes: Preferences configured under + ui.theme and ui.color_mode in ~/.ktop/config.yaml apply + automatically at startup; --theme and --color-mode + command-line flags override saved settings for the current + session without mutating the config file. Unrecognized + values exit immediately with a validation error listing + accepted options. + * Core Architecture & Data Pipeline + - Immutable Snapshot Model and Lock-Free SnapshotBuilder + - Problem / Context: Overview panels and resource detail + pages previously assembled view state separately from + mutable Kubernetes models, pointer-based resource.Quantity + fields, and live metrics lookups during draw cycles. + - Implementation Details: Added package internal/snapshot + (internal/snapshot/snapshot.go, + internal/snapshot/builder.go) defining value-type Snapshot, + ClusterInfo, SummaryData, NodeData, PodData, ContainerData, + and PSIData structs with deep-copy Clone() and indexed + accessors (NodeByName, PodByKey, PodsOnNode). Implemented + snapshot.Builder.Build for lock-free in-memory joins of + cached controller models and batch pod/container metrics, + alongside NodeDetailProjection, PodDetailProjection, and + ContainerUsageFromSnapshot. Updated overview + (views/overview) and detail panels (views/node, views/pod, + views/container) to render from Snapshot values and + projections. + - Impact & Behavioral Notes: Overview tables and detail pages + render from a unified point-in-time state representation + without performing network I/O or holding locks on the UI + draw goroutine. + - application.Runner Interface and application/tui Lifecycle + Package + - Problem / Context: Startup orchestration in cmd/ktop.go + directly coupled CLI flag parsing to tview page + construction, RBAC preflight checks, and terminal screen + initialization. + - Implementation Details: Defined the application.Runner + interface (Run(ctx context.Context) error, Stop() error in + application/app.go) and extracted interactive TUI + initialization into application/tui (tui.NewRunner, + tui.App, tui.Options in application/tui/app.go), + encapsulating theme resolution, overview layout, initial + column sorting, k8sC.AssertCoreAuthz(ctx), and minimum + terminal height checks. + - Impact & Behavioral Notes: Cleanly separates + command/configuration wiring from TUI execution while + preserving existing preflight authorization diagnostics and + exit behavior. + * Prometheus Metrics & Resource Reporting + - Upstream Timestamp Anchoring, Node CPU Series Selection, and + Fallback Alignment + - Problem / Context: Under Prometheus scraping, node CPU + metrics could disagree between Cluster Summary, the Nodes + table, and the Node Detail view when cAdvisor housekeeping + intervals exceeded the query window (causing transient 0m + drops), when local scrape timing jitter skewed counter rate + denominators, or when root cgroup (id="/") metrics exposed + both cpu="total" and per-core cpu="0".. series. + Additionally, valid 0m / 0Mi usage was treated as missing + usage data, causing views to fall back to displaying + requested resources instead of 0.0% used. ++++ 71 more lines (skipped) ++++ between /work/SRC/openSUSE:Factory/ktop/ktop.changes ++++ and /work/SRC/openSUSE:Factory/.ktop.new.1251/ktop.changes Old: ---- ktop-0.6.1.obscpio New: ---- ktop-0.7.1.obscpio ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ktop.spec ++++++ --- /var/tmp/diff_new_pack.tMmtNQ/_old 2026-11-16 12:31:15.602756942 +0100 +++ /var/tmp/diff_new_pack.tMmtNQ/_new 2026-11-16 12:31:15.605757068 +0100 @@ -17,7 +17,7 @@ Name: ktop -Version: 0.6.1 +Version: 0.7.1 Release: 0 Summary: A top-like tool for your Kubernetes clusters License: Apache-2.0 ++++++ _service ++++++ --- /var/tmp/diff_new_pack.tMmtNQ/_old 2026-11-16 12:31:15.661759421 +0100 +++ /var/tmp/diff_new_pack.tMmtNQ/_new 2026-11-16 12:31:15.665759589 +0100 @@ -3,7 +3,7 @@ <param name="url">https://github.com/vladimirvivien/ktop.git</param> <param name="scm">git</param> <param name="exclude">.git</param> - <param name="revision">refs/tags/v0.6.1</param> + <param name="revision">refs/tags/v0.7.1</param> <param name="versionformat">@PARENT_TAG@</param> <param name="changesgenerate">enable</param> <param name="versionrewrite-pattern">v(.*)</param> ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.tMmtNQ/_old 2026-11-16 12:31:15.707761354 +0100 +++ /var/tmp/diff_new_pack.tMmtNQ/_new 2026-11-16 12:31:15.714761648 +0100 @@ -3,6 +3,6 @@ <param name="url">https://github.com/vladimirvivien/ktop</param> <param name="changesrevision">741794d89c63c4e9898e31d14799317ee4aa7cfb</param></service><service name="tar_scm"> <param name="url">https://github.com/vladimirvivien/ktop.git</param> - <param name="changesrevision">3396f6f75f4e311576284447d0938056fb3aadef</param></service></servicedata> + <param name="changesrevision">6b351b69a64abdc75ac1979d5a279d88a8da6d4a</param></service></servicedata> (No newline at EOF) ++++++ ktop-0.6.1.obscpio -> ktop-0.7.1.obscpio ++++++ ++++ 14800 lines of diff (skipped) ++++++ ktop.obsinfo ++++++ --- /var/tmp/diff_new_pack.tMmtNQ/_old 2026-11-16 12:31:15.994773415 +0100 +++ /var/tmp/diff_new_pack.tMmtNQ/_new 2026-11-16 12:31:15.998773583 +0100 @@ -1,5 +1,5 @@ name: ktop -version: 0.6.1 -mtime: 1794009574 -commit: 3396f6f75f4e311576284447d0938056fb3aadef +version: 0.7.1 +mtime: 1794782601 +commit: 6b351b69a64abdc75ac1979d5a279d88a8da6d4a ++++++ vendor.tar.gz ++++++ /work/SRC/openSUSE:Factory/ktop/vendor.tar.gz /work/SRC/openSUSE:Factory/.ktop.new.1251/vendor.tar.gz differ: char 135, line 1
