Hello community, here is the log from the commit of package python-user-agents for openSUSE:Factory checked in at 2019-04-14 12:22:57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-user-agents (Old) and /work/SRC/openSUSE:Factory/.python-user-agents.new.27019 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-user-agents" Sun Apr 14 12:22:57 2019 rev:3 rq:693687 version:2.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-user-agents/python-user-agents.changes 2018-08-10 09:49:25.494235806 +0200 +++ /work/SRC/openSUSE:Factory/.python-user-agents.new.27019/python-user-agents.changes 2019-04-14 12:22:57.859800146 +0200 @@ -1,0 +2,6 @@ +Fri Apr 12 08:59:10 UTC 2019 - Marketa Calabkova <[email protected]> + +- update to version 2.0 + * python-user-agents now require ua-parser>=0.8.0. + +------------------------------------------------------------------- Old: ---- v1.1.0.tar.gz New: ---- v2.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-user-agents.spec ++++++ --- /var/tmp/diff_new_pack.kZwsLj/_old 2019-04-14 12:22:58.423800823 +0200 +++ /var/tmp/diff_new_pack.kZwsLj/_new 2019-04-14 12:22:58.427800828 +0200 @@ -1,7 +1,7 @@ # # spec file for package python-user-agents # -# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,13 +12,13 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-user-agents -Version: 1.1.0 +Version: 2.0 Release: 0 Summary: A library to identify device capabilities (phones, tablets) License: MIT @@ -27,11 +27,11 @@ Source: https://github.com/selwin/python-user-agents/archive/v%{version}.tar.gz BuildRequires: %{python_module PyYAML} BuildRequires: %{python_module setuptools} -BuildRequires: %{python_module ua-parser} +BuildRequires: %{python_module ua-parser >= 0.8.0} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-PyYAML -Requires: python-ua-parser +Requires: python-ua-parser >= 0.8.0 BuildArch: noarch %python_subpackages @@ -51,7 +51,6 @@ %python_expand %fdupes -s %{buildroot}/%{$python_sitelib} %check -# 5 known failures in tests %python_expand $python -m unittest discover ||: %files %{python_files} ++++++ v1.1.0.tar.gz -> v2.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/python-user-agents-1.1.0/.travis.yml new/python-user-agents-2.0/.travis.yml --- old/python-user-agents-1.1.0/.travis.yml 2017-02-16 23:46:33.000000000 +0100 +++ new/python-user-agents-2.0/.travis.yml 2019-04-07 12:47:25.000000000 +0200 @@ -1,9 +1,12 @@ sudo: false language: python +dist: xenial python: - "2.7" - - "3.3" - "3.4" + - "3.5" + - "3.6" + - "3.7" install: - "python setup.py install" - "pip install -U pip" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/python-user-agents-1.1.0/README.rst new/python-user-agents-2.0/README.rst --- old/python-user-agents-1.1.0/README.rst 2017-02-16 23:46:33.000000000 +0100 +++ new/python-user-agents-2.0/README.rst 2019-04-07 12:47:25.000000000 +0200 @@ -10,7 +10,7 @@ - User agent has touch capabilities (has touch screen) ``user_agents`` relies on the excellent -``ua-parser <https://github.com/tobie/ua-parser>``\ \_ to do the actual +`ua-parser <https://github.com/tobie/ua-parser>`_ to do the actual parsing of the raw user agent string. Installation @@ -20,6 +20,7 @@ :alt: Build status Build status + ``user-agents`` is hosted on `PyPI <http://pypi.python.org/pypi/user-agents/>`__ and can be installed as such: @@ -29,7 +30,9 @@ pip install pyyaml ua-parser user-agents Alternatively, you can also get the latest source code from -``Github``\ \_ and install it manually. +Github_ and install it manually. + +.. _Github: https://github.com/selwin/python-user-agents Usage ----- @@ -151,13 +154,12 @@ Changelog --------- -Version 1.1.0 -~~~~~~~~~~~~~ -- Better FirefoxOS and ChromeBook detection -- Fixes browser version number parsing. +Version 2.0 (2019-04-07) +~~~~~~~~~~~~~~~~~~~~~~~~ +- ``python-user-agents`` now require ``ua-parser>=0.8.0``. Thanks @IMDagger! -Version 1.0.0 +Version 1.1 ~~~~~~~~~~~~~ - Fixes packaging issue @@ -169,7 +171,6 @@ - Access to more device information in ``user_agent.device.brand`` and ``user_agent.device.model`` -=== Version 0.3.2 ~~~~~~~~~~~~~ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/python-user-agents-1.1.0/setup.py new/python-user-agents-2.0/setup.py --- old/python-user-agents-1.1.0/setup.py 2017-02-16 23:46:33.000000000 +0100 +++ new/python-user-agents-2.0/setup.py 2019-04-07 12:47:25.000000000 +0200 @@ -3,7 +3,7 @@ setup( name='user-agents', - version='1.1.0', + version='2.0', author='Selwin Ong', author_email='[email protected]', packages=['user_agents'], @@ -14,7 +14,7 @@ zip_safe=False, include_package_data=True, package_data={'': ['README.rst']}, - install_requires=['ua-parser>=0.4.1'], + install_requires=['ua-parser>=0.8.0'], classifiers=[ 'Development Status :: 5 - Production/Stable', 'Environment :: Web Environment', diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/python-user-agents-1.1.0/user_agents/__init__.py new/python-user-agents-2.0/user_agents/__init__.py --- old/python-user-agents-1.1.0/user_agents/__init__.py 2017-02-16 23:46:33.000000000 +0100 +++ new/python-user-agents-2.0/user_agents/__init__.py 2019-04-07 12:47:25.000000000 +0200 @@ -1,3 +1,3 @@ -VERSION = (1, 1, 0) +VERSION = (2, 0, 0) from .parsers import parse diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/python-user-agents-1.1.0/user_agents/parsers.py new/python-user-agents-2.0/user_agents/parsers.py --- old/python-user-agents-1.1.0/user_agents/parsers.py 2017-02-16 23:46:33.000000000 +0100 +++ new/python-user-agents-2.0/user_agents/parsers.py 2019-04-07 12:47:25.000000000 +0200 @@ -16,7 +16,6 @@ PC_OS_FAMILIES = ( 'Windows 95', 'Windows 98', - 'Windows ME', 'Solaris', ) @@ -51,8 +50,6 @@ 'iOS', 'Android', 'Windows Phone', - 'Windows Phone OS', - 'Windows RT', 'Windows CE', 'Windows Mobile', 'Firefox OS', @@ -65,7 +62,7 @@ 'Kindle Fire', ) -EMAIL_PROGRAM_FAMILIES = { +EMAIL_PROGRAM_FAMILIES = set(( 'Outlook', 'Windows Live Mail', 'AirMail', @@ -82,7 +79,7 @@ 'MailBar', 'kmail2', 'YahooMobileMail' -} +)) def verify_attribute(attribute): if isinstance(attribute, string_types) and attribute.isdigit(): @@ -172,7 +169,7 @@ return True if (self.os.family == 'Android' and self._is_android_tablet()): return True - if self.os.family.startswith('Windows RT'): + if self.os.family == 'Windows' and self.os.version_string.startswith('RT'): return True if self.os.family == 'Firefox OS' and 'Mobile' not in self.browser.family: return True @@ -217,8 +214,11 @@ return True if self.device.family in TOUCH_CAPABLE_DEVICE_FAMILIES: return True - if self.os.family.startswith('Windows 8') and 'Touch' in self.ua_string: - return True + if self.os.family == 'Windows': + if self.os.version_string.startswith('RT'): + return True + if self.os.version_string.startswith('8') and 'Touch' in self.ua_string: + return True if 'BlackBerry' in self.os.family and self._is_blackberry_touch_capable_device(): return True return False @@ -226,7 +226,8 @@ @property def is_pc(self): # Returns True for "PC" devices (Windows, Mac and Linux) - if 'Windows NT' in self.ua_string or self.os.family in PC_OS_FAMILIES: + if 'Windows NT' in self.ua_string or self.os.family in PC_OS_FAMILIES or \ + self.os.family == 'Windows' and self.os.version_string == 'ME': return True # TODO: remove after https://github.com/tobie/ua-parser/issues/127 is closed if self.os.family == 'Mac OS X' and 'Silk' not in self.ua_string:
