agent: is enabled passes on a disabled Radio, CupertinoButton, Slider or DropdownButton (controls the agent cannot read)

Open
#864 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
dart, flutter
Domain
mobile, testing

Research direction

Start with _controlDisabled in probe_agent/lib/src/executor.dart and compare its supported controls with the disabled Radio, CupertinoButton, Slider and DropdownButton cases in the issue. Read the linked plan in #857 and the related discussion in #861 to understand the measured Semantics approach and its limitation for CupertinoButton. Done means disabled-state checks no longer silently pass for controls the agent cannot read.

Written by the indexing model from the issue text.

Description

bug

Symptom

see #id is enabled passes on a disabled control the agent cannot read, in every position: the control as the target itself, a wrapper around it, or a text inside it. don't see #id is disabled passes too. That's a silent false pass with the current agent on plain Flutter apps.

Reported in the review of #861. The reader (_controlDisabled in probe_agent/lib/src/executor.dart) knows only ButtonStyleButton (the elevated, filled, outlined and text buttons), IconButton, FloatingActionButton, TextField, Switch and Checkbox. Every other control falls back to "not disabled", including:

  • a disabled Radio;
  • a CupertinoButton(onPressed: null);
  • a Slider(onChanged: null);
  • a DropdownButton(onChanged: null);
  • chips, SegmentedButton, PopupMenuButton, CupertinoSlider and others.

Related: with #861, a wrapper holding a disabled button and an enabled Slider reads as disabled (the slider is ignored). A wrapper holding an enabled button and a disabled Slider reads as enabled, which is wrong for the slider.

Fix

The library-neutral plan in #857 (reading enabled from the Semantics each control builds) covers these controls. It was measured for the buttons, text fields, switches, checkboxes, radios and chips, on the framework and on material_ui. CupertinoButton builds no enabled value, so the plan refuses rather than guesses there. Until then, a smaller step could refuse is enabled/is disabled on a known unread control.

Dominant language
Go
Stars
6
Forks
3
Avg merge
6h 28m
Merged PRs (30d)
362

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from AlphaWaveSystems/flutter-probe

All issues in AlphaWaveSystems/flutter-probe

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.