Skip to content

"no connected devices" when we see an unauthorized device #6538

Description

@Hixie

We shouldn't say "no connected devices" if we see an unauthorized device.

$ flutter run
Device 0012bae55d88a1be is not authorized.
You might need to check your device for an authorization dialog.
No connected devices.

Activity

  1. added
    toolAffects the "flutter" command-line tool. See also t: labels.
    on Oct 26, 2016
  2. added this to the milestone on Oct 26, 2016
  3. srsudar commented on Aug 17, 2018

    @srsudar

    What do you think the simplest fix is for this? Based on where this call is printed in flutter_command.dart, other 0-device cases are handled like this:

        } else if (devices.isEmpty && deviceManager.hasSpecifiedAllDevices) {
          printStatus('No devices found');
          return null;
        }

    However, I don't currently see anything like deviceManager.devicePendingAuthorization in DeviceManager.

    I could see either:

    1. Adding a method like devicePendingAuthorization to DeviceManager.
    2. Simply changing No connected devices to No available devices.

    Number 2 seems less thorough but just as accurate. There's no need to add an additional 'authorized device' state if this error message is the only place that needs it, I would argue.

    What do you think?

  4. Hixie commented on Aug 18, 2018

    @Hixie
    ContributorAuthor

    I wouldn't necessarily aim for the simplest fix, but I agree with you that there's nothing really gained from doing anything more involved than just changing the message in this case.

  5. srsudar commented on Aug 27, 2018

    @srsudar

    I meant simple in a good way, fwiw.

    However, I can't repro the output you show above. Do you mean also for the output of flutter devices, as shown below?

    $ flutter --version
    Flutter 0.7.1-pre.30 • channel master • [email protected]:srsudar/flutter.git
    Framework • revision 7f0f938de7 (12 hours ago) • 2018-08-27 11:11:14 +0200
    Engine • revision af42b6dc95
    Tools • Dart 2.1.0-dev.1.0.flutter-ccb16f7282
    
    $ flutter run
    No connected devices.
    
    $ flutter devices
    No devices detected.
    
    Run 'flutter emulators' to list and start any available device emulators.
    
    Or, if you expected your device to be detected, please run "flutter doctor" to diagnose
    potential issues, or visit https://flutter.io/setup/ for troubleshooting tips.
    
    • Device 01abfc49119c410e is not authorized.
      You might need to check your device for an authorization dialog.
    
    
  6. Hixie commented on Aug 28, 2018

    @Hixie
    ContributorAuthor

    It's possible this has improved since the original bug was filed.

  7. zoechi commented on Jan 17, 2019

    @zoechi
    Contributor

    Related #13047

  8. oycx commented on May 14, 2019

    @oycx

    we met the same question, Have you solved it?

  9. modified the milestones: , on Jan 7, 2020
  10. added
    P3Issues that are less important to the Flutter project
    on May 29, 2020
  11. 6 remaining items

  12. removed this from the milestone on Jul 22, 2020
  13. removed this from the milestone on Aug 17, 2020
  14. self-assigned this
    on Jul 24, 2023
  15. github-actions commented on Aug 11, 2023

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  16. locked as resolved and limited conversation to collaborators on Aug 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P3Issues that are less important to the Flutter projecta: qualityA truly polished experienceteam-toolOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.triaged-toolTriaged by Flutter Tool teamwaiting for PR to land (fixed)A fix is in flight

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions