You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 41c7a8f
Browse filesBrowse the repository at this point in the historyBrowse files
[flutter_tools] Remove AzureDetector IMDS probe from BotDetector (flutter#194530)
Remove `AzureDetector` (`http://169.254.169.254/metadata/instance`) and
persistent `is-bot` caching (`PersistentToolState.isRunningOnBot` /
`setIsRunningOnBot`) from `BotDetector`, relying strictly on
deterministic CI environment variables.
- **Remove IMDS probe and disk cache (`bot_detector.dart`,
`persistent_tool_state.dart`)**: Eliminates the link-local HTTP probe on
tool startup, prevents cloud developer workstations on Azure/GCE/AWS
from being permanently misclassified as bots in `.flutter_tool_state`,
and removes unused `httpClientFactory` and `persistentToolState`
parameters from `BotDetector`.
- **Tighten `BOT` and `CI` environment checks (`bot_detector.dart`)**:
Treat `BOT=false` and `BOT=0` as explicit non-bot overrides, require
`CI` to be non-empty and not `'false'` or `'0'`, accept `BOT=true` or
`BOT=1`, and check `AZURE_HTTP_USER_AGENT` alongside `TF_BUILD`
(matching `dartdev`).
- **Async getter retention**: `Future<bool> get isRunningOnBot` is
intentionally kept async (`Future<bool>`) in this PR to avoid churn
across the 12 production `await` sites and `FakeBotDetector` in tests;
once `package:unified_analytics` rolls with `Analytics.isBot(Map<String,
String> environment)` (tracked in
dart-lang/tools#2672 /
dart-lang/tools#2687), a follow-up PR for
flutter#194405 can delegate directly
or simplify callers if desired.
Part of flutter#194405
0 commit comments