MaikuB / MaikuB/flutter_appauth

App killed when android phone too aggressive in memory preservation, authorizeAndExchangeCode not completed

Open
#635 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Objective-C
Stars
308
Forks
301
Avg merge
2d 11h
Merged PRs (30d)
5

Description

Hi,

on some Android phones that employ overly aggressive memory management, we are encountering an issue. While the in-app browser is displayed (presenting the Keycloak interface to complete the login flow), the operating system may decide to terminate (kill) the app in the background to conserve memory.

Consequently, by the time the login process completes, the app is relaunched from a cold start, and the login state (e.g., session data) is lost.

What is a possible workaround for this situation?

Thanks

Contributor guide

Open the contributing guide

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.

Research direction

Start with the authorizeAndExchangeCode flow described in the issue and review how Android cold starts affect the in-app browser login. No source files or tests are named, so trace the relaunch path first. Done means the login can complete or recover its state after the app is killed during authentication.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, dart, flutter
Domain
authentication, mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.