Skip to content

v1 fixes: OAuth functionality - part I #5247

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Apr 26, 2025
Merged

v1 fixes: OAuth functionality - part I #5247

merged 9 commits into from
Apr 26, 2025

Conversation

FeodorFitsner
Copy link
Contributor

@FeodorFitsner FeodorFitsner commented Apr 26, 2025

Summary by Sourcery

Refactor OAuth functionality to be fully asynchronous, removing synchronous methods and simplifying the API. Improve event handling and update related components.

Bug Fixes:

  • Correct OAuth callback handling in FletOAuth to invoke the method on the page instance.
  • Ensure did_mount is called for controls added via Session.get_page_patch.
  • Add error handling for missing control IDs in Session.handle_invoke_method_results.

Enhancements:

  • Remove synchronous OAuth methods (login, request_token, _fetch_user, _fetch_groups, etc.) across Page, Authorization, and providers.
  • Refactor asynchronous OAuth methods (login_async, request_token_async, etc.) to use httpx.AsyncClient directly.
  • Simplify OAuth authorization flow initiation in Page.login_async.
  • Improve event dispatch handling in various connection types using asyncio.create_task.
  • Update Page.run_task and Page.run_thread to use the connection event loop.
  • Refactor internal Page update methods related to mount/unmount handling.

Build:

  • Update dependencies in poetry.lock.

Chores:

  • Remove debug print statement from Dart SharedPreferencesService.

@FeodorFitsner FeodorFitsner merged commit 5abc6e0 into v1 Apr 26, 2025
1 of 2 checks passed
@FeodorFitsner FeodorFitsner deleted the feodor/v1-oauth branch April 26, 2025 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant