mirror of
https://github.com/kuhyx/wake-alarm.git
synced 2026-11-10 19:27:02 +01:00
The inline `_DeviceCodeDialog` (86 lines) was byte-for-byte identical to diet-guard's, and `services/github_device_auth.dart` was a fourth copy of the auth client. Both now come from `github_device_auth` in the kuhyx/utils monorepo. This app's client was not merely a drifted copy -- it carried a fix the other three lacked: `pollForToken` swallowed a transient socket failure and kept polling, because GitHub can close the connection at the exact moment the user authorizes. Extracting todo's version would have silently deleted that. The package took this behaviour instead, so the fix now protects all four apps rather than just this one. It is expressed as `on http.ClientException` rather than the local `SocketException` arm, because the package is also imported by diet-guard's **web** build where `dart:io` will not compile. Verified that nothing is lost: package:http wraps a dead socket as `_ClientSocketException`, which implements both types. 19 tests pass, analyze clean, and the release APK is installed on the phone and launching. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01U4Rj3s7K2qzrLNgJqqPhno
33 lines
710 B
YAML
33 lines
710 B
YAML
include: package:very_good_analysis/analysis_options.yaml
|
|
|
|
analyzer:
|
|
language:
|
|
strict-casts: true
|
|
strict-inference: true
|
|
strict-raw-types: true
|
|
errors:
|
|
missing_required_param: error
|
|
unnecessary_null_comparison: error
|
|
dead_code: error
|
|
invalid_annotation_target: error
|
|
exclude:
|
|
- build/**
|
|
- android/**
|
|
- ios/**
|
|
- web/**
|
|
- windows/**
|
|
- macos/**
|
|
- linux/**
|
|
|
|
linter:
|
|
rules:
|
|
always_use_package_imports: true
|
|
avoid_print: true
|
|
avoid_relative_lib_imports: true
|
|
cancel_subscriptions: true
|
|
close_sinks: true
|
|
directives_ordering: true
|
|
lines_longer_than_80_chars: true
|
|
public_member_api_docs: true
|
|
unawaited_futures: true
|