Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-google-auth-oauthlib for
openSUSE:Factory checked in at 2023-03-07 16:50:55
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-google-auth-oauthlib (Old)
and /work/SRC/openSUSE:Factory/.python-google-auth-oauthlib.new.31432
(New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-google-auth-oauthlib"
Tue Mar 7 16:50:55 2023 rev:13 rq:1069914 version:1.0.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-google-auth-oauthlib/python-google-auth-oauthlib.changes
2023-01-05 15:01:26.097204374 +0100
+++
/work/SRC/openSUSE:Factory/.python-google-auth-oauthlib.new.31432/python-google-auth-oauthlib.changes
2023-03-07 16:51:22.169911722 +0100
@@ -1,0 +2,8 @@
+Tue Mar 7 10:38:03 UTC 2023 - John Paul Adrian Glaubitz
<[email protected]>
+
+- Update to 1.0.0
+ * PKCE is enabled by default. (#269)
+ * Change the library from preview to stable (#267)
+ * Remove deprecated OOB code (1391486)
+
+-------------------------------------------------------------------
Old:
----
google-auth-oauthlib-0.8.0.tar.gz
New:
----
google-auth-oauthlib-1.0.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-google-auth-oauthlib.spec ++++++
--- /var/tmp/diff_new_pack.TP8fvI/_old 2023-03-07 16:51:22.737914717 +0100
+++ /var/tmp/diff_new_pack.TP8fvI/_new 2023-03-07 16:51:22.753914802 +0100
@@ -19,7 +19,7 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%bcond_without python2
Name: python-google-auth-oauthlib
-Version: 0.8.0
+Version: 1.0.0
Release: 0
Summary: Google authentication library
License: Apache-2.0
++++++ google-auth-oauthlib-0.8.0.tar.gz -> google-auth-oauthlib-1.0.0.tar.gz
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/google-auth-oauthlib-0.8.0/PKG-INFO
new/google-auth-oauthlib-1.0.0/PKG-INFO
--- old/google-auth-oauthlib-0.8.0/PKG-INFO 2022-12-12 22:57:51.401111100
+0100
+++ new/google-auth-oauthlib-1.0.0/PKG-INFO 2023-02-07 21:53:17.732518700
+0100
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: google-auth-oauthlib
-Version: 0.8.0
+Version: 1.0.0
Summary: Google Authentication Library
Home-page:
https://github.com/GoogleCloudPlatform/google-auth-library-python-oauthlib
Author: Google Cloud Platform
@@ -14,7 +14,7 @@
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
-Classifier: Development Status :: 3 - Alpha
+Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: POSIX
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/flow.py
new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/flow.py
--- old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/flow.py 2022-12-12
22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/flow.py 2023-02-07
21:50:41.000000000 +0100
@@ -52,7 +52,6 @@
import hashlib
import json
import logging
-import warnings
try:
from secrets import SystemRandom
@@ -70,11 +69,6 @@
_LOGGER = logging.getLogger(__name__)
-_OOB_REDIRECT_URIS = [
- "urn:ietf:wg:oauth:2.0:oob",
- "urn:ietf:wg:oauth:2.0:oob:auto",
- "oob",
-]
class Flow(object):
@@ -103,7 +97,7 @@
client_config,
redirect_uri=None,
code_verifier=None,
- autogenerate_code_verifier=False,
+ autogenerate_code_verifier=True,
):
"""
Args:
@@ -214,17 +208,8 @@
@redirect_uri.setter
def redirect_uri(self, value):
- if value in _OOB_REDIRECT_URIS:
- warnings.warn(
- "'{}' is an OOB redirect URI. The OAuth out-of-band (OOB) flow
is deprecated. "
- "New clients will be unable to use this flow starting on Feb
28, 2022. "
- "This flow will be deprecated for all clients on Oct 3, 2022. "
- "Migrate to an alternative flow. "
- "See
https://developers.googleblog.com/2022/02/making-oauth-flows-safer.html?m=1#disallowed-oob".format(
- value
- ),
- DeprecationWarning,
- )
+ """The OAuth 2.0 redirect URI. Pass-through to
+ ``self.oauth2session.redirect_uri``."""
self.oauth2session.redirect_uri = value
def authorization_url(self, **kwargs):
@@ -370,8 +355,6 @@
https://github.com/googleapis/google-api-python-client/blob/main/docs/oauth-installed.md
"""
- _OOB_REDIRECT_URI = "urn:ietf:wg:oauth:2.0:oob"
-
_DEFAULT_AUTH_PROMPT_MESSAGE = (
"Please visit this URL to authorize this application: {url}"
)
@@ -385,63 +368,6 @@
"The authentication flow has completed. You may close this window."
)
- def run_console(
- self,
- authorization_prompt_message=_DEFAULT_AUTH_PROMPT_MESSAGE,
- authorization_code_message=_DEFAULT_AUTH_CODE_MESSAGE,
- **kwargs
- ):
- """Run the flow using the console strategy.
-
- .. deprecated:: 0.5.0
- Use :meth:`run_local_server` instead.
-
- The OAuth out-of-band (OOB) flow is deprecated. New clients will be
unable to
- use this flow starting on Feb 28, 2022. This flow will be deprecated
- for all clients on Oct 3, 2022. Migrate to an alternative flow.
-
- See
https://developers.googleblog.com/2022/02/making-oauth-flows-safer.html?m=1#disallowed-oob"
-
- The console strategy instructs the user to open the authorization URL
- in their browser. Once the authorization is complete the authorization
- server will give the user a code. The user then must copy & paste this
- code into the application. The code is then exchanged for a token.
-
- Args:
- authorization_prompt_message (str | None): The message to display
to tell
- the user to navigate to the authorization URL. If None or
empty,
- don't display anything.
- authorization_code_message (str): The message to display when
- prompting the user for the authorization code.
- kwargs: Additional keyword arguments passed through to
- :meth:`authorization_url`.
-
- Returns:
- google.oauth2.credentials.Credentials: The OAuth 2.0 credentials
- for the user.
- """
- kwargs.setdefault("prompt", "consent")
- warnings.warn(
- "New clients will be unable to use `InstalledAppFlow.run_console` "
- "starting on Feb 28, 2022. All clients will be unable to use this
method starting on Oct 3, 2022. "
- "Use `InstalledAppFlow.run_local_server` instead. For details on
the OOB flow deprecation, "
- "see
https://developers.googleblog.com/2022/02/making-oauth-flows-safer.html?m=1#disallowed-oob",
- DeprecationWarning,
- )
-
- self.redirect_uri = self._OOB_REDIRECT_URI
-
- auth_url, _ = self.authorization_url(**kwargs)
-
- if authorization_prompt_message:
- print(authorization_prompt_message.format(url=auth_url))
-
- code = input(authorization_code_message)
-
- self.fetch_token(code=code)
-
- return self.credentials
-
def run_local_server(
self,
host="localhost",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/interactive.py
new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/interactive.py
--- old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/interactive.py
2022-12-12 22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/interactive.py
2023-02-07 21:50:41.000000000 +0100
@@ -156,7 +156,6 @@
"installed": {
"client_id": client_id,
"client_secret": client_secret,
- "redirect_uris": ["urn:ietf:wg:oauth:2.0:oob"],
"auth_uri": "https://accounts.google.com/o/oauth2/auth",
"token_uri": "https://oauth2.googleapis.com/token",
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/tool/__main__.py
new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/tool/__main__.py
--- old/google-auth-oauthlib-0.8.0/google_auth_oauthlib/tool/__main__.py
2022-12-12 22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/google_auth_oauthlib/tool/__main__.py
2023-02-07 21:50:41.000000000 +0100
@@ -72,15 +72,7 @@
default=os.path.join(click.get_app_dir(APP_NAME),
DEFAULT_CREDENTIALS_FILENAME),
help="Path to store OAuth2 credentials.",
)
[email protected](
- "--headless",
- is_flag=True,
- metavar="<headless_mode>",
- show_default=True,
- default=False,
- help="Run a console based flow.",
-)
-def main(client_secrets, scope, save, credentials, headless):
+def main(client_secrets, scope, save, credentials):
"""Command-line tool for obtaining authorization and credentials from a
user.
This tool uses the OAuth 2.0 Authorization Code grant as described
@@ -88,9 +80,7 @@
https://tools.ietf.org/html/rfc6749#section-1.3.1
This tool is intended for assist developers in obtaining credentials
- for testing applications where it may not be possible or easy to run a
- complete OAuth 2.0 authorization flow, especially in the case of code
- samples or embedded devices without input / display capabilities.
+ for testing applications or samples.
This is not intended for production use where a combination of
companion and on-device applications should complete the OAuth 2.0
@@ -102,10 +92,7 @@
client_secrets, scopes=scope
)
- if not headless:
- creds = flow.run_local_server()
- else:
- creds = flow.run_console()
+ creds = flow.run_local_server()
creds_data = {
"token": creds.token,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/google-auth-oauthlib-0.8.0/google_auth_oauthlib.egg-info/PKG-INFO
new/google-auth-oauthlib-1.0.0/google_auth_oauthlib.egg-info/PKG-INFO
--- old/google-auth-oauthlib-0.8.0/google_auth_oauthlib.egg-info/PKG-INFO
2022-12-12 22:57:51.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/google_auth_oauthlib.egg-info/PKG-INFO
2023-02-07 21:53:17.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: google-auth-oauthlib
-Version: 0.8.0
+Version: 1.0.0
Summary: Google Authentication Library
Home-page:
https://github.com/GoogleCloudPlatform/google-auth-library-python-oauthlib
Author: Google Cloud Platform
@@ -14,7 +14,7 @@
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
-Classifier: Development Status :: 3 - Alpha
+Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: POSIX
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/google-auth-oauthlib-0.8.0/setup.py
new/google-auth-oauthlib-1.0.0/setup.py
--- old/google-auth-oauthlib-0.8.0/setup.py 2022-12-12 22:54:41.000000000
+0100
+++ new/google-auth-oauthlib-1.0.0/setup.py 2023-02-07 21:50:41.000000000
+0100
@@ -27,7 +27,7 @@
long_description = fh.read()
-version = "0.8.0"
+version = "1.0.0"
setup(
name="google-auth-oauthlib",
@@ -56,7 +56,7 @@
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
- "Development Status :: 3 - Alpha",
+ "Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
"Operating System :: POSIX",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/google-auth-oauthlib-0.8.0/tests/unit/data/client_secrets.json
new/google-auth-oauthlib-1.0.0/tests/unit/data/client_secrets.json
--- old/google-auth-oauthlib-0.8.0/tests/unit/data/client_secrets.json
2022-12-12 22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/tests/unit/data/client_secrets.json
2023-02-07 21:50:41.000000000 +0100
@@ -7,7 +7,6 @@
"auth_provider_x509_cert_url":
"https://www.googleapis.com/oauth2/v1/certs",
"client_secret": "itsasecrettoeveryone",
"redirect_uris": [
- "urn:ietf:wg:oauth:2.0:oob",
"http://localhost"
]
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/google-auth-oauthlib-0.8.0/tests/unit/test_flow.py
new/google-auth-oauthlib-1.0.0/tests/unit/test_flow.py
--- old/google-auth-oauthlib-0.8.0/tests/unit/test_flow.py 2022-12-12
22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/tests/unit/test_flow.py 2023-02-07
21:50:41.000000000 +0100
@@ -58,20 +58,6 @@
== mock.sentinel.redirect_uri
)
- def test_from_client_secrets_file_with_oob_redirect_uri(self):
- with pytest.deprecated_call():
- instance = flow.Flow.from_client_secrets_file(
- CLIENT_SECRETS_FILE,
- scopes=mock.sentinel.scopes,
- redirect_uri="urn:ietf:wg:oauth:2.0:oob",
- )
-
- assert (
- instance.redirect_uri
- == instance.oauth2session.redirect_uri
- == "urn:ietf:wg:oauth:2.0:oob"
- )
-
def test_from_client_config_installed(self):
client_config = {"installed": CLIENT_SECRETS_INFO["web"]}
instance = flow.Flow.from_client_config(
@@ -296,25 +282,6 @@
with fetch_token_patch as fetch_token_mock:
yield fetch_token_mock
- @mock.patch("builtins.input", autospec=True)
- def test_run_console(self, input_mock, instance, mock_fetch_token):
- input_mock.return_value = mock.sentinel.code
- instance.code_verifier = "amanaplanacanalpanama"
-
- with pytest.deprecated_call():
- credentials = instance.run_console()
-
- assert credentials.token == mock.sentinel.access_token
- assert credentials._refresh_token == mock.sentinel.refresh_token
- assert credentials.id_token == mock.sentinel.id_token
-
- mock_fetch_token.assert_called_with(
- CLIENT_SECRETS_INFO["web"]["token_uri"],
- client_secret=CLIENT_SECRETS_INFO["web"]["client_secret"],
- code=mock.sentinel.code,
- code_verifier="amanaplanacanalpanama",
- )
-
@pytest.mark.webtest
@mock.patch("google_auth_oauthlib.flow.webbrowser", autospec=True)
def test_run_local_server(self, webbrowser_mock, instance,
mock_fetch_token, port):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/google-auth-oauthlib-0.8.0/tests/unit/test_tool.py
new/google-auth-oauthlib-1.0.0/tests/unit/test_tool.py
--- old/google-auth-oauthlib-0.8.0/tests/unit/test_tool.py 2022-12-12
22:54:41.000000000 +0100
+++ new/google-auth-oauthlib-1.0.0/tests/unit/test_tool.py 2023-02-07
21:50:41.000000000 +0100
@@ -57,16 +57,6 @@
flow.return_value = dummy_credentials
yield flow
- @pytest.fixture
- def console_mock(self, dummy_credentials):
- run_console_patch = mock.patch.object(
- google_auth_oauthlib.flow.InstalledAppFlow, "run_console",
autospec=True
- )
-
- with run_console_patch as flow:
- flow.return_value = dummy_credentials
- yield flow
-
def test_help(self, runner):
result = runner.invoke(cli.main, ["--help"])
assert not result.exception
@@ -91,22 +81,6 @@
assert creds.client_secret == dummy_credentials.client_secret
assert creds.scopes == dummy_credentials.scopes
- def test_headless(self, runner, dummy_credentials, console_mock):
- result = runner.invoke(
- cli.main,
- [
- "--client-secrets",
- CLIENT_SECRETS_FILE,
- "--scope",
- "somescope",
- "--headless",
- ],
- )
- console_mock.assert_called_with(mock.ANY)
- assert not result.exception
- assert dummy_credentials.refresh_token in result.output
- assert result.exit_code == 0
-
def test_save_new_dir(self, runner, dummy_credentials, local_server_mock):
credentials_tmpdir = tempfile.mkdtemp()
credentials_path = os.path.join(