Content-Length: 253813 | pFad | http://www.togithub.com/googleapis/google-auth-library-python-oauthlib/issues/276

2AF1 InstalledAppFlow.run_local_server does not raise expected error on timeout · Issue #276 · googleapis/google-auth-library-python-oauthlib · GitHub
Skip to content

InstalledAppFlow.run_local_server does not raise expected error on timeout #276

Open
@juhhov

Description

@juhhov

Environment details

  • OS type and version: Ubuntu 20.04
  • Python version: Python 3.10.10
  • pip version: pip 23.0.1
  • google-auth-oauthlib version: Version: 1.0.0

Steps to reproduce

  1. Start authentication flow using InstalledAppFlow
  2. Once browser is opened do not proceed but close browser
  3. Wait for timeout to trigger
  4. AttributeError: 'NoneType' object has no attribute 'replace' is raised instead of expected timeout specific error

Code example

flow = InstalledAppFlow.from_client_secrets_file(
    client_secrets_file=client_secret_file,
    scopes=['https://www.googleapis.com/auth/userinfo.email', 'openid', 'https://www.googleapis.com/auth/userinfo.profile'])
return flow.run_local_server(
    host='localhost',
    port=port,
    authorization_prompt_message='Please visit this URL: {url}',
    success_message='The auth flow is complete; you may close this window.',
    open_browser=True,
    timeout_seconds=20)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions









      ApplySandwichStrip

      pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


      --- a PPN by Garber Painting Akron. With Image Size Reduction included!

      Fetched URL: http://www.togithub.com/googleapis/google-auth-library-python-oauthlib/issues/276

      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy