xworkmate-app/lib/runtime/embedded_agent_launch_policy.dart
Haitao Pan d3b6585bd5 refactor(bridge): enforce remote bridge execution and remove local ACP fallbacks
- Prioritize remote endpoints for svc.plus accounts.
- Remove legacy local go-core execution logic.
- Remove legacy local codex app-server launch logic.
- Update endpoint resolution to support provider-specific paths.
2026-04-21 12:35:52 +08:00

28 lines
794 B
Dart

import '../app/app_store_policy.dart';
/// Decides whether to block embedded agent process launching based on platform policy.
///
/// In the cloud-neutral bridge model, local process launching is generally disabled.
bool shouldBlockEmbeddedAgentLaunch({
required bool isAppleHost,
bool? enabled,
}) {
// Always apply policy which blocks local execution in restricted environments.
// In the current architecture, we've moved to bridge-mediated execution.
return shouldApplyAppleAppStorePolicy(
isAppleHost: isAppleHost,
enabled: enabled,
);
}
/// Helper for Go core launch blocking check.
bool shouldBlockGoCoreLaunch({
required bool isAppleHost,
bool? enabled,
}) {
return shouldBlockEmbeddedAgentLaunch(
isAppleHost: isAppleHost,
enabled: enabled,
);
}