mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-19 09:33:53 +00:00
Log CLI version and git commit hash (v2) (#6176)
This commit is contained in:
@@ -30,6 +30,7 @@ import {
|
||||
} from '../../utils/user_account.js';
|
||||
import { getInstallationId } from '../../utils/user_id.js';
|
||||
import { FixedDeque } from 'mnemonist';
|
||||
import { GIT_COMMIT_INFO, CLI_VERSION } from '../../generated/git-commit.js';
|
||||
import { DetectedIde, detectIde } from '../../ide/detect-ide.js';
|
||||
|
||||
const start_session_event_name = 'start_session';
|
||||
@@ -374,6 +375,14 @@ export class ClearcutLogger {
|
||||
EventMetadataKey.GEMINI_CLI_START_SESSION_TELEMETRY_LOG_USER_PROMPTS_ENABLED,
|
||||
value: event.telemetry_log_user_prompts_enabled.toString(),
|
||||
},
|
||||
{
|
||||
gemini_cli_key: EventMetadataKey.GEMINI_CLI_VERSION,
|
||||
value: CLI_VERSION,
|
||||
},
|
||||
{
|
||||
gemini_cli_key: EventMetadataKey.GEMINI_CLI_GIT_COMMIT_HASH,
|
||||
value: GIT_COMMIT_INFO,
|
||||
},
|
||||
];
|
||||
|
||||
// Flush start event immediately
|
||||
|
||||
@@ -157,6 +157,12 @@ export enum EventMetadataKey {
|
||||
// Logs the session id
|
||||
GEMINI_CLI_SESSION_ID = 40,
|
||||
|
||||
// Logs the Gemini CLI version
|
||||
GEMINI_CLI_VERSION = 54,
|
||||
|
||||
// Logs the Gemini CLI Git commit hash
|
||||
GEMINI_CLI_GIT_COMMIT_HASH = 55,
|
||||
|
||||
// ==========================================================================
|
||||
// Loop Detected Event Keys
|
||||
// ===========================================================================
|
||||
|
||||
Reference in New Issue
Block a user