GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Android Sample app problem with Leaked Window when Permission request is refused · Issue #57 · googleapis/google-http-java-client

Android Sample app problem with Leaked Window when Permission request is refused #57

New issue
Copy link
New issue
Copy link
Closed
Closed
Android Sample app problem with Leaked Window when Permission request is refused#57
Copy link
Assignees
JustinBeckwith
Labels
🚨This issue needs some love.priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Description

@wonderfly
wonderfly
opened on Jan 9, 2015
Issue body actions

From [email protected] on December 30, 2011 13:40:09

Affects: all versions of google-http-java-client (problem is with the sample apps)

Java environment (Android 4.x)

when you start the sample Android app the account picker dialog is displayed as usual. If you select an account and then pick 'No, thanks' at the Account Manager generated Permission Request dialog the app crashes with a leaked window. If you select 'Allow access' the app proceeds as designed.

It looks like the app is failing when trying to redisplay the account picker dialog. It's not an API bug but a problem with the sample app. Here is my LogCat of the failure:

LogCat showing problem is attached.

Attachment: log.txt

Original issue: http://code.google.com/p/google-http-java-client/issues/detail?id=57

Activity

  1. wonderfly
    added
    imported
    Priority-High
    2–5 stars
    Type-Sample
    on Jan 9, 2015
  2. wonderfly
    self-assigned this
    on Jan 9, 2015
  3. wonderfly commented on Jan 9, 2015

    @wonderfly
    wonderfly
    on Jan 9, 2015
    ContributorAuthor
    More actions

    From [email protected] on January 04, 2012 09:16:11

    Labels: -Type-Defect -Priority-Medium Type-Sample Priority-High

  4. wonderfly commented on Jan 9, 2015

    @wonderfly
    wonderfly
    on Jan 9, 2015
    ContributorAuthor
    More actions

    From [email protected] on January 04, 2012 09:34:37

    fyi I spent some more time on this yesterday.

    The problem is not at the manager.getAuthToken(account, AUTH_TOKEN_TYPE, true, null, null).getResult(); line which seems to fire normally....instead the issue occurs when startActivityForResult(intent, REQUEST_AUTHENTICATE); is called.

    For some reason rather than going into onPause() and waiting for the response from the Permission request dialog the UI thread goes straight through onStop() and onDestroy(). If the back key is pressed in the Permission request dialog or 'No thanks' selected then the activity reinitializes and everything goes nuts.

    Posting the symptoms on Android Developer got a response from another dev who could NOT replicate the problem but who was using emulator rather than physical device....so I guess it could possibly be a setup issue.

    I've managed to reproduce the problem on various levels of the SDK (8, 13, 14, 15) and using Eclipse v3.5 and 3.7. Exactly the same code works fine with Honeycomb or lower devices.

    In my own app I've put in a rather kludgy workaround that sets a Boolean in the default preferences just before the startActivityForResult() is called and avoids restarting the auth process in onCreate() if that Boolean is set. The Boolean is cleared in onActivityResult(). This seems to work fine.

  5. wonderfly
    removed their assignment
    on May 20, 2016
  6. ejona86
    added
    type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.
    docs
    on Feb 22, 2017
  7. mattwhisenhunt
    added
    priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.
    and removed
    Priority-High
    on Dec 11, 2017
  8. JustinBeckwith
    closed this as completedon Jun 6, 2018
  9. yoshi-automation
    added
    🚨This issue needs some love.
    on Apr 6, 2020
  10. JustinBeckwith
    self-assigned this
    on Feb 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @JustinBeckwith
    JustinBeckwith

Labels

🚨This issue needs some love.priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.