mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-28 22:14:52 -07:00
Add interactive ValidationDialog for handling 403 VALIDATION_REQUIRED errors. (#16231)
This commit is contained in:
@@ -67,7 +67,10 @@ import {
|
||||
ApprovalModeSwitchEvent,
|
||||
ApprovalModeDurationEvent,
|
||||
} from '../telemetry/types.js';
|
||||
import type { FallbackModelHandler } from '../fallback/types.js';
|
||||
import type {
|
||||
FallbackModelHandler,
|
||||
ValidationHandler,
|
||||
} from '../fallback/types.js';
|
||||
import { ModelAvailabilityService } from '../availability/modelAvailabilityService.js';
|
||||
import { ModelRouterService } from '../routing/modelRouterService.js';
|
||||
import { OutputFormat } from '../output/types.js';
|
||||
@@ -477,6 +480,7 @@ export class Config {
|
||||
private readonly _enabledExtensions: string[];
|
||||
private readonly enableExtensionReloading: boolean;
|
||||
fallbackModelHandler?: FallbackModelHandler;
|
||||
validationHandler?: ValidationHandler;
|
||||
private quotaErrorOccurred: boolean = false;
|
||||
private readonly summarizeToolOutput:
|
||||
| Record<string, SummarizeToolOutputSettings>
|
||||
@@ -1066,6 +1070,14 @@ export class Config {
|
||||
return this.fallbackModelHandler;
|
||||
}
|
||||
|
||||
setValidationHandler(handler: ValidationHandler): void {
|
||||
this.validationHandler = handler;
|
||||
}
|
||||
|
||||
getValidationHandler(): ValidationHandler | undefined {
|
||||
return this.validationHandler;
|
||||
}
|
||||
|
||||
resetTurn(): void {
|
||||
this.modelAvailabilityService.resetTurn();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user