From 0d625ccea7ffdbb014d9de171278d5ce34ee071f Mon Sep 17 00:00:00 2001 From: Sebastian Malton Date: Fri, 3 Mar 2023 16:24:17 -0500 Subject: [PATCH] Improve logging after refresh accessibility Signed-off-by: Sebastian Malton --- packages/core/src/common/cluster/cluster.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/core/src/common/cluster/cluster.ts b/packages/core/src/common/cluster/cluster.ts index bfa6c0f612..91aa9ee609 100644 --- a/packages/core/src/common/cluster/cluster.ts +++ b/packages/core/src/common/cluster/cluster.ts @@ -26,6 +26,7 @@ import type { RequestApiResources } from "../../main/cluster/request-api-resourc import type { DetectClusterMetadata } from "../../main/cluster-detectors/detect-cluster-metadata.injectable"; import type { FalibleOnlyClusterMetadataDetector } from "../../main/cluster-detectors/token"; import { withConcurrencyLimit } from "../utils/with-concurrency-limit"; +import { inspect } from "util"; export interface ClusterDependencies { readonly directoryForKubeConfigs: string; @@ -498,7 +499,10 @@ export class Cluster implements ClusterModel { this.allowedResources.replace(await this.getAllowedResources(requestNamespaceListPermissions)); this.ready = this.knownResources.length > 0; - this.dependencies.logger.info(`[CLUSTER]: refreshed accessibility data`, this.getState()); + this.dependencies.logger.info(`[CLUSTER]: refreshed accessibility data: %s`, inspect(this.getState(), { + colors: true, + depth: Infinity, + })); } /**