Remove Grok OAuth and legacy BYOK support

This commit is contained in:
Ryan Ward
2026-07-28 02:30:22 -05:00
parent 2faeed7ac5
commit 87e0c83e9e
26 changed files with 153 additions and 4140 deletions
-18
View File
@@ -1498,23 +1498,6 @@ pub(crate) fn initialize_app(
if FeatureFlag::GeminiEnterprise.is_enabled() {
manager.subscribe_to_geap_settings_changes(ctx);
}
// The Grok subscription refresher (`ai::grok_subscription`) has no
// visibility into workspace policy, so wire the BYO API key policy in
// here. The initial value resumes proactive refresh of any tokens
// restored from secure storage; TeamsChanged keeps the policy aligned
// as team data loads or the workspace changes.
#[cfg(not(target_family = "wasm"))]
if FeatureFlag::SuperGrok.is_enabled() {
use crate::workspaces::user_workspaces::UserWorkspacesEvent;
ctx.subscribe_to_model(&UserWorkspaces::handle(ctx), |manager, _, event, ctx| {
if matches!(event, UserWorkspacesEvent::TeamsChanged) {
let allowed = UserWorkspaces::as_ref(ctx).is_byo_api_key_enabled(ctx);
manager.set_grok_refresh_allowed(allowed, ctx);
}
});
let allowed = UserWorkspaces::as_ref(ctx).is_byo_api_key_enabled(ctx);
manager.set_grok_refresh_allowed(allowed, ctx);
}
manager
});
@@ -2393,7 +2376,6 @@ pub(crate) fn app_callbacks(
if let Some(initialization) = tracing_initialization.as_mut() {
initialization.shutdown();
}
})),
on_should_close_window: Some(Box::new(move |window_id, ctx| {
let general_settings = GeneralSettings::as_ref(ctx);