openSUSE Commits
Threads by month
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
February 2017
- 1 participants
- 1918 discussions
Hello community,
here is the log from the commit of package python3-websocket-client for openSUSE:Factory checked in at 2017-02-22 13:54:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-websocket-client (Old)
and /work/SRC/openSUSE:Factory/.python3-websocket-client.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-websocket-client"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-websocket-client/python3-websocket-client.changes 2016-12-05 16:34:00.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.python3-websocket-client.new/python3-websocket-client.changes 2017-02-22 13:54:50.329181499 +0100
@@ -1,0 +2,9 @@
+Mon Feb 20 21:49:15 UTC 2017 - arun(a)gmx.de
+
+- specfile:
+ * update copyright year
+
+- update to version 0.40.0:
+ * Fix opcode -> op_code (#286)
+
+-------------------------------------------------------------------
Old:
----
websocket_client-0.39.0.tar.gz
New:
----
websocket_client-0.40.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-websocket-client.spec ++++++
--- /var/tmp/diff_new_pack.TeW95z/_old 2017-02-22 13:54:50.893101264 +0100
+++ /var/tmp/diff_new_pack.TeW95z/_new 2017-02-22 13:54:50.893101264 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python3-websocket-client
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -17,7 +17,7 @@
Name: python3-websocket-client
-Version: 0.39.0
+Version: 0.40.0
Release: 0
Summary: WebSocket client implementation
License: LGPL-2.1
++++++ websocket_client-0.39.0.tar.gz -> websocket_client-0.40.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/ChangeLog new/websocket_client-0.40.0/ChangeLog
--- old/websocket_client-0.39.0/ChangeLog 2016-12-02 01:52:08.000000000 +0100
+++ new/websocket_client-0.40.0/ChangeLog 2016-12-09 03:07:29.000000000 +0100
@@ -1,6 +1,9 @@
ChangeLog
============
+- 0.40.0
+ - Fix opcode -> op_code (#286)
+
- 0.39.0
- Shuffled around example code (#256)
- _send_ping graceful error handling (#262)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/PKG-INFO new/websocket_client-0.40.0/PKG-INFO
--- old/websocket_client-0.39.0/PKG-INFO 2016-12-02 01:58:00.000000000 +0100
+++ new/websocket_client-0.40.0/PKG-INFO 2016-12-09 03:11:01.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: websocket_client
-Version: 0.39.0
+Version: 0.40.0
Summary: WebSocket client for python. hybi13 is supported.
Home-page: https://github.com/liris/websocket-client
Author: liris
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/setup.py new/websocket_client-0.40.0/setup.py
--- old/websocket_client-0.39.0/setup.py 2016-12-02 01:57:55.000000000 +0100
+++ new/websocket_client-0.40.0/setup.py 2016-12-09 03:07:47.000000000 +0100
@@ -3,7 +3,7 @@
from setuptools import setup
import pkg_resources
-VERSION = "0.39.0"
+VERSION = "0.40.0"
NAME = "websocket_client"
install_requires = ["six"]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/websocket/__init__.py new/websocket_client-0.40.0/websocket/__init__.py
--- old/websocket_client-0.39.0/websocket/__init__.py 2016-10-03 03:38:18.000000000 +0200
+++ new/websocket_client-0.40.0/websocket/__init__.py 2016-12-09 03:08:02.000000000 +0100
@@ -26,4 +26,4 @@
from ._logging import *
from ._socket import *
-__version__ = "0.39.0"
+__version__ = "0.40.0"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/websocket/_app.py new/websocket_client-0.40.0/websocket/_app.py
--- old/websocket_client-0.39.0/websocket/_app.py 2016-10-03 03:47:28.000000000 +0200
+++ new/websocket_client-0.40.0/websocket/_app.py 2016-12-09 03:06:53.000000000 +0100
@@ -218,7 +218,7 @@
frame.data, frame.fin)
else:
data = frame.data
- if six.PY3 and opcode == ABNF.OPCODE_TEXT:
+ if six.PY3 and op_code == ABNF.OPCODE_TEXT:
data = data.decode("utf-8")
self._callback(self.on_data, data, frame.opcode, True)
self._callback(self.on_message, data)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/websocket_client-0.39.0/websocket_client.egg-info/PKG-INFO new/websocket_client-0.40.0/websocket_client.egg-info/PKG-INFO
--- old/websocket_client-0.39.0/websocket_client.egg-info/PKG-INFO 2016-12-02 01:58:00.000000000 +0100
+++ new/websocket_client-0.40.0/websocket_client.egg-info/PKG-INFO 2016-12-09 03:11:01.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: websocket-client
-Version: 0.39.0
+Version: 0.40.0
Summary: WebSocket client for python. hybi13 is supported.
Home-page: https://github.com/liris/websocket-client
Author: liris
1
0
Hello community,
here is the log from the commit of package python3-setuptools-git for openSUSE:Factory checked in at 2017-02-22 13:54:42
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-setuptools-git (Old)
and /work/SRC/openSUSE:Factory/.python3-setuptools-git.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-setuptools-git"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-setuptools-git/python3-setuptools-git.changes 2016-05-25 21:26:16.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python3-setuptools-git.new/python3-setuptools-git.changes 2017-02-22 13:54:43.962087426 +0100
@@ -1,0 +2,16 @@
+Mon Feb 20 19:55:23 UTC 2017 - arun(a)gmx.de
+
+- specfile:
+ * update copyright year
+
+- update to version 1.2:
+ * Add ability to get version from git tags
+ (https://github.com/msabramo/setuptools-git/pull/9)
+ * Return early if a directory isn’t managed by git
+ (https://github.com/msabramo/setuptools-git/pull/10)
+ * Support universal wheels
+ (https://github.com/msabramo/setuptools-git/pull/11)
+ * Optimize directory scanning to skip ignored directories
+ (https://github.com/msabramo/setuptools-git/pull/12)
+
+-------------------------------------------------------------------
@@ -7 +22,0 @@
-
Old:
----
setuptools-git-1.1.tar.gz
New:
----
setuptools-git-1.2.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-setuptools-git.spec ++++++
--- /var/tmp/diff_new_pack.r1jTec/_old 2017-02-22 13:54:44.370029382 +0100
+++ /var/tmp/diff_new_pack.r1jTec/_new 2017-02-22 13:54:44.370029382 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python3-setuptools-git
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -19,7 +19,7 @@
%define mod_name setuptools-git
Name: python3-setuptools-git
-Version: 1.1
+Version: 1.2
Release: 0
Summary: Setuptools revision control system plugin for Git
License: BSD-3-Clause
++++++ setuptools-git-1.1.tar.gz -> setuptools-git-1.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/PKG-INFO new/setuptools-git-1.2/PKG-INFO
--- old/setuptools-git-1.1/PKG-INFO 2014-08-16 11:08:11.000000000 +0200
+++ new/setuptools-git-1.2/PKG-INFO 2017-02-18 01:30:59.000000000 +0100
@@ -1,10 +1,10 @@
Metadata-Version: 1.1
Name: setuptools-git
-Version: 1.1
+Version: 1.2
Summary: Setuptools revision control system plugin for Git
Home-page: https://github.com/wichert/setuptools-git
-Author: Wichert Akkerman
-Author-email: wichert(a)wiggy.net
+Author: Marc Abramowitz
+Author-email: msabramo(a)gmail.com
License: BSD
Description: About
-----
@@ -15,11 +15,11 @@
inclusion specifications with ``MANIFEST.in``.
A package distribution here refers to a package that you create using
- setup.py, ex::
+ setup.py, for example::
- python setup.py sdist
- python setup.py bdist_rpm
- python setup.py bdist_egg
+ $> python setup.py sdist
+ $> python setup.py bdist_rpm
+ $> python setup.py bdist_egg
This package was formerly known as gitlsfiles. The name change is the
result of an effort by the setuptools plugin developers to provide a
@@ -31,13 +31,13 @@
With easy_install::
- easy_install setuptools_git
+ $> easy_install setuptools_git
Alternative manual installation::
- tar -zxvf setuptools_git-X.Y.Z.tar.gz
- cd setuptools_git-X.Y.Z
- python setup.py install
+ $> tar -zxvf setuptools_git-X.Y.Z.tar.gz
+ $> cd setuptools_git-X.Y.Z
+ $> python setup.py install
Where X.Y.Z is a version number.
@@ -51,12 +51,16 @@
the `distutils manual <http://docs.python.org/dist/dist.html>`_.
To use setuptools instead of distutils, just edit ``setup.py`` and
- change::
+ change:
+
+ .. code-block:: python
from distutils.core import setup
- to::
-
+ to:
+
+ .. code-block:: python
+
from setuptools import setup, find_packages
When Setuptools builds a source package, it always includes all files
@@ -65,21 +69,25 @@
When Setuptools builds a binary package, you can ask it to include all
files tracked by your revision control system, by adding these argument
- to your invocation of `setup()`::
+ to your invocation of `setup()`:
- setup(...,
- packages=find_packages(),
- include_package_data=True,
- ...)
+ .. code-block:: python
+
+ setup(...,
+ packages=find_packages(),
+ include_package_data=True,
+ ...)
which will detect that a directory is a package if it contains a
- ``__init__.py`` file. Alternatively, you can do without ``__init__.py``
- files and tell Setuptools explicitly which packages to process::
+ ``__init__.py`` file. Alternatively, you can do without ``__init__.py``
+ files and tell Setuptools explicitly which packages to process:
+
+ .. code-block:: python
- setup(...,
- packages=["a_package", "another_one"],
- include_package_data=True,
- ...)
+ setup(...,
+ packages=["a_package", "another_one"],
+ include_package_data=True,
+ ...)
This plugin lets setuptools know what files are tracked by your git
revision control tool. Setuptools ships with support for cvs and
@@ -89,28 +97,32 @@
It might happen that you track files with your revision control system
that you don't want to include in your packages. In that case, you
can prevent setuptools from packaging those files with a directive in
- your `MANIFEST.in`, ex::
+ your ``MANIFEST.in``, for example::
exclude .gitignore
recursive-exclude images *.xcf *.blend
- In this example, we prevent setuptools from packaging `.gitignore` and
- the Gimp and Blender source files found under the `images` directory.
+ In this example, we prevent setuptools from packaging ``.gitignore`` and
+ the Gimp and Blender source files found under the ``images`` directory.
Files to exclude from the package can also be listed in the `setup()`
- directive. To do the same as the MANIFEST.in above, do::
+ directive. To do the same as the MANIFEST.in above, do:
+
+ .. code-block:: python
+
+ setup(...,
+ exclude_package_data={'': ['.gitignore'],
+ 'images': ['*.xcf', '*.blend']},
+ ...)
+
+ Here is another example:
+
+ .. code-block:: python
- setup(...,
- exclude_package_data = {'': ['.gitignore'],
- 'images': ['*.xcf', '*.blend']},
- ...)
-
- Here is another example::
-
- setup(...,
- exclude_package_data = {'': ['.gitignore', 'artwork/*'],
- 'model': ['config.py']},
- ...)
+ setup(...,
+ exclude_package_data={'': ['.gitignore', 'artwork/*'],
+ 'model': ['config.py']},
+ ...)
Gotchas
@@ -129,22 +141,39 @@
You can make sure that anyone who clones your git repository and uses
your setup.py file has this plugin by adding a `setup_requires`
- argument::
+ argument:
+
+ .. code-block:: python
+
+ setup(...,
+ setup_requires=[ "setuptools_git >= 0.3", ],
+ ...)
+
+
+ Changes
+ -------
+
+ 1.2; 2017-02-17
+ ~~~~~~~~~~~~~~~~
+ - Add ability to get version from git tags (https://github.com/msabramo/setuptools-git/pull/9)
+ - Return early if a directory isn't managed by git (https://github.com/msabramo/setuptools-git/pull/10)
+ - Support universal wheels (https://github.com/msabramo/setuptools-git/pull/11)
+ - Optimize directory scanning to skip ignored directories (https://github.com/msabramo/setuptools-git/pull/12)
- setup(...,
- setup_requires = [ "setuptools_git >= 0.3", ],
- ...)
-
References
----------
* `How to distribute Python modules with Distutils
<http://docs.python.org/dist/dist.html>`_
+
* `Setuptools complete manual
<http://peak.telecommunity.com/DevCenter/setuptools>`_
- Thanks to Zooko O'Whielacronx for many improvements to the documentation.
+ Thanks to `Zooko O'Whielacronx`_ for many improvements to the documentation.
+
+
+ .. _Zooko O'Whielacronx: https://bitbucket.org/zooko
Keywords: distutils setuptools git
Platform: UNKNOWN
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/README.rst new/setuptools-git-1.2/README.rst
--- old/setuptools-git-1.1/README.rst 2014-08-16 11:06:54.000000000 +0200
+++ new/setuptools-git-1.2/README.rst 2017-02-18 01:30:24.000000000 +0100
@@ -7,11 +7,11 @@
inclusion specifications with ``MANIFEST.in``.
A package distribution here refers to a package that you create using
-setup.py, ex::
+setup.py, for example::
- python setup.py sdist
- python setup.py bdist_rpm
- python setup.py bdist_egg
+ $> python setup.py sdist
+ $> python setup.py bdist_rpm
+ $> python setup.py bdist_egg
This package was formerly known as gitlsfiles. The name change is the
result of an effort by the setuptools plugin developers to provide a
@@ -23,13 +23,13 @@
With easy_install::
- easy_install setuptools_git
+ $> easy_install setuptools_git
Alternative manual installation::
- tar -zxvf setuptools_git-X.Y.Z.tar.gz
- cd setuptools_git-X.Y.Z
- python setup.py install
+ $> tar -zxvf setuptools_git-X.Y.Z.tar.gz
+ $> cd setuptools_git-X.Y.Z
+ $> python setup.py install
Where X.Y.Z is a version number.
@@ -43,12 +43,16 @@
the `distutils manual <http://docs.python.org/dist/dist.html>`_.
To use setuptools instead of distutils, just edit ``setup.py`` and
-change::
+change:
+
+.. code-block:: python
from distutils.core import setup
-to::
-
+to:
+
+.. code-block:: python
+
from setuptools import setup, find_packages
When Setuptools builds a source package, it always includes all files
@@ -57,21 +61,25 @@
When Setuptools builds a binary package, you can ask it to include all
files tracked by your revision control system, by adding these argument
-to your invocation of `setup()`::
+to your invocation of `setup()`:
- setup(...,
- packages=find_packages(),
- include_package_data=True,
- ...)
+.. code-block:: python
+
+ setup(...,
+ packages=find_packages(),
+ include_package_data=True,
+ ...)
which will detect that a directory is a package if it contains a
-``__init__.py`` file. Alternatively, you can do without ``__init__.py``
-files and tell Setuptools explicitly which packages to process::
+``__init__.py`` file. Alternatively, you can do without ``__init__.py``
+files and tell Setuptools explicitly which packages to process:
+
+.. code-block:: python
- setup(...,
- packages=["a_package", "another_one"],
- include_package_data=True,
- ...)
+ setup(...,
+ packages=["a_package", "another_one"],
+ include_package_data=True,
+ ...)
This plugin lets setuptools know what files are tracked by your git
revision control tool. Setuptools ships with support for cvs and
@@ -81,28 +89,32 @@
It might happen that you track files with your revision control system
that you don't want to include in your packages. In that case, you
can prevent setuptools from packaging those files with a directive in
-your `MANIFEST.in`, ex::
+your ``MANIFEST.in``, for example::
exclude .gitignore
recursive-exclude images *.xcf *.blend
-In this example, we prevent setuptools from packaging `.gitignore` and
-the Gimp and Blender source files found under the `images` directory.
+In this example, we prevent setuptools from packaging ``.gitignore`` and
+the Gimp and Blender source files found under the ``images`` directory.
Files to exclude from the package can also be listed in the `setup()`
-directive. To do the same as the MANIFEST.in above, do::
+directive. To do the same as the MANIFEST.in above, do:
+
+.. code-block:: python
+
+ setup(...,
+ exclude_package_data={'': ['.gitignore'],
+ 'images': ['*.xcf', '*.blend']},
+ ...)
+
+Here is another example:
+
+.. code-block:: python
- setup(...,
- exclude_package_data = {'': ['.gitignore'],
- 'images': ['*.xcf', '*.blend']},
- ...)
-
-Here is another example::
-
- setup(...,
- exclude_package_data = {'': ['.gitignore', 'artwork/*'],
- 'model': ['config.py']},
- ...)
+ setup(...,
+ exclude_package_data={'': ['.gitignore', 'artwork/*'],
+ 'model': ['config.py']},
+ ...)
Gotchas
@@ -121,19 +133,36 @@
You can make sure that anyone who clones your git repository and uses
your setup.py file has this plugin by adding a `setup_requires`
-argument::
+argument:
+
+.. code-block:: python
+
+ setup(...,
+ setup_requires=[ "setuptools_git >= 0.3", ],
+ ...)
+
+
+Changes
+-------
+
+1.2; 2017-02-17
+~~~~~~~~~~~~~~~~
+ - Add ability to get version from git tags (https://github.com/msabramo/setuptools-git/pull/9)
+ - Return early if a directory isn't managed by git (https://github.com/msabramo/setuptools-git/pull/10)
+ - Support universal wheels (https://github.com/msabramo/setuptools-git/pull/11)
+ - Optimize directory scanning to skip ignored directories (https://github.com/msabramo/setuptools-git/pull/12)
- setup(...,
- setup_requires = [ "setuptools_git >= 0.3", ],
- ...)
-
References
----------
* `How to distribute Python modules with Distutils
<http://docs.python.org/dist/dist.html>`_
+
* `Setuptools complete manual
<http://peak.telecommunity.com/DevCenter/setuptools>`_
-Thanks to Zooko O'Whielacronx for many improvements to the documentation.
+Thanks to `Zooko O'Whielacronx`_ for many improvements to the documentation.
+
+
+.. _Zooko O'Whielacronx: https://bitbucket.org/zooko
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setup.cfg new/setuptools-git-1.2/setup.cfg
--- old/setuptools-git-1.1/setup.cfg 2014-08-16 11:08:11.000000000 +0200
+++ new/setuptools-git-1.2/setup.cfg 2017-02-18 01:30:59.000000000 +0100
@@ -1,5 +1,7 @@
+[bdist_wheel]
+universal = 1
+
[egg_info]
tag_build =
tag_date = 0
-tag_svn_revision = 0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setup.py new/setuptools-git-1.2/setup.py
--- old/setuptools-git-1.1/setup.py 2014-08-16 11:07:07.000000000 +0200
+++ new/setuptools-git-1.2/setup.py 2017-02-18 01:06:52.000000000 +0100
@@ -1,12 +1,12 @@
from setuptools import setup, find_packages
-version = '1.1'
+version = '1.2'
setup(
name="setuptools-git",
version=version,
- maintainer='Wichert Akkerman',
- maintainer_email='wichert(a)wiggy.net',
+ maintainer='Marc Abramowitz',
+ maintainer_email='msabramo(a)gmail.com',
author="Yannick Gingras",
author_email="ygingras(a)ygingras.net",
url="https://github.com/wichert/setuptools-git",
@@ -35,5 +35,8 @@
entry_points="""
[setuptools.file_finders]
git=setuptools_git:listfiles
+
+ [distutils.setup_keywords]
+ use_vcs_version=setuptools_git:version_calc
"""
)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setuptools_git/__init__.py new/setuptools-git-1.2/setuptools_git/__init__.py
--- old/setuptools-git-1.1/setuptools_git/__init__.py 2014-08-16 11:06:54.000000000 +0200
+++ new/setuptools-git-1.2/setuptools_git/__init__.py 2017-02-18 01:05:33.000000000 +0100
@@ -18,6 +18,19 @@
from setuptools_git.utils import CalledProcessError
+def version_calc(dist, attr, value):
+ """
+ Handler for parameter to setup(use_vcs_version=value)
+ bool(value) should be true to invoke this plugin.
+ """
+ if attr == 'use_vcs_version' and value:
+ dist.metadata.version = calculate_version()
+
+
+def calculate_version():
+ return check_output(['git', 'describe', '--tags', '--dirty']).strip()
+
+
def ntfsdecode(path):
# We receive the raw bytes from Git and must decode by hand
if sys.version_info >= (3,):
@@ -80,18 +93,34 @@
return res
+def _gitlsdirs(files, prefix_length):
+ # Return directories managed by Git
+ dirs = set()
+ for file in files:
+ dir = posixpath.dirname(file)
+ while len(dir) > prefix_length:
+ dirs.add(dir)
+ dir = posixpath.dirname(dir)
+ return dirs
+
+
def listfiles(dirname=''):
git_files = gitlsfiles(dirname)
+ if not git_files:
+ return
cwd = realpath(dirname or os.curdir)
prefix_length = len(cwd) + 1
+ git_dirs = _gitlsdirs(git_files, prefix_length)
+
if sys.version_info >= (2, 6):
walker = os.walk(cwd, followlinks=True)
else:
walker = os.walk(cwd)
for root, dirs, files in walker:
+ dirs[:] = [x for x in dirs if posix(realpath(join(root, x))) in git_dirs]
for file in files:
filename = join(root, file)
if posix(realpath(filename)) in git_files:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setuptools_git/tests.py new/setuptools-git-1.2/setuptools_git/tests.py
--- old/setuptools-git-1.1/setuptools_git/tests.py 2014-08-16 11:06:54.000000000 +0200
+++ new/setuptools-git-1.2/setuptools_git/tests.py 2017-02-18 01:05:33.000000000 +0100
@@ -61,7 +61,7 @@
def test_at_repo_root_with_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
self.assertEqual(
set(self.gitlsfiles(self.directory)),
@@ -70,7 +70,7 @@
def test_at_repo_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
self.assertEqual(
set(self.gitlsfiles(join(self.directory, 'subdir'))),
@@ -167,7 +167,7 @@
def test_empty_dirname_in_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
os.chdir(join(self.directory, 'subdir'))
self.assertEqual(
@@ -205,7 +205,7 @@
def test_at_repo_root_with_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
self.assertEqual(
set(self.listfiles(self.directory)),
@@ -213,7 +213,7 @@
def test_at_repo_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
self.assertEqual(
set(self.listfiles(join(self.directory, 'subdir'))),
@@ -309,7 +309,7 @@
def test_empty_dirname_in_subdir(self):
self.create_git_file('root.txt')
- os.mkdir(join(self.directory, 'subdir'))
+ self.create_dir('subdir')
self.create_git_file('subdir', 'entry.txt')
os.chdir(join(self.directory, 'subdir'))
self.assertEqual(
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setuptools_git.egg-info/PKG-INFO new/setuptools-git-1.2/setuptools_git.egg-info/PKG-INFO
--- old/setuptools-git-1.1/setuptools_git.egg-info/PKG-INFO 2014-08-16 11:08:10.000000000 +0200
+++ new/setuptools-git-1.2/setuptools_git.egg-info/PKG-INFO 2017-02-18 01:30:59.000000000 +0100
@@ -1,10 +1,10 @@
Metadata-Version: 1.1
Name: setuptools-git
-Version: 1.1
+Version: 1.2
Summary: Setuptools revision control system plugin for Git
Home-page: https://github.com/wichert/setuptools-git
-Author: Wichert Akkerman
-Author-email: wichert(a)wiggy.net
+Author: Marc Abramowitz
+Author-email: msabramo(a)gmail.com
License: BSD
Description: About
-----
@@ -15,11 +15,11 @@
inclusion specifications with ``MANIFEST.in``.
A package distribution here refers to a package that you create using
- setup.py, ex::
+ setup.py, for example::
- python setup.py sdist
- python setup.py bdist_rpm
- python setup.py bdist_egg
+ $> python setup.py sdist
+ $> python setup.py bdist_rpm
+ $> python setup.py bdist_egg
This package was formerly known as gitlsfiles. The name change is the
result of an effort by the setuptools plugin developers to provide a
@@ -31,13 +31,13 @@
With easy_install::
- easy_install setuptools_git
+ $> easy_install setuptools_git
Alternative manual installation::
- tar -zxvf setuptools_git-X.Y.Z.tar.gz
- cd setuptools_git-X.Y.Z
- python setup.py install
+ $> tar -zxvf setuptools_git-X.Y.Z.tar.gz
+ $> cd setuptools_git-X.Y.Z
+ $> python setup.py install
Where X.Y.Z is a version number.
@@ -51,12 +51,16 @@
the `distutils manual <http://docs.python.org/dist/dist.html>`_.
To use setuptools instead of distutils, just edit ``setup.py`` and
- change::
+ change:
+
+ .. code-block:: python
from distutils.core import setup
- to::
-
+ to:
+
+ .. code-block:: python
+
from setuptools import setup, find_packages
When Setuptools builds a source package, it always includes all files
@@ -65,21 +69,25 @@
When Setuptools builds a binary package, you can ask it to include all
files tracked by your revision control system, by adding these argument
- to your invocation of `setup()`::
+ to your invocation of `setup()`:
- setup(...,
- packages=find_packages(),
- include_package_data=True,
- ...)
+ .. code-block:: python
+
+ setup(...,
+ packages=find_packages(),
+ include_package_data=True,
+ ...)
which will detect that a directory is a package if it contains a
- ``__init__.py`` file. Alternatively, you can do without ``__init__.py``
- files and tell Setuptools explicitly which packages to process::
+ ``__init__.py`` file. Alternatively, you can do without ``__init__.py``
+ files and tell Setuptools explicitly which packages to process:
+
+ .. code-block:: python
- setup(...,
- packages=["a_package", "another_one"],
- include_package_data=True,
- ...)
+ setup(...,
+ packages=["a_package", "another_one"],
+ include_package_data=True,
+ ...)
This plugin lets setuptools know what files are tracked by your git
revision control tool. Setuptools ships with support for cvs and
@@ -89,28 +97,32 @@
It might happen that you track files with your revision control system
that you don't want to include in your packages. In that case, you
can prevent setuptools from packaging those files with a directive in
- your `MANIFEST.in`, ex::
+ your ``MANIFEST.in``, for example::
exclude .gitignore
recursive-exclude images *.xcf *.blend
- In this example, we prevent setuptools from packaging `.gitignore` and
- the Gimp and Blender source files found under the `images` directory.
+ In this example, we prevent setuptools from packaging ``.gitignore`` and
+ the Gimp and Blender source files found under the ``images`` directory.
Files to exclude from the package can also be listed in the `setup()`
- directive. To do the same as the MANIFEST.in above, do::
+ directive. To do the same as the MANIFEST.in above, do:
+
+ .. code-block:: python
+
+ setup(...,
+ exclude_package_data={'': ['.gitignore'],
+ 'images': ['*.xcf', '*.blend']},
+ ...)
+
+ Here is another example:
+
+ .. code-block:: python
- setup(...,
- exclude_package_data = {'': ['.gitignore'],
- 'images': ['*.xcf', '*.blend']},
- ...)
-
- Here is another example::
-
- setup(...,
- exclude_package_data = {'': ['.gitignore', 'artwork/*'],
- 'model': ['config.py']},
- ...)
+ setup(...,
+ exclude_package_data={'': ['.gitignore', 'artwork/*'],
+ 'model': ['config.py']},
+ ...)
Gotchas
@@ -129,22 +141,39 @@
You can make sure that anyone who clones your git repository and uses
your setup.py file has this plugin by adding a `setup_requires`
- argument::
+ argument:
+
+ .. code-block:: python
+
+ setup(...,
+ setup_requires=[ "setuptools_git >= 0.3", ],
+ ...)
+
+
+ Changes
+ -------
+
+ 1.2; 2017-02-17
+ ~~~~~~~~~~~~~~~~
+ - Add ability to get version from git tags (https://github.com/msabramo/setuptools-git/pull/9)
+ - Return early if a directory isn't managed by git (https://github.com/msabramo/setuptools-git/pull/10)
+ - Support universal wheels (https://github.com/msabramo/setuptools-git/pull/11)
+ - Optimize directory scanning to skip ignored directories (https://github.com/msabramo/setuptools-git/pull/12)
- setup(...,
- setup_requires = [ "setuptools_git >= 0.3", ],
- ...)
-
References
----------
* `How to distribute Python modules with Distutils
<http://docs.python.org/dist/dist.html>`_
+
* `Setuptools complete manual
<http://peak.telecommunity.com/DevCenter/setuptools>`_
- Thanks to Zooko O'Whielacronx for many improvements to the documentation.
+ Thanks to `Zooko O'Whielacronx`_ for many improvements to the documentation.
+
+
+ .. _Zooko O'Whielacronx: https://bitbucket.org/zooko
Keywords: distutils setuptools git
Platform: UNKNOWN
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setuptools_git.egg-info/SOURCES.txt new/setuptools-git-1.2/setuptools_git.egg-info/SOURCES.txt
--- old/setuptools-git-1.1/setuptools_git.egg-info/SOURCES.txt 2014-08-16 11:08:11.000000000 +0200
+++ new/setuptools-git-1.2/setuptools_git.egg-info/SOURCES.txt 2017-02-18 01:30:59.000000000 +0100
@@ -3,6 +3,7 @@
LICENSE.txt
README.rst
TODO.txt
+setup.cfg
setup.py
setuptools_git/__init__.py
setuptools_git/tests.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/setuptools-git-1.1/setuptools_git.egg-info/entry_points.txt new/setuptools-git-1.2/setuptools_git.egg-info/entry_points.txt
--- old/setuptools-git-1.1/setuptools_git.egg-info/entry_points.txt 2014-08-16 11:08:10.000000000 +0200
+++ new/setuptools-git-1.2/setuptools_git.egg-info/entry_points.txt 2017-02-18 01:30:59.000000000 +0100
@@ -1,4 +1,7 @@
[setuptools.file_finders]
git=setuptools_git:listfiles
+
+ [distutils.setup_keywords]
+ use_vcs_version=setuptools_git:version_calc
\ No newline at end of file
1
0
Hello community,
here is the log from the commit of package python3-pycodestyle for openSUSE:Factory checked in at 2017-02-22 13:54:35
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-pycodestyle (Old)
and /work/SRC/openSUSE:Factory/.python3-pycodestyle.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-pycodestyle"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-pycodestyle/python3-pycodestyle.changes 2016-11-15 18:01:50.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.python3-pycodestyle.new/python3-pycodestyle.changes 2017-02-22 13:54:36.339172047 +0100
@@ -1,0 +2,21 @@
+Mon Feb 20 20:01:00 UTC 2017 - arun(a)gmx.de
+
+- specfile:
+ * update copyright year
+
+- update to version 2.3.1:
+ * Bugs:
+ + Fix regression in detection of E302 and E306; #618, #620
+
+- changes from version 2.3.0:
+ * New Checks:
+ + Add E722 warning for bare except clauses
+ + Report E704 for async function definitions (async def)
+ * Bugs:
+ + Fix another E305 false positive for variables beginning with
+ “class” or “def”
+ + Fix detection of multiple spaces betwen async and def
+ + Fix handling of variable annotations. Stop reporting E701 on
+ Python 3.6 for variable annotations.
+
+-------------------------------------------------------------------
Old:
----
pycodestyle-2.2.0.tar.gz
New:
----
pycodestyle-2.3.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-pycodestyle.spec ++++++
--- /var/tmp/diff_new_pack.SokDiX/_old 2017-02-22 13:54:36.767111157 +0100
+++ /var/tmp/diff_new_pack.SokDiX/_new 2017-02-22 13:54:36.767111157 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python3-pycodestyle
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -17,7 +17,7 @@
Name: python3-pycodestyle
-Version: 2.2.0
+Version: 2.3.1
Release: 0
Url: https://github.com/PyCQA/pycodestyle
Summary: Python style guide checker - formery python3-pep8
++++++ pycodestyle-2.2.0.tar.gz -> pycodestyle-2.3.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/CHANGES.txt new/pycodestyle-2.3.1/CHANGES.txt
--- old/pycodestyle-2.2.0/CHANGES.txt 2016-11-14 19:40:58.000000000 +0100
+++ new/pycodestyle-2.3.1/CHANGES.txt 2017-01-31 00:58:13.000000000 +0100
@@ -1,6 +1,29 @@
Changelog
=========
+2.3.1 (2017-01-31)
+------------------
+
+Bugs:
+
+* Fix regression in detection of E302 and E306; #618, #620
+
+2.3.0 (2017-01-30)
+------------------
+
+New Checks:
+
+* Add E722 warning for bare ``except`` clauses
+* Report E704 for async function definitions (``async def``)
+
+Bugs:
+
+* Fix another E305 false positive for variables beginning with "class" or
+ "def"
+* Fix detection of multiple spaces betwen ``async`` and ``def``
+* Fix handling of variable annotations. Stop reporting E701 on Python 3.6 for
+ variable annotations.
+
2.2.0 (2016-11-14)
------------------
@@ -28,6 +51,7 @@
* Report E741 on 'global' and 'nonlocal' statements, as well as prohibited
single-letter variables.
* Deprecated use of `[pep8]` section name in favor of `[pycodestyle]`; #591
+* Report E722 when bare except clause is used; #579
Bugs:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/PKG-INFO new/pycodestyle-2.3.1/PKG-INFO
--- old/pycodestyle-2.2.0/PKG-INFO 2016-11-14 19:41:50.000000000 +0100
+++ new/pycodestyle-2.3.1/PKG-INFO 2017-01-31 00:59:36.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: pycodestyle
-Version: 2.2.0
+Version: 2.3.1
Summary: Python style guide checker
Home-page: https://pycodestyle.readthedocs.io/
Author: Ian Lee
@@ -119,6 +119,29 @@
Changelog
=========
+ 2.3.1 (2017-01-31)
+ ------------------
+
+ Bugs:
+
+ * Fix regression in detection of E302 and E306; #618, #620
+
+ 2.3.0 (2017-01-30)
+ ------------------
+
+ New Checks:
+
+ * Add E722 warning for bare ``except`` clauses
+ * Report E704 for async function definitions (``async def``)
+
+ Bugs:
+
+ * Fix another E305 false positive for variables beginning with "class" or
+ "def"
+ * Fix detection of multiple spaces betwen ``async`` and ``def``
+ * Fix handling of variable annotations. Stop reporting E701 on Python 3.6 for
+ variable annotations.
+
2.2.0 (2016-11-14)
------------------
@@ -146,6 +169,7 @@
* Report E741 on 'global' and 'nonlocal' statements, as well as prohibited
single-letter variables.
* Deprecated use of `[pep8]` section name in favor of `[pycodestyle]`; #591
+ * Report E722 when bare except clause is used; #579
Bugs:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/docs/intro.rst new/pycodestyle-2.3.1/docs/intro.rst
--- old/pycodestyle-2.2.0/docs/intro.rst 2016-11-14 19:34:56.000000000 +0100
+++ new/pycodestyle-2.3.1/docs/intro.rst 2017-01-25 00:13:11.000000000 +0100
@@ -361,6 +361,8 @@
+------------+----------------------------------------------------------------------+
| E721 (^) | do not compare types, use 'isinstance()' |
+------------+----------------------------------------------------------------------+
+| E722 | do not use bare except, specify exception instead |
++------------+----------------------------------------------------------------------+
| E731 | do not assign a lambda expression, use a def |
+------------+----------------------------------------------------------------------+
| E741 | do not use variables named 'l', 'O', or 'I' |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/pycodestyle.egg-info/PKG-INFO new/pycodestyle-2.3.1/pycodestyle.egg-info/PKG-INFO
--- old/pycodestyle-2.2.0/pycodestyle.egg-info/PKG-INFO 2016-11-14 19:41:50.000000000 +0100
+++ new/pycodestyle-2.3.1/pycodestyle.egg-info/PKG-INFO 2017-01-31 00:59:35.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: pycodestyle
-Version: 2.2.0
+Version: 2.3.1
Summary: Python style guide checker
Home-page: https://pycodestyle.readthedocs.io/
Author: Ian Lee
@@ -119,6 +119,29 @@
Changelog
=========
+ 2.3.1 (2017-01-31)
+ ------------------
+
+ Bugs:
+
+ * Fix regression in detection of E302 and E306; #618, #620
+
+ 2.3.0 (2017-01-30)
+ ------------------
+
+ New Checks:
+
+ * Add E722 warning for bare ``except`` clauses
+ * Report E704 for async function definitions (``async def``)
+
+ Bugs:
+
+ * Fix another E305 false positive for variables beginning with "class" or
+ "def"
+ * Fix detection of multiple spaces betwen ``async`` and ``def``
+ * Fix handling of variable annotations. Stop reporting E701 on Python 3.6 for
+ variable annotations.
+
2.2.0 (2016-11-14)
------------------
@@ -146,6 +169,7 @@
* Report E741 on 'global' and 'nonlocal' statements, as well as prohibited
single-letter variables.
* Deprecated use of `[pep8]` section name in favor of `[pycodestyle]`; #591
+ * Report E722 when bare except clause is used; #579
Bugs:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/pycodestyle.egg-info/SOURCES.txt new/pycodestyle-2.3.1/pycodestyle.egg-info/SOURCES.txt
--- old/pycodestyle-2.2.0/pycodestyle.egg-info/SOURCES.txt 2016-11-14 19:41:50.000000000 +0100
+++ new/pycodestyle-2.3.1/pycodestyle.egg-info/SOURCES.txt 2017-01-31 00:59:36.000000000 +0100
@@ -21,6 +21,7 @@
pycodestyle.egg-info/namespace_packages.txt
pycodestyle.egg-info/not-zip-safe
pycodestyle.egg-info/top_level.txt
+testsuite/.E30not.py.swp
testsuite/E10.py
testsuite/E11.py
testsuite/E12.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/pycodestyle.py new/pycodestyle-2.3.1/pycodestyle.py
--- old/pycodestyle-2.2.0/pycodestyle.py 2016-11-14 19:38:29.000000000 +0100
+++ new/pycodestyle-2.3.1/pycodestyle.py 2017-01-31 00:57:04.000000000 +0100
@@ -66,7 +66,7 @@
except ImportError:
from ConfigParser import RawConfigParser
-__version__ = '2.2.0'
+__version__ = '2.3.1'
DEFAULT_EXCLUDE = '.svn,CVS,.bzr,.hg,.git,__pycache__,.tox'
DEFAULT_IGNORE = 'E121,E123,E126,E226,E24,E704,W503'
@@ -121,6 +121,20 @@
OPERATOR_REGEX = re.compile(r'(?:[^,\s])(\s*)(?:[-+*/|!<=>%&^]+)(\s*)')
LAMBDA_REGEX = re.compile(r'\blambda\b')
HUNK_REGEX = re.compile(r'^@@ -\d+(?:,\d+)? \+(\d+)(?:,(\d+))? @@.*$')
+STARTSWITH_DEF_REGEX = re.compile(r'^(async\s+def|def)')
+STARTSWITH_TOP_LEVEL_REGEX = re.compile(r'^(async\s+def\s+|def\s+|class\s+|@)')
+STARTSWITH_INDENT_STATEMENT_REGEX = re.compile(
+ r'^\s*({0})'.format('|'.join(s.replace(' ', '\s+') for s in (
+ 'def', 'async def',
+ 'for', 'async for',
+ 'if', 'elif', 'else',
+ 'try', 'except', 'finally',
+ 'with', 'async with',
+ 'class',
+ 'while',
+ )))
+)
+DUNDER_REGEX = re.compile(r'^__([^\s]+)__ = ')
# Work around Python < 2.6 behaviour, which does not generate NL after
# a comment which is on a line by itself.
@@ -264,6 +278,7 @@
E303: def a():\n\n\n\n pass
E304: @decorator\n\ndef a():\n pass
E305: def a():\n pass\na()
+ E306: def a():\n def b():\n pass\n def c():\n pass
"""
if line_number < 3 and not previous_logical:
return # Don't expect blank lines before the first line
@@ -272,7 +287,7 @@
yield 0, "E304 blank lines found after function decorator"
elif blank_lines > 2 or (indent_level and blank_lines == 2):
yield 0, "E303 too many blank lines (%d)" % blank_lines
- elif logical_line.startswith(('def ', 'async def', 'class ', '@')):
+ elif STARTSWITH_TOP_LEVEL_REGEX.match(logical_line):
if indent_level:
if not (blank_before or previous_indent_level < indent_level or
DOCSTRING_REGEX.match(previous_logical)):
@@ -813,7 +828,7 @@
no_space = False
prev_end = None
annotated_func_arg = False
- in_def = logical_line.startswith(('def', 'async def'))
+ in_def = bool(STARTSWITH_DEF_REGEX.match(logical_line))
message = "E251 unexpected spaces around keyword / parameter equals"
for token_type, text, start, end, line in tokens:
if token_type == tokenize.NL:
@@ -912,8 +927,10 @@
Okay: # this is a comment\nimport os
Okay: '''this is a module docstring'''\nimport os
Okay: r'''this is a module docstring'''\nimport os
- Okay: try:\n import x\nexcept:\n pass\nelse:\n pass\nimport y
- Okay: try:\n import x\nexcept:\n pass\nfinally:\n pass\nimport y
+ Okay:
+ try:\n\timport x\nexcept ImportError:\n\tpass\nelse:\n\tpass\nimport y
+ Okay:
+ try:\n\timport x\nexcept ImportError:\n\tpass\nfinally:\n\tpass\nimport y
E402: a=1\nimport os
E402: 'One string'\n"Two string"\nimport os
E402: a=1\nfrom sys import x
@@ -939,6 +956,8 @@
if line.startswith('import ') or line.startswith('from '):
if checker_state.get('seen_non_imports', False):
yield 0, "E402 module level import not at top of file"
+ elif re.match(DUNDER_REGEX, line):
+ return
elif any(line.startswith(kw) for kw in allowed_try_keywords):
# Allow try, except, else, finally keywords intermixed with imports in
# order to support conditional importing
@@ -998,9 +1017,9 @@
yield 0, ("E731 do not assign a lambda expression, use a "
"def")
break
- if line.startswith('def '):
+ if STARTSWITH_DEF_REGEX.match(line):
yield 0, "E704 multiple statements on one line (def)"
- else:
+ elif STARTSWITH_INDENT_STATEMENT_REGEX.match(line):
yield found, "E701 multiple statements on one line (colon)"
prev_found = found
found = line.find(':', found + 1)
@@ -1179,6 +1198,22 @@
yield match.start(), "E721 do not compare types, use 'isinstance()'"
+def bare_except(logical_line, noqa):
+ r"""When catching exceptions, mention specific exceptions whenever possible.
+
+ Okay: except Exception:
+ Okay: except BaseException:
+ E722: except:
+ """
+ if noqa:
+ return
+
+ regex = re.compile(r"except\s*:")
+ match = regex.match(logical_line)
+ if match:
+ yield match.start(), "E722 do not use bare except'"
+
+
def ambiguous_identifier(logical_line, tokens):
r"""Never use the characters 'l', 'O', or 'I' as variable names.
Binary files old/pycodestyle-2.2.0/testsuite/.E30not.py.swp and new/pycodestyle-2.3.1/testsuite/.E30not.py.swp differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E25.py new/pycodestyle-2.3.1/testsuite/E25.py
--- old/pycodestyle-2.2.0/testsuite/E25.py 2016-06-08 06:18:03.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E25.py 2017-01-25 00:13:11.000000000 +0100
@@ -38,3 +38,7 @@
#: Okay
async def add(a: int = 0, b: int = 0) -> int:
return a + b
+# Previously E251 four times
+#: E272:1:6
+async def add(a: int = 0, b: int = 0) -> int:
+ return a + b
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E30.py new/pycodestyle-2.3.1/testsuite/E30.py
--- old/pycodestyle-2.2.0/testsuite/E30.py 2016-08-13 20:42:06.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E30.py 2017-01-25 00:13:11.000000000 +0100
@@ -113,7 +113,7 @@
try:
a()
-except:
+except Exception:
pass
#: E305:5:1
def a():
@@ -156,3 +156,10 @@
if __name__ == '__main__':
main()
+# Previously just E272:1:6 E272:4:6
+#: E302:4:1 E272:1:6 E272:4:6
+async def x():
+ pass
+
+async def x(y: int = 1):
+ pass
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E30not.py new/pycodestyle-2.3.1/testsuite/E30not.py
--- old/pycodestyle-2.2.0/testsuite/E30not.py 2016-06-25 23:41:24.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E30not.py 2017-01-31 00:56:48.000000000 +0100
@@ -151,3 +151,14 @@
if __name__ == '__main__':
foo()
+#: Okay
+classification_errors = None
+#: Okay
+defined_properly = True
+#: Okay
+defaults = {}
+defaults.update({})
+#: Okay
+def foo(x):
+ classification = x
+ definitely = not classification
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E40.py new/pycodestyle-2.3.1/testsuite/E40.py
--- old/pycodestyle-2.2.0/testsuite/E40.py 2016-06-03 03:06:25.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E40.py 2017-01-27 21:51:02.000000000 +0100
@@ -11,14 +11,22 @@
import myclass
import foo.bar.yourclass
-#: E402
+#: Okay
__all__ = ['abc']
import foo
#: Okay
+__version__ = "42"
+
+import foo
+#: Okay
+__author__ = "Simon Gomizelj"
+
+import foo
+#: Okay
try:
import foo
-except:
+except ImportError:
pass
else:
print('imported foo')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E70.py new/pycodestyle-2.3.1/testsuite/E70.py
--- old/pycodestyle-2.2.0/testsuite/E70.py 2016-05-31 18:17:34.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E70.py 2017-01-25 00:13:11.000000000 +0100
@@ -12,6 +12,10 @@
del a[:]; a.append(42);
#: E704:1:1
def f(x): return 2
+#: E704:1:1
+async def f(x): return 2
+#: E704:1:1 E272:1:6
+async def f(x): return 2
#: E704:1:1 E226:1:19
def f(x): return 2*x
#: E704:2:5 E226:2:23
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E72.py new/pycodestyle-2.3.1/testsuite/E72.py
--- old/pycodestyle-2.2.0/testsuite/E72.py 2016-05-31 18:17:34.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E72.py 2017-01-25 00:13:11.000000000 +0100
@@ -49,3 +49,31 @@
pass
if type(a) != type(b) or type(a) == type(ccc):
pass
+#: E722
+try:
+ pass
+except:
+ pass
+#: E722
+try:
+ pass
+except Exception:
+ pass
+except:
+ pass
+#: E722 E203 E271
+try:
+ pass
+except :
+ pass
+#: Okay
+fake_code = """"
+try:
+ do_something()
+except:
+ pass
+"""
+try:
+ pass
+except Exception:
+ pass
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/E90.py new/pycodestyle-2.3.1/testsuite/E90.py
--- old/pycodestyle-2.2.0/testsuite/E90.py 2016-05-31 18:17:34.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/E90.py 2017-01-25 00:13:11.000000000 +0100
@@ -8,7 +8,7 @@
pass
except:
print 'Whoops'
-#: E122 E225 E251 E251 E701
+#: E122 E225 E251 E251
# Do not crash if code is invalid
if msg:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pycodestyle-2.2.0/testsuite/python3.py new/pycodestyle-2.3.1/testsuite/python3.py
--- old/pycodestyle-2.2.0/testsuite/python3.py 2016-05-31 18:17:34.000000000 +0200
+++ new/pycodestyle-2.3.1/testsuite/python3.py 2017-01-25 00:13:11.000000000 +0100
@@ -1,6 +1,18 @@
#!/usr/bin/env python3
+from typing import ClassVar, List
# Annotated function (Issue #29)
def foo(x: int) -> int:
return x + 1
+
+
+# Annotated variables #575
+CONST: int = 42
+
+
+class Class:
+ cls_var: ClassVar[str]
+
+ def m(self):
+ xs: List[int] = []
1
0
Hello community,
here is the log from the commit of package python3-polib for openSUSE:Factory checked in at 2017-02-22 13:54:27
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-polib (Old)
and /work/SRC/openSUSE:Factory/.python3-polib.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-polib"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-polib/python3-polib-doc.changes 2016-06-19 10:48:51.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.python3-polib.new/python3-polib-doc.changes 2017-02-22 13:54:28.332311311 +0100
@@ -1,0 +2,15 @@
+Mon Feb 20 20:12:52 UTC 2017 - arun(a)gmx.de
+
+- specfile:
+ * update copyright year
+
+- update to version 1.0.8:
+ * Fixed issue #70 (occurrences parsing for windows pathes)
+ * Fixed issue #71 (tcomment and flags not saved for obsolete
+ entries)
+ * Fixed issue #72 (wrong metadata ordering)
+ * Fixed issue #73 (can’t always unpickle POFile)
+ * Use natural sorting for additional headers (metadata)
+ * Fixed typos in various documents
+
+-------------------------------------------------------------------
python3-polib.changes: same change
Old:
----
polib-1.0.7.tar.gz
New:
----
polib-1.0.8.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-polib-doc.spec ++++++
--- /var/tmp/diff_new_pack.B0XpUQ/_old 2017-02-22 13:54:29.116199774 +0100
+++ /var/tmp/diff_new_pack.B0XpUQ/_new 2017-02-22 13:54:29.120199205 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python3-polib-doc
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -17,7 +17,7 @@
Name: python3-polib-doc
-Version: 1.0.7
+Version: 1.0.8
Release: 0
Summary: Documentation for Library to Manipulate gettext Files
License: MIT
python3-polib.spec: same change
++++++ polib-1.0.7.tar.gz -> polib-1.0.8.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/CHANGELOG new/polib-1.0.8/CHANGELOG
--- old/polib-1.0.7/CHANGELOG 2015-07-08 08:21:36.000000000 +0200
+++ new/polib-1.0.8/CHANGELOG 2016-11-21 14:30:52.000000000 +0100
@@ -2,6 +2,15 @@
Changelog
=========
+Version 1.0.8 (2016/11/21)
+--------------------------
+ - Fixed issue #70 (occurrences parsing for windows pathes)
+ - Fixed issue #71 (tcomment and flags not saved for obsolete entries)
+ - Fixed issue #72 (wrong metadata ordering)
+ - Fixed issue #73 (can't always unpickle POFile)
+ - Use natural sorting for additional headers (metadata)
+ - Fixed typos in various documents
+
Version 1.0.7 (2015/07/08)
--------------------------
- Fixed bad parsing of indented msgstr_plural
@@ -145,7 +154,7 @@
- fixed issue #0015: no LICENSE file included in tarball,
- removed Version/Date from README,
- added test pot files to MANIFEST.in,
- - performance improvment in find() method (thanks Thomas !).
+ - performance improvement in find() method (thanks Thomas !).
Version 0.4.1 (2009/03/04)
--------------------------
@@ -159,7 +168,7 @@
Version 0.4.0 (2008/11/26)
--------------------------
- fixed bug #0005: percent_translated divide by 0 on empty po files,
- - fixed bug #0004: occurrences that have hiphens are wrapped when they should not,
+ - fixed bug #0004: occurrences that have hyphens are wrapped when they should not,
- changes in how encoding is handled,
- remove deprecation warnings for typo on "occurrences",
- added POEntry.__cmp__() method to sort entries like gettext does,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/PKG-INFO new/polib-1.0.8/PKG-INFO
--- old/polib-1.0.7/PKG-INFO 2015-07-08 08:23:06.000000000 +0200
+++ new/polib-1.0.8/PKG-INFO 2016-11-21 14:32:21.000000000 +0100
@@ -1,12 +1,12 @@
Metadata-Version: 1.1
Name: polib
-Version: 1.0.7
+Version: 1.0.8
Summary: A library to manipulate gettext files (po and mo files).
Home-page: http://bitbucket.org/izi/polib/
Author: David Jean Louis
Author-email: izimobil(a)gmail.com
License: MIT
-Download-URL: https://pypi.python.org/packages/source/p/polib/polib-1.0.7.tar.gz
+Download-URL: https://pypi.python.org/packages/source/p/polib/polib-1.0.8.tar.gz
Description:
=====
polib
@@ -52,6 +52,15 @@
Changelog
=========
+ Version 1.0.8 (2016/11/21)
+ --------------------------
+ - Fixed issue #70 (occurrences parsing for windows pathes)
+ - Fixed issue #71 (tcomment and flags not saved for obsolete entries)
+ - Fixed issue #72 (wrong metadata ordering)
+ - Fixed issue #73 (can't always unpickle POFile)
+ - Use natural sorting for additional headers (metadata)
+ - Fixed typos in various documents
+
Version 1.0.7 (2015/07/08)
--------------------------
- Fixed bad parsing of indented msgstr_plural
@@ -195,7 +204,7 @@
- fixed issue #0015: no LICENSE file included in tarball,
- removed Version/Date from README,
- added test pot files to MANIFEST.in,
- - performance improvment in find() method (thanks Thomas !).
+ - performance improvement in find() method (thanks Thomas !).
Version 0.4.1 (2009/03/04)
--------------------------
@@ -209,7 +218,7 @@
Version 0.4.0 (2008/11/26)
--------------------------
- fixed bug #0005: percent_translated divide by 0 on empty po files,
- - fixed bug #0004: occurrences that have hiphens are wrapped when they should not,
+ - fixed bug #0004: occurrences that have hyphens are wrapped when they should not,
- changes in how encoding is handled,
- remove deprecation warnings for typo on "occurrences",
- added POEntry.__cmp__() method to sort entries like gettext does,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/__init__.py new/polib-1.0.8/__init__.py
--- old/polib-1.0.7/__init__.py 2014-12-05 10:19:35.000000000 +0100
+++ new/polib-1.0.8/__init__.py 2016-05-19 11:20:52.000000000 +0200
@@ -2,4 +2,4 @@
# version of polib as a mercurial sub-repository for example.
#
# This file will NOT be installed when installing polib with pip, setuptools,
-# or any other mecanism based on the setup.py file.
+# or any other mechanism based on the setup.py file.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/docs/projects.rst new/polib-1.0.8/docs/projects.rst
--- old/polib-1.0.7/docs/projects.rst 2014-12-05 10:19:35.000000000 +0100
+++ new/polib-1.0.8/docs/projects.rst 2016-05-19 11:20:52.000000000 +0200
@@ -11,7 +11,6 @@
* `Django-rosetta <http://code.google.com/p/django-rosetta/>`_
* `The evergreen library system <http://www.open-ils.org/>`_
* `Qooxdoo <http://qooxdoo.org/>`_
-* `<http://www.linux.rk.edu.pl/tra/list/>`_
* `Lictionary <http://www.lictionary.in/>`_
* `Jasy - Web Tooling Framework <https://github.com/sebastian-software/jasy>`_
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/polib.egg-info/PKG-INFO new/polib-1.0.8/polib.egg-info/PKG-INFO
--- old/polib-1.0.7/polib.egg-info/PKG-INFO 2015-07-08 08:23:06.000000000 +0200
+++ new/polib-1.0.8/polib.egg-info/PKG-INFO 2016-11-21 14:32:21.000000000 +0100
@@ -1,12 +1,12 @@
Metadata-Version: 1.1
Name: polib
-Version: 1.0.7
+Version: 1.0.8
Summary: A library to manipulate gettext files (po and mo files).
Home-page: http://bitbucket.org/izi/polib/
Author: David Jean Louis
Author-email: izimobil(a)gmail.com
License: MIT
-Download-URL: https://pypi.python.org/packages/source/p/polib/polib-1.0.7.tar.gz
+Download-URL: https://pypi.python.org/packages/source/p/polib/polib-1.0.8.tar.gz
Description:
=====
polib
@@ -52,6 +52,15 @@
Changelog
=========
+ Version 1.0.8 (2016/11/21)
+ --------------------------
+ - Fixed issue #70 (occurrences parsing for windows pathes)
+ - Fixed issue #71 (tcomment and flags not saved for obsolete entries)
+ - Fixed issue #72 (wrong metadata ordering)
+ - Fixed issue #73 (can't always unpickle POFile)
+ - Use natural sorting for additional headers (metadata)
+ - Fixed typos in various documents
+
Version 1.0.7 (2015/07/08)
--------------------------
- Fixed bad parsing of indented msgstr_plural
@@ -195,7 +204,7 @@
- fixed issue #0015: no LICENSE file included in tarball,
- removed Version/Date from README,
- added test pot files to MANIFEST.in,
- - performance improvment in find() method (thanks Thomas !).
+ - performance improvement in find() method (thanks Thomas !).
Version 0.4.1 (2009/03/04)
--------------------------
@@ -209,7 +218,7 @@
Version 0.4.0 (2008/11/26)
--------------------------
- fixed bug #0005: percent_translated divide by 0 on empty po files,
- - fixed bug #0004: occurrences that have hiphens are wrapped when they should not,
+ - fixed bug #0004: occurrences that have hyphens are wrapped when they should not,
- changes in how encoding is handled,
- remove deprecation warnings for typo on "occurrences",
- added POEntry.__cmp__() method to sort entries like gettext does,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/polib.py new/polib-1.0.8/polib.py
--- old/polib-1.0.7/polib.py 2015-07-08 08:14:47.000000000 +0200
+++ new/polib-1.0.8/polib.py 2016-11-21 14:27:20.000000000 +0100
@@ -13,7 +13,7 @@
"""
__author__ = 'David Jean Louis <izimobil(a)gmail.com>'
-__version__ = '1.0.7'
+__version__ = '1.0.8'
__all__ = ['pofile', 'POFile', 'POEntry', 'mofile', 'MOFile', 'MOEntry',
'default_encoding', 'escape', 'unescape', 'detect_encoding', ]
@@ -262,13 +262,25 @@
return m # handles escaped double quote
return re.sub(r'\\(\\|n|t|r|")', unescape_repl, st)
# }}}
+# function natural_sort() {{{
+
+
+def natural_sort(lst):
+ """
+ Sort naturally the given list.
+ Credits: http://stackoverflow.com/a/4836734
+ """
+ convert = lambda text: int(text) if text.isdigit() else text.lower()
+ alphanum_key = lambda key: [ convert(c) for c in re.split('([0-9]+)', key) ]
+ return sorted(lst, key = alphanum_key)
+# }}}
# class _BaseFile {{{
class _BaseFile(list):
"""
Common base class for the :class:`~polib.POFile` and :class:`~polib.MOFile`
- classes. This class should **not** be instanciated directly.
+ classes. This class should **not** be instantiated directly.
"""
def __init__(self, *args, **kwargs):
@@ -367,7 +379,9 @@
``entry``
an instance of :class:`~polib._BaseEntry`.
"""
- if self.check_for_duplicates and entry in self:
+ # check_for_duplicates may not be defined (yet) when unpickling.
+ # But if pickling, we never want to check for duplicates anyway.
+ if getattr(self, 'check_for_duplicates', False) and entry in self:
raise ValueError('Entry "%s" already exists' % entry.msgid)
super(_BaseFile, self).append(entry)
@@ -483,10 +497,10 @@
'PO-Revision-Date',
'Last-Translator',
'Language-Team',
+ 'Language',
'MIME-Version',
'Content-Type',
'Content-Transfer-Encoding',
- 'Language',
'Plural-Forms'
]
ordered_data = []
@@ -498,7 +512,7 @@
pass
# the rest of the metadata will be alphabetically ordered since there
# are no specs for this AFAIK
- for data in sorted(metadata.keys()):
+ for data in natural_sort(metadata.keys()):
value = metadata[data]
ordered_data.append((data, value))
return ordered_data
@@ -780,7 +794,7 @@
class _BaseEntry(object):
"""
Base class for :class:`~polib.POEntry` and :class:`~polib.MOEntry` classes.
- This class should **not** be instanciated directly.
+ This class should **not** be instantiated directly.
"""
def __init__(self, *args, **kwargs):
@@ -953,12 +967,12 @@
"""
Returns the unicode representation of the entry.
"""
- if self.obsolete:
- return _BaseEntry.__unicode__(self, wrapwidth)
-
ret = []
# comments first, if any (with text wrapping as xgettext does)
- comments = [('comment', '#. '), ('tcomment', '# ')]
+ if self.obsolete:
+ comments = [('tcomment', '# ')]
+ else:
+ comments = [('comment', '#. '), ('tcomment', '# ')]
for c in comments:
val = getattr(self, c[0])
if val:
@@ -975,7 +989,7 @@
ret.append('%s%s' % (c[1], comment))
# occurrences (with text wrapping as xgettext does)
- if self.occurrences:
+ if not self.obsolete and self.occurrences:
filelist = []
for fpath, lineno in self.occurrences:
if lineno:
@@ -1005,17 +1019,17 @@
# previous context and previous msgid/msgid_plural
fields = ['previous_msgctxt', 'previous_msgid',
'previous_msgid_plural']
+ if self.obsolete:
+ prefix = "#~| "
+ else:
+ prefix = "#| "
for f in fields:
val = getattr(self, f)
if val:
- ret += self._str_field(f, "#| ", "", val, wrapwidth)
+ ret += self._str_field(f, prefix, "", val, wrapwidth)
ret.append(_BaseEntry.__unicode__(self, wrapwidth))
ret = u('\n').join(ret)
-
- assert isinstance(ret, text_type)
- #if type(ret) != types.UnicodeType:
- # return unicode(ret, self.encoding)
return ret
def __cmp__(self, other):
@@ -1490,7 +1504,7 @@
for occurrence in occurrences:
if occurrence != '':
try:
- fil, line = occurrence.split(':')
+ fil, line = occurrence.rsplit(':', 1)
if not line.isdigit():
fil = fil + line
line = ''
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/tests/test_fuzzy_header.po new/polib-1.0.8/tests/test_fuzzy_header.po
--- old/polib-1.0.7/tests/test_fuzzy_header.po 2014-12-05 10:19:35.000000000 +0100
+++ new/polib-1.0.8/tests/test_fuzzy_header.po 2016-11-21 13:07:50.000000000 +0100
@@ -12,3 +12,6 @@
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
+"X-Poedit-SearchPath-1: Foo\n"
+"X-Poedit-SearchPath-2: Bar\n"
+"X-Poedit-SearchPath-10: Baz\n"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/tests/test_weird_occurrences.po new/polib-1.0.8/tests/test_weird_occurrences.po
--- old/polib-1.0.7/tests/test_weird_occurrences.po 2014-12-05 10:19:35.000000000 +0100
+++ new/polib-1.0.8/tests/test_weird_occurrences.po 2016-11-21 13:55:52.000000000 +0100
@@ -14,6 +14,12 @@
"X-Etoys-Domain: etoys\n"
"X-Etoys-SystemVersion: etoys3.0 of 24 February 2008 update 2029\n"
+
+# Windows paths
+#: C:\foo\bar.py:12
+msgid "Windows path"
+msgstr "Windows path"
+
#. Test for empty comment lines
#.
#,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/polib-1.0.7/tests/tests.py new/polib-1.0.8/tests/tests.py
--- old/polib-1.0.7/tests/tests.py 2015-07-07 14:27:59.000000000 +0200
+++ new/polib-1.0.8/tests/tests.py 2016-11-21 13:04:46.000000000 +0100
@@ -88,7 +88,7 @@
Test that weird occurrences are correctly parsed.
"""
po = polib.pofile('tests/test_weird_occurrences.po')
- self.assertEqual(len(po), 46)
+ self.assertEqual(len(po), 47)
def test_pofile_and_mofile9(self):
"""
@@ -209,7 +209,7 @@
def test_detect_encoding1(self):
"""
- Test that given enconding is returned when file has no encoding defined.
+ Test that given encoding is returned when file has no encoding defined.
"""
self.assertEqual(polib.detect_encoding('tests/test_noencoding.po'), 'utf-8')
@@ -314,6 +314,10 @@
po = polib.pofile('tests/test_utf8.po')
self.assertEqual(po[-1].linenum, 3478)
+ def test_windows_path_occurrences(self):
+ po = polib.pofile('tests/test_weird_occurrences.po')
+ self.assertEqual(po[0].occurrences, [('C:\\foo\\bar.py', '12')])
+
class TestBaseFile(unittest.TestCase):
"""
@@ -414,7 +418,10 @@
('Language-Team', u('LANGUAGE <LL(a)li.org>')),
('MIME-Version', u('1.0')),
('Content-Type', u('text/plain; charset=UTF-8')),
- ('Content-Transfer-Encoding', u('8bit'))
+ ('Content-Transfer-Encoding', u('8bit')),
+ ('X-Poedit-SearchPath-1', u('Foo')),
+ ('X-Poedit-SearchPath-2', u('Bar')),
+ ('X-Poedit-SearchPath-10', u('Baz')),
]
self.assertEqual(pofile.ordered_metadata(), mdata)
1
0
Hello community,
here is the log from the commit of package courier-authlib for openSUSE:Factory checked in at 2017-02-22 13:54:22
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/courier-authlib (Old)
and /work/SRC/openSUSE:Factory/.courier-authlib.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "courier-authlib"
Changes:
--------
--- /work/SRC/openSUSE:Factory/courier-authlib/courier-authlib.changes 2016-05-17 17:16:23.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.courier-authlib.new/courier-authlib.changes 2017-02-22 13:54:22.469145567 +0100
@@ -1,0 +2,5 @@
+Sat Feb 18 17:31:33 UTC 2017 - kukuk(a)suse.com
+
+- Don't call insserv if we use systemd
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ courier-authlib.spec ++++++
--- /var/tmp/diff_new_pack.YOcjiM/_old 2017-02-22 13:54:23.241035735 +0100
+++ /var/tmp/diff_new_pack.YOcjiM/_new 2017-02-22 13:54:23.241035735 +0100
@@ -1,7 +1,7 @@
#
# spec file for package courier-authlib
#
-# Copyright (c) 2016 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -204,12 +204,13 @@
%postun
/sbin/ldconfig
+%if 0%{?has_systemd}
+%service_del_postun courier-authdaemon.service
+%else
%if 0%{?suse_version}
%restart_on_update courier-authdaemon
%insserv_cleanup
%endif
-%if 0%{?has_systemd}
-%service_del_postun courier-authdaemon.service
%endif
%post userdb -p /sbin/ldconfig
1
0
Hello community,
here is the log from the commit of package qscintilla for openSUSE:Factory checked in at 2017-02-22 13:54:12
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/qscintilla (Old)
and /work/SRC/openSUSE:Factory/.qscintilla.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "qscintilla"
Changes:
--------
--- /work/SRC/openSUSE:Factory/qscintilla/python-qscintilla.changes 2017-01-20 13:07:17.634633679 +0100
+++ /work/SRC/openSUSE:Factory/.qscintilla.new/python-qscintilla.changes 2017-02-22 13:54:13.290451596 +0100
@@ -1,0 +2,5 @@
+Thu Feb 16 18:51:38 UTC 2017 - termim(a)gmail.com
+
+- Require sip 4.19.1 for compatibility with PyQt5
+
+-------------------------------------------------------------------
python3-qscintilla.changes: same change
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-qscintilla.spec ++++++
--- /var/tmp/diff_new_pack.sO9zjh/_old 2017-02-22 13:54:14.058342333 +0100
+++ /var/tmp/diff_new_pack.sO9zjh/_new 2017-02-22 13:54:14.058342333 +0100
@@ -28,10 +28,10 @@
BuildRequires: libqscintilla-devel
BuildRequires: python-devel
BuildRequires: python-qt4-devel
-BuildRequires: python-sip-devel >= 4.19
+BuildRequires: python-sip-devel >= 4.19.1
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%requires_ge python-qt4
-%requires_ge python-sip >= 4.19
+%requires_ge python-sip >= 4.19.1
%requires_ge libqt4-x11
%description
++++++ python3-qscintilla.spec ++++++
--- /var/tmp/diff_new_pack.sO9zjh/_old 2017-02-22 13:54:14.078339487 +0100
+++ /var/tmp/diff_new_pack.sO9zjh/_new 2017-02-22 13:54:14.078339487 +0100
@@ -28,10 +28,10 @@
BuildRequires: libqscintilla-devel
BuildRequires: python3-devel
BuildRequires: python3-qt4-devel
-BuildRequires: python3-sip-devel >= 4.19
+BuildRequires: python3-sip-devel >= 4.19.1
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%requires_ge python3-qt4
-%requires_ge python3-sip >= 4.19
+%requires_ge python3-sip >= 4.19.1
%requires_ge libqt4-x11
%description
1
0
Hello community,
here is the log from the commit of package python3-QtPy for openSUSE:Factory checked in at 2017-02-22 13:54:07
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python3-QtPy (Old)
and /work/SRC/openSUSE:Factory/.python3-QtPy.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python3-QtPy"
Changes:
--------
--- /work/SRC/openSUSE:Factory/python3-QtPy/python3-QtPy.changes 2017-01-25 23:18:13.393038002 +0100
+++ /work/SRC/openSUSE:Factory/.python3-QtPy.new/python3-QtPy.changes 2017-02-22 13:54:08.319158965 +0100
@@ -1,0 +2,40 @@
+Thu Feb 16 09:13:41 UTC 2017 - joerg.lorenzen(a)ki.tng.de
+
+- Update to version 1.2.1
+ - Bugs fixed:
+ Pull requests
+ + PR 98 - PR: Don't use Travis to test macOS because it slows
+ down the entire spyder-ide organization
+ + PR 97 - PR: Update Appveyor badge in Readme because of moving
+ to an org account
+ + PR 94 - PR: Include test suite in sdist
+
+- Version 1.2
+ - New features:
+ + Add support for QtMultimedia
+ + Use relative imports so its vendored more easily
+ - Bugs fixed:
+ Issues
+ + Issue 83 - Include core doc files in PyPi releases
+ + Issue 78 - Request for a new bugfix release
+ + Issue 75 - Missing copyright headers
+ + Issue 67 - uic.loadUiType is missing
+ + Issue 64 - QHeaderView.setSectionResizeMode
+ + Issue 49 - QtMultimedia support
+ Pull requests
+ + PR 93 - Restore uic full namespace for PyQt5 and PyQt4
+ + PR 92 - Add missing copyright header in _patch/qheaderview.py
+ + PR 91 - Use star imports in QtSvg again instead of direct
+ ones (reverts PR #55)
+ + PR 88 - PR: Add manifest
+ + PR 74 - Move QStringListModel to QtCore
+ + PR 71 - PR: Use relative imports so its vendored more easily
+ + PR 65 - Introduce renamed methods of QHeaderView in PyQt4 and
+ PySide
+ + PR 59 - Don't install qtpy as a conda package in CircleCI
+ + PR 58 - Remove reference to how qtpy is pronounced in README
+ + PR 55 - PR: Add explicit imports to QtSvg module
+ + PR 50 - Add support for QtMultimedia
+- Removed source file LICENSE.txt, fixed upstream.
+
+-------------------------------------------------------------------
Old:
----
LICENSE.txt
QtPy-1.1.2.tar.gz
New:
----
QtPy-1.2.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python3-QtPy.spec ++++++
--- /var/tmp/diff_new_pack.UFXSqF/_old 2017-02-22 13:54:08.691106040 +0100
+++ /var/tmp/diff_new_pack.UFXSqF/_new 2017-02-22 13:54:08.691106040 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python3-QtPy
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -16,15 +16,13 @@
Name: python3-QtPy
-Version: 1.1.2
+Version: 1.2.1
Release: 0
License: MIT
Summary: Abstraction layer on top of Qt bindings
Url: https://github.com/spyder-ide/qtpy
Group: Development/Languages/Python
Source: https://files.pythonhosted.org/packages/source/Q/QtPy/QtPy-%{version}.tar.gz
-# This will be included in the tarball in the next release. It can be removed then.
-Source1: LICENSE.txt
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-qt5
@@ -44,7 +42,6 @@
%prep
%setup -q -n QtPy-%{version}
-cp %{SOURCE1} ./
%build
python3 setup.py build
++++++ QtPy-1.1.2.tar.gz -> QtPy-1.2.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/AUTHORS.md new/QtPy-1.2.1/AUTHORS.md
--- old/QtPy-1.1.2/AUTHORS.md 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/AUTHORS.md 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,16 @@
+Maintainer
+==========
+
+Gonzalo Peña-Castellanos ([@goanpeca](http://github.com/goanpeca))
+
+Main Authors
+============
+
+* Colin Duquesnoy ([@ColinDuquesnoy](http://github.com/ColinDuquesnoy))
+
+* [The Spyder Development Team](https://github.com/spyder-ide/spyder/graphs/contributors)
+
+Contributors
+============
+
+* Thomas Robitaille ([@astrofrog](http://www.github.com/astrofrog))
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/CHANGELOG.md new/QtPy-1.2.1/CHANGELOG.md
--- old/QtPy-1.1.2/CHANGELOG.md 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/CHANGELOG.md 2017-01-22 03:08:58.000000000 +0100
@@ -0,0 +1,190 @@
+# History of changes
+
+## Version 1.2.1 (2017/01/21)
+
+### Bugs fixed
+
+**Pull requests**
+
+* [PR 98](https://github.com/spyder-ide/qtpy/pull/98) - PR: Don't use Travis to test macOS because it slows down the entire spyder-ide organization
+* [PR 97](https://github.com/spyder-ide/qtpy/pull/97) - PR: Update Appveyor badge in Readme because of moving to an org account
+* [PR 94](https://github.com/spyder-ide/qtpy/pull/94) - PR: Include test suite in sdist
+
+In this release 3 pull requests were merged
+
+
+----
+
+
+## Version 1.2 (2017/01/08)
+
+### New features
+
+* Add support for QtMultimedia
+* Use relative imports so its vendored more easily
+
+### Bugs fixed
+
+**Issues**
+
+* [Issue 83](https://github.com/spyder-ide/qtpy/issues/83) - Include core doc files in PyPi releases
+* [Issue 78](https://github.com/spyder-ide/qtpy/issues/78) - Request for a new bugfix release
+* [Issue 75](https://github.com/spyder-ide/qtpy/issues/75) - Missing copyright headers
+* [Issue 67](https://github.com/spyder-ide/qtpy/issues/67) - uic.loadUiType is missing
+* [Issue 64](https://github.com/spyder-ide/qtpy/issues/64) - QHeaderView.setSectionResizeMode
+* [Issue 49](https://github.com/spyder-ide/qtpy/issues/49) - QtMultimedia support
+
+In this release 6 issues were closed
+
+**Pull requests**
+
+* [PR 93](https://github.com/spyder-ide/qtpy/pull/93) - Restore uic full namespace for PyQt5 and PyQt4
+* [PR 92](https://github.com/spyder-ide/qtpy/pull/92) - Add missing copyright header in _patch/qheaderview.py
+* [PR 91](https://github.com/spyder-ide/qtpy/pull/91) - Use star imports in QtSvg again instead of direct ones (reverts PR #55)
+* [PR 88](https://github.com/spyder-ide/qtpy/pull/88) - PR: Add manifest
+* [PR 74](https://github.com/spyder-ide/qtpy/pull/74) - Move QStringListModel to QtCore
+* [PR 71](https://github.com/spyder-ide/qtpy/pull/71) - PR: Use relative imports so its vendored more easily
+* [PR 65](https://github.com/spyder-ide/qtpy/pull/65) - Introduce renamed methods of QHeaderView in PyQt4 and PySide
+* [PR 59](https://github.com/spyder-ide/qtpy/pull/59) - Don't install qtpy as a conda package in CircleCI
+* [PR 58](https://github.com/spyder-ide/qtpy/pull/58) - Remove reference to how qtpy is pronounced in README
+* [PR 55](https://github.com/spyder-ide/qtpy/pull/55) - PR: Add explicit imports to QtSvg module
+* [PR 50](https://github.com/spyder-ide/qtpy/pull/50) - Add support for QtMultimedia
+
+In this release 11 pull requests were merged
+
+
+----
+
+
+## Version 1.1.2 (2016-08-08)
+
+### Bugfixes
+
+**Pull requests**
+
+* [PR 54](https://github.com/spyder-ide/qtpy/pull/54) - PR: Fix/ci
+* [PR 53](https://github.com/spyder-ide/qtpy/pull/53) - PR: Move tests to module so they can be run when installed
+* [PR 52](https://github.com/spyder-ide/qtpy/pull/52) - PR: Update readme
+* [PR 51](https://github.com/spyder-ide/qtpy/pull/51) - PR: Add circle ci
+* [PR 47](https://github.com/spyder-ide/qtpy/pull/47) - Remove PyQt variant symbols from QtCore
+* [PR 46](https://github.com/spyder-ide/qtpy/pull/46) - del QtWidgets.QStyleOptionViewItemV4
+* [PR 45](https://github.com/spyder-ide/qtpy/pull/45) - Allow QT_API values that are not completely in lower case
+
+In this release 7 pull requests were merged
+
+
+----
+
+
+## Version 1.1.1 (2016-07-01)
+
+### Bugfixes
+
+**Pull requests**
+
+* [PR 44](https://github.com/spyder-ide/qtpy/pull/44) - Make qtpy to set the QT_API environment variable
+
+In this release 1 pull requests were merged
+
+
+---
+
+
+## Version 1.1 (2016-06-30)
+
+### New features
+
+* Make importing `qtpy` thread-safe
+* Add a uic module to make loadUI work for PySide
+* Add QtTest support for PySide
+
+### Bugfixes
+
+**Issues**
+
+* [Issue 42](https://github.com/spyder-ide/qtpy/issues/42) - Wrong old PyQt4 version check
+* [Issue 21](https://github.com/spyder-ide/qtpy/issues/21) - Patch QComboBox with PySide?
+* [Issue 16](https://github.com/spyder-ide/qtpy/issues/16) - Add loadUI functionality
+
+In this release 3 issues were closed
+
+**Pull requests**
+
+* [PR 43](https://github.com/spyder-ide/qtpy/pull/43) - Don't check PyQt version with qtpy's version for old PyQt versions
+* [PR 41](https://github.com/spyder-ide/qtpy/pull/41) - `qtpy.__version__` should be QtPy version, not Qt version
+* [PR 40](https://github.com/spyder-ide/qtpy/pull/40) - Mention qt-helpers in README.md, and add myself to AUTHORS.md
+* [PR 39](https://github.com/spyder-ide/qtpy/pull/39) - Fix remaining segmentation fault that occurs with the patched QComboBox in PySide
+* [PR 38](https://github.com/spyder-ide/qtpy/pull/38) - QtTest for PySide
+* [PR 37](https://github.com/spyder-ide/qtpy/pull/37) - Automatically load custom widget classes when using PySide
+* [PR 33](https://github.com/spyder-ide/qtpy/pull/33) - Ignore case for QT_API env variable in qtpy submodules
+* [PR 32](https://github.com/spyder-ide/qtpy/pull/32) - Remove QItemSelectionModel from QtWidgets for PyQt4 and PySide
+* [PR 31](https://github.com/spyder-ide/qtpy/pull/31) - Add compatibility for QItemSelectionModel
+* [PR 29](https://github.com/spyder-ide/qtpy/pull/29) - Use ci-helpers (from Astropy) for CI and enable AppVeyor
+* [PR 28](https://github.com/spyder-ide/qtpy/pull/28) - Make tests.py into proper unit test, and add Qt version info to pytest header
+* [PR 27](https://github.com/spyder-ide/qtpy/pull/27) - Make sure loadUi is available
+* [PR 25](https://github.com/spyder-ide/qtpy/pull/25) - Add patched version of QComboBox
+
+In this release 13 pull requests were merged
+
+
+---
+
+
+## Version 1.0.2 (2016-06-02)
+
+### New features
+
+* Add a WEBENGINE constant to QtWebEngineWidgets, which is True if Qt 5 comes with the WebEngine module and False otherwise.
+
+### Bugfixes
+
+**Pull requests**
+
+* [PR 24](https://github.com/spyder-ide/qtpy/pull/24) - Add constant to QtWebEngineWidgets to see if we are using WebEngine or WebKit
+* [PR 23](https://github.com/spyder-ide/qtpy/pull/23) - Fix "Prefer `format()` over string interpolation operator" issue
+
+In this release 2 pull requests were merged
+
+
+---
+
+
+## Version 1.0.1 (2016-04-10)
+
+### Bugfixes
+
+**Issues**
+
+* [Issue 18](https://github.com/spyder-ide/qtpy/issues/18) - QIntValidator left in QtWidgets, should be in QtGui
+
+In this release 1 issues were closed
+
+**Pull requests**
+
+* [PR 19](https://github.com/spyder-ide/qtpy/pull/19) - Import QIntValidator in QtGui and remove it from QtWidgets
+
+In this release 1 pull requests were merged
+
+
+----
+
+## Version 1.0 (2016-03-22)
+
+* Add QtWebEngineWidgets module for Qt 5.6. This module replaces the previous
+ QtWebKit one.
+
+* Import the right objects in QtGui, QtWidgets and QtCore
+
+* Add a QtPrintSupport module
+
+
+---
+
+
+## Version 0.1.3 (2015-12-30)
+
+* Add tests and continuous integration
+
+## Version 0.1.2 (2015-03-01)
+
+* First release
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/LICENSE.txt new/QtPy-1.2.1/LICENSE.txt
--- old/QtPy-1.1.2/LICENSE.txt 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/LICENSE.txt 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,22 @@
+The MIT License (MIT)
+
+Copyright (c) The Spyder Development Team
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/MANIFEST.in new/QtPy-1.2.1/MANIFEST.in
--- old/QtPy-1.1.2/MANIFEST.in 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/MANIFEST.in 2017-01-22 03:05:55.000000000 +0100
@@ -0,0 +1,5 @@
+include AUTHORS.md
+include CHANGELOG.md
+include LICENSE.txt
+include README.md
+recursive-include qtpy/tests *
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/PKG-INFO new/QtPy-1.2.1/PKG-INFO
--- old/QtPy-1.1.2/PKG-INFO 2016-08-09 00:32:35.000000000 +0200
+++ new/QtPy-1.2.1/PKG-INFO 2017-01-22 03:10:28.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: QtPy
-Version: 1.1.2
+Version: 1.2.1
Summary: Provides an abstraction layer on top of the various Qt bindings (PyQt5, PyQt4 and PySide) and additional custom QWidgets.
Home-page: https://github.com/spyder-ide/qtpy
Author: Gonzalo Peña-Castellanos
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/QtPy.egg-info/PKG-INFO new/QtPy-1.2.1/QtPy.egg-info/PKG-INFO
--- old/QtPy-1.1.2/QtPy.egg-info/PKG-INFO 2016-08-09 00:32:35.000000000 +0200
+++ new/QtPy-1.2.1/QtPy.egg-info/PKG-INFO 2017-01-22 03:10:27.000000000 +0100
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: QtPy
-Version: 1.1.2
+Version: 1.2.1
Summary: Provides an abstraction layer on top of the various Qt bindings (PyQt5, PyQt4 and PySide) and additional custom QWidgets.
Home-page: https://github.com/spyder-ide/qtpy
Author: Gonzalo Peña-Castellanos
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/QtPy.egg-info/SOURCES.txt new/QtPy-1.2.1/QtPy.egg-info/SOURCES.txt
--- old/QtPy-1.1.2/QtPy.egg-info/SOURCES.txt 2016-08-09 00:32:35.000000000 +0200
+++ new/QtPy-1.2.1/QtPy.egg-info/SOURCES.txt 2017-01-22 03:10:28.000000000 +0100
@@ -1,3 +1,8 @@
+AUTHORS.md
+CHANGELOG.md
+LICENSE.txt
+MANIFEST.in
+README.md
setup.cfg
setup.py
QtPy.egg-info/PKG-INFO
@@ -7,6 +12,7 @@
qtpy/QtCore.py
qtpy/QtDesigner.py
qtpy/QtGui.py
+qtpy/QtMultimedia.py
qtpy/QtNetwork.py
qtpy/QtPrintSupport.py
qtpy/QtSvg.py
@@ -19,4 +25,19 @@
qtpy/py3compat.py
qtpy/uic.py
qtpy/_patch/__init__.py
-qtpy/_patch/qcombobox.py
\ No newline at end of file
+qtpy/_patch/qcombobox.py
+qtpy/_patch/qheaderview.py
+qtpy/tests/conftest.py
+qtpy/tests/runtests.py
+qtpy/tests/test.ui
+qtpy/tests/test_custom.ui
+qtpy/tests/test_main.py
+qtpy/tests/test_patch_qcombobox.py
+qtpy/tests/test_patch_qheaderview.py
+qtpy/tests/test_qtmultimedia.py
+qtpy/tests/test_uic.py
+qtpy/tests/__pycache__/conftest.cpython-35.pyc
+qtpy/tests/__pycache__/test_main.cpython-35-PYTEST.pyc
+qtpy/tests/__pycache__/test_patch_qcombobox.cpython-35-PYTEST.pyc
+qtpy/tests/__pycache__/test_qtmultimedia.cpython-35-PYTEST.pyc
+qtpy/tests/__pycache__/test_uic.cpython-35-PYTEST.pyc
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/README.md new/QtPy-1.2.1/README.md
--- old/QtPy-1.1.2/README.md 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/README.md 2017-01-22 03:07:05.000000000 +0100
@@ -0,0 +1,70 @@
+# QtPy: Abtraction layer for PyQt5/PyQt4/PySide
+
+Copyright © 2009- The Spyder Development Team.
+
+## Project details
+[![license](https://img.shields.io/pypi/l/qtpy.svg)](./LICENSE)
+[![pypi version](https://img.shields.io/pypi/v/qtpy.svg)](https://pypi.python.org/p…
+[![Join the chat at https://gitter.im/spyder-ide/public](https://badges.gitter.im/spyder-ide/sp…
+
+## Build status
+[![Build status](https://ci.appveyor.com/api/projects/status/62y6i02vhn4hefg0/branch…
+[![CircleCI](https://circleci.com/gh/spyder-ide/qtpy.svg?style=shield)](https://circleci.com/gh/spyder-ide/qtpy)
+[![Coverage Status](https://coveralls.io/repos/github/spyder-ide/qtpy/badge.svg?branch=master)](https://coveralls.io/github/spyder-ide/qtpy?branch=master)
+[![Code Issues](https://www.quantifiedcode.com/api/v1/project/c769241c7d7f4463b1e6f…
+[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/spyder-ide/qtpy/badges/quality-score.…
+
+## Description
+
+**QtPy** is a small abstraction layer that lets you
+write applications using a single API call to either PyQt or PySide.
+
+It provides support for PyQt5, PyQt4 and PySide using the PyQt5 layout (where
+the QtGui module has been split into QtGui and QtWidgets).
+
+Basically, you write your code as if you were using PyQt5 but import Qt modules
+from `qtpy` instead of `PyQt5`.
+
+
+### Attribution and acknowledgements
+
+This project is based on the [pyqode.qt](https://github.com/pyQode/pyqode.qt)
+project and the [spyderlib.qt](https://github.com/spyder-ide/spyder/tree/2.3/spyderlib/qt)
+module from the [Spyder](https://github.com/spyder-ide/spyder) project, and
+also includes contributions adapted from
+[qt-helpers](https://github.com/glue-viz/qt-helpers), developed as part of the
+[glue](http://glueviz.org) project.
+
+Unlike `pyqode.qt` this is not a namespace package, so it is not tied
+to a particular project or namespace.
+
+
+### License
+
+This project is licensed under the MIT license.
+
+
+### Requirements
+
+You need PyQt5, PyQt4 or PySide installed in your system to make use
+of QtPy. If several of these packages are found, PyQt5 is used by
+default unless you set the `QT_API` environment variable.
+
+`QT_API` can take the following values:
+
+* `pyqt5` (to use PyQt5).
+* `pyqt` or `pyqt4` (to use PyQt4).
+* `pyside` (to use PySide).
+
+
+### Installation
+
+```bash
+pip install qtpy
+```
+
+or
+
+```bash
+conda install qtpy
+```
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtCore.py new/QtPy-1.2.1/qtpy/QtCore.py
--- old/QtPy-1.1.2/qtpy/QtCore.py 2016-08-08 23:58:16.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtCore.py 2017-01-02 23:05:09.000000000 +0100
@@ -10,7 +10,7 @@
Provides QtCore classes and functions.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
if PYQT5:
@@ -32,7 +32,8 @@
from PyQt4.QtCore import pyqtSlot as Slot
from PyQt4.QtCore import pyqtProperty as Property
from PyQt4.QtGui import (QItemSelection, QItemSelectionModel,
- QItemSelectionRange, QSortFilterProxyModel)
+ QItemSelectionRange, QSortFilterProxyModel,
+ QStringListModel)
from PyQt4.QtCore import QT_VERSION_STR as __version__
# Those are imported from `import *`
@@ -40,7 +41,8 @@
elif PYSIDE:
from PySide.QtCore import *
from PySide.QtGui import (QItemSelection, QItemSelectionModel,
- QItemSelectionRange, QSortFilterProxyModel)
+ QItemSelectionRange, QSortFilterProxyModel,
+ QStringListModel)
import PySide.QtCore
__version__ = PySide.QtCore.__version__
else:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtDesigner.py new/QtPy-1.2.1/qtpy/QtDesigner.py
--- old/QtPy-1.1.2/qtpy/QtDesigner.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtDesigner.py 2017-01-02 21:13:51.000000000 +0100
@@ -9,7 +9,7 @@
Provides QtDesigner classes and functions.
"""
-from qtpy import PYQT5, PYQT4, PythonQtError
+from . import PYQT5, PYQT4, PythonQtError
if PYQT5:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtGui.py new/QtPy-1.2.1/qtpy/QtGui.py
--- old/QtPy-1.1.2/qtpy/QtGui.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtGui.py 2017-01-02 21:13:51.000000000 +0100
@@ -13,7 +13,7 @@
the ``PyQt5.QtGui`` module.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
if PYQT5:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtMultimedia.py new/QtPy-1.2.1/qtpy/QtMultimedia.py
--- old/QtPy-1.1.2/qtpy/QtMultimedia.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/QtMultimedia.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,13 @@
+from . import PYQT5
+from . import PYQT4
+from . import PYSIDE
+
+
+if PYQT5:
+ from PyQt5.QtMultimedia import *
+elif PYQT4:
+ from PyQt4.QtMultimedia import *
+ from PyQt4.QtGui import QSound
+elif PYSIDE:
+ from PySide.QtMultimedia import *
+ from PySide.QtGui import QSound
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtNetwork.py new/QtPy-1.2.1/qtpy/QtNetwork.py
--- old/QtPy-1.1.2/qtpy/QtNetwork.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtNetwork.py 2017-01-02 21:13:51.000000000 +0100
@@ -10,7 +10,7 @@
Provides QtNetwork classes and functions.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
if PYQT5:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtPrintSupport.py new/QtPy-1.2.1/qtpy/QtPrintSupport.py
--- old/QtPy-1.1.2/qtpy/QtPrintSupport.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtPrintSupport.py 2017-01-02 21:13:51.000000000 +0100
@@ -9,7 +9,7 @@
Provides QtPrintSupport classes and functions.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
if PYQT5:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtSvg.py new/QtPy-1.2.1/qtpy/QtSvg.py
--- old/QtPy-1.1.2/qtpy/QtSvg.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtSvg.py 2017-01-02 22:17:23.000000000 +0100
@@ -1,15 +1,14 @@
# -*- coding: utf-8 -*-
-#
+# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
+#
# Licensed under the terms of the MIT License
# (see LICENSE.txt for details)
+# -----------------------------------------------------------------------------
+"""Provides QtSvg classes and functions."""
-"""
-Provides QtSvg classes and functions.
-"""
-
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
-
+# Local imports
+from . import PYQT4, PYQT5, PYSIDE, PythonQtError
if PYQT5:
from PyQt5.QtSvg import *
@@ -19,3 +18,5 @@
from PySide.QtSvg import *
else:
raise PythonQtError('No Qt bindings could be found')
+
+del PYQT4, PYQT5, PYSIDE
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtTest.py new/QtPy-1.2.1/qtpy/QtTest.py
--- old/QtPy-1.1.2/qtpy/QtTest.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtTest.py 2017-01-02 21:13:51.000000000 +0100
@@ -10,7 +10,7 @@
Provides QtTest and functions
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
if PYQT5:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtWebEngineWidgets.py new/QtPy-1.2.1/qtpy/QtWebEngineWidgets.py
--- old/QtPy-1.1.2/qtpy/QtWebEngineWidgets.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtWebEngineWidgets.py 2017-01-02 21:13:51.000000000 +0100
@@ -10,7 +10,7 @@
Provides QtWebEngineWidgets classes and functions.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
# To test if we are using WebEngine or WebKit
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/QtWidgets.py new/QtPy-1.2.1/qtpy/QtWidgets.py
--- old/QtPy-1.1.2/qtpy/QtWidgets.py 2016-08-08 23:58:16.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/QtWidgets.py 2017-01-02 23:05:09.000000000 +0100
@@ -13,8 +13,9 @@
were the ``PyQt5.QtWidgets`` module.
"""
-from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError
-from qtpy._patch.qcombobox import patch_qcombobox
+from . import PYQT5, PYQT4, PYSIDE, PythonQtError
+from ._patch.qcombobox import patch_qcombobox
+from ._patch.qheaderview import introduce_renamed_methods_qheaderview
if PYQT5:
@@ -52,7 +53,8 @@
QTextTableCellFormat, QTextTableFormat, QTouchEvent, QTransform,
QValidator, QVector2D, QVector3D, QVector4D, QWhatsThisClickedEvent,
QWheelEvent, QWindowStateChangeEvent, qAlpha, qBlue, qFuzzyCompare,
- qGray, qGreen, qIsGray, qRed, qRgb, qRgba, QIntValidator)
+ qGray, qGreen, qIsGray, qRed, qRgb, qRgba, QIntValidator,
+ QStringListModel)
# These objects belong to QtPrintSupport
del (QAbstractPrintDialog, QPageSetupDialog, QPrintDialog, QPrintEngine,
@@ -65,6 +67,9 @@
# Patch QComboBox to allow Python objects to be passed to userData
patch_qcombobox(QComboBox)
+ # QHeaderView: renamed methods
+ introduce_renamed_methods_qheaderview(QHeaderView)
+
elif PYSIDE:
from PySide.QtGui import *
QStyleOptionViewItem = QStyleOptionViewItemV4
@@ -98,7 +103,7 @@
QTextTableCellFormat, QTextTableFormat, QTouchEvent, QTransform,
QValidator, QVector2D, QVector3D, QVector4D, QWhatsThisClickedEvent,
QWheelEvent, QWindowStateChangeEvent, qAlpha, qBlue, qGray, qGreen,
- qIsGray, qRed, qRgb, qRgba, QIntValidator)
+ qIsGray, qRed, qRgb, qRgba, QIntValidator, QStringListModel)
# These objects belong to QtPrintSupport
del (QAbstractPrintDialog, QPageSetupDialog, QPrintDialog, QPrintEngine,
@@ -111,5 +116,8 @@
# Patch QComboBox to allow Python objects to be passed to userData
patch_qcombobox(QComboBox)
+ # QHeaderView: renamed methods
+ introduce_renamed_methods_qheaderview(QHeaderView)
+
else:
raise PythonQtError('No Qt bindings could be found')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/__init__.py new/QtPy-1.2.1/qtpy/__init__.py
--- old/QtPy-1.1.2/qtpy/__init__.py 2016-07-06 19:30:52.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/__init__.py 2017-01-02 21:13:51.000000000 +0100
@@ -53,7 +53,7 @@
import os
# Version of QtPy
-from qtpy._version import __version__
+from ._version import __version__
#: Qt API environment variable name
QT_API = 'QT_API'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/_patch/qcombobox.py new/QtPy-1.2.1/qtpy/_patch/qcombobox.py
--- old/QtPy-1.1.2/qtpy/_patch/qcombobox.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/_patch/qcombobox.py 2017-01-02 21:13:51.000000000 +0100
@@ -42,8 +42,8 @@
using PyQt4 and PySide to avoid issues.
"""
- from qtpy.QtGui import QIcon
- from qtpy.QtCore import Qt, QObject
+ from ..QtGui import QIcon
+ from ..QtCore import Qt, QObject
class userDataWrapper():
"""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/_patch/qheaderview.py new/QtPy-1.2.1/qtpy/_patch/qheaderview.py
--- old/QtPy-1.1.2/qtpy/_patch/qheaderview.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/_patch/qheaderview.py 2017-01-02 22:36:20.000000000 +0100
@@ -0,0 +1,89 @@
+# -*- coding: utf-8 -*-
+#
+# Copyright © The Spyder Development Team
+#
+# Licensed under the terms of the MIT License
+# (see LICENSE.txt for details)
+
+def introduce_renamed_methods_qheaderview(QHeaderView):
+
+ _isClickable = QHeaderView.isClickable
+ def sectionsClickable(self):
+ """
+ QHeaderView.sectionsClickable() -> bool
+ """
+ return _isClickable(self)
+ QHeaderView.sectionsClickable = sectionsClickable
+ def isClickable(self):
+ raise Exception('isClickable is only available in Qt4. Use '
+ 'sectionsClickable instead.')
+ QHeaderView.isClickable = isClickable
+
+
+ _isMovable = QHeaderView.isMovable
+ def sectionsMovable(self):
+ """
+ QHeaderView.sectionsMovable() -> bool
+ """
+ return _isMovable(self)
+ QHeaderView.sectionsMovable = sectionsMovable
+ def isMovable(self):
+ raise Exception('isMovable is only available in Qt4. Use '
+ 'sectionsMovable instead.')
+ QHeaderView.isMovable = isMovable
+
+
+ _resizeMode = QHeaderView.resizeMode
+ def sectionResizeMode(self, logicalIndex):
+ """
+ QHeaderView.sectionResizeMode(int) -> QHeaderView.ResizeMode
+ """
+ return _resizeMode(self, logicalIndex)
+ QHeaderView.sectionResizeMode = sectionResizeMode
+ def resizeMode(self, logicalIndex):
+ raise Exception('resizeMode is only available in Qt4. Use '
+ 'sectionResizeMode instead.')
+ QHeaderView.resizeMode = resizeMode
+
+ _setClickable = QHeaderView.setClickable
+ def setSectionsClickable(self, clickable):
+ """
+ QHeaderView.setSectionsClickable(bool)
+ """
+ return _setClickable(self, clickable)
+ QHeaderView.setSectionsClickable = setSectionsClickable
+ def setClickable(self, clickable):
+ raise Exception('setClickable is only available in Qt4. Use '
+ 'setSectionsClickable instead.')
+ QHeaderView.setClickable = setClickable
+
+
+ _setMovable = QHeaderView.setMovable
+ def setSectionsMovable(self, movable):
+ """
+ QHeaderView.setSectionsMovable(bool)
+ """
+ return _setMovable(self, movable)
+ QHeaderView.setSectionsMovable = setSectionsMovable
+ def setMovable(self, movable):
+ raise Exception('setMovable is only available in Qt4. Use '
+ 'setSectionsMovable instead.')
+ QHeaderView.setMovable = setMovable
+
+
+ _setResizeMode = QHeaderView.setResizeMode
+ def setSectionResizeMode(self, *args):
+ """
+ QHeaderView.setSectionResizeMode(QHeaderView.ResizeMode)
+ QHeaderView.setSectionResizeMode(int, QHeaderView.ResizeMode)
+ """
+ _setResizeMode(self, *args)
+ QHeaderView.setSectionResizeMode = setSectionResizeMode
+ def setResizeMode(self, *args):
+ raise Exception('setResizeMode is only available in Qt4. Use '
+ 'setSectionResizeMode instead.')
+ QHeaderView.setResizeMode = setResizeMode
+
+
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/_version.py new/QtPy-1.2.1/qtpy/_version.py
--- old/QtPy-1.1.2/qtpy/_version.py 2016-08-09 00:31:12.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/_version.py 2017-01-22 03:09:46.000000000 +0100
@@ -1,2 +1,2 @@
-version_info = (1, 1, 2)
+version_info = (1, 2, 1)
__version__ = '.'.join(map(str, version_info))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/compat.py new/QtPy-1.2.1/qtpy/compat.py
--- old/QtPy-1.1.2/qtpy/compat.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/compat.py 2017-01-02 21:13:51.000000000 +0100
@@ -11,9 +11,9 @@
import sys
import collections
-from qtpy import PYQT4
-from qtpy.QtWidgets import QFileDialog
-from qtpy.py3compat import is_text_string, to_text_string, TEXT_TYPES
+from . import PYQT4
+from .QtWidgets import QFileDialog
+from .py3compat import is_text_string, to_text_string, TEXT_TYPES
# =============================================================================
@@ -105,7 +105,7 @@
options = QFileDialog.Options(0)
try:
# PyQt <v4.6 (API #1)
- from qtpy.QtCore import QString
+ from .QtCore import QString
except ImportError:
# PySide or PyQt >=v4.6
QString = None # analysis:ignore
Binary files old/QtPy-1.1.2/qtpy/tests/__pycache__/conftest.cpython-35.pyc and new/QtPy-1.2.1/qtpy/tests/__pycache__/conftest.cpython-35.pyc differ
Binary files old/QtPy-1.1.2/qtpy/tests/__pycache__/test_main.cpython-35-PYTEST.pyc and new/QtPy-1.2.1/qtpy/tests/__pycache__/test_main.cpython-35-PYTEST.pyc differ
Binary files old/QtPy-1.1.2/qtpy/tests/__pycache__/test_patch_qcombobox.cpython-35-PYTEST.pyc and new/QtPy-1.2.1/qtpy/tests/__pycache__/test_patch_qcombobox.cpython-35-PYTEST.pyc differ
Binary files old/QtPy-1.1.2/qtpy/tests/__pycache__/test_qtmultimedia.cpython-35-PYTEST.pyc and new/QtPy-1.2.1/qtpy/tests/__pycache__/test_qtmultimedia.cpython-35-PYTEST.pyc differ
Binary files old/QtPy-1.1.2/qtpy/tests/__pycache__/test_uic.cpython-35-PYTEST.pyc and new/QtPy-1.2.1/qtpy/tests/__pycache__/test_uic.cpython-35-PYTEST.pyc differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/conftest.py new/QtPy-1.2.1/qtpy/tests/conftest.py
--- old/QtPy-1.1.2/qtpy/tests/conftest.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/conftest.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,59 @@
+import os
+
+
+def pytest_configure(config):
+ """
+ This function gets run by py.test at the very start
+ """
+
+ if 'USE_QT_API' in os.environ:
+ os.environ['QT_API'] = os.environ['USE_QT_API'].lower()
+
+ # We need to import qtpy here to make sure that the API versions get set
+ # straight away.
+ import qtpy
+
+
+def pytest_report_header(config):
+ """
+ This function is used by py.test to insert a customized header into the
+ test report.
+ """
+
+ versions = os.linesep
+ versions += 'PyQt4: '
+
+ try:
+ from PyQt4 import Qt
+ versions += "PyQt: {0} - Qt: {1}".format(Qt.PYQT_VERSION_STR, Qt.QT_VERSION_STR)
+ except ImportError:
+ versions += 'not installed'
+ except AttributeError:
+ versions += 'unknown version'
+
+ versions += os.linesep
+ versions += 'PyQt5: '
+
+ try:
+ from PyQt5 import Qt
+ versions += "PyQt: {0} - Qt: {1}".format(Qt.PYQT_VERSION_STR, Qt.QT_VERSION_STR)
+ except ImportError:
+ versions += 'not installed'
+ except AttributeError:
+ versions += 'unknown version'
+
+ versions += os.linesep
+ versions += 'PySide: '
+
+ try:
+ import PySide
+ from PySide import QtCore
+ versions += "PySide: {0} - Qt: {1}".format(PySide.__version__, QtCore.__version__)
+ except ImportError:
+ versions += 'not installed'
+ except AttributeError:
+ versions += 'unknown version'
+
+ versions += os.linesep
+
+ return versions
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/runtests.py new/QtPy-1.2.1/qtpy/tests/runtests.py
--- old/QtPy-1.1.2/qtpy/tests/runtests.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/runtests.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,26 @@
+#!/usr/bin/env python
+# -*- coding: utf-8 -*-
+# ----------------------------------------------------------------------------
+# Copyright © 2015- The Spyder Development Team
+#
+# Licensed under the terms of the MIT License
+# ----------------------------------------------------------------------------
+
+"""File for running tests programmatically."""
+
+# Standard library imports
+import sys
+
+# Third party imports
+import qtpy # to ensure that Qt4 uses API v2
+import pytest
+
+
+def main():
+ """Run pytest tests."""
+ errno = pytest.main(['-x', 'qtpy', '-v', '-rw', '--durations=10',
+ '--cov=qtpy', '--cov-report=term-missing'])
+ sys.exit(errno)
+
+if __name__ == '__main__':
+ main()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test.ui new/QtPy-1.2.1/qtpy/tests/test.ui
--- old/QtPy-1.1.2/qtpy/tests/test.ui 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test.ui 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>Form</class>
+ <widget class="QWidget" name="Form">
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>300</height>
+ </rect>
+ </property>
+ <property name="windowTitle">
+ <string>Form</string>
+ </property>
+ <layout class="QGridLayout" name="gridLayout_2">
+ <item row="0" column="0">
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QPushButton" name="pushButton">
+ <property name="text">
+ <string>Ceci n'est pas un bouton</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0">
+ <widget class="QComboBox" name="comboBox"/>
+ </item>
+ </layout>
+ </item>
+ </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_custom.ui new/QtPy-1.2.1/qtpy/tests/test_custom.ui
--- old/QtPy-1.1.2/qtpy/tests/test_custom.ui 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_custom.ui 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>Form</class>
+ <widget class="QWidget" name="Form">
+ <property name="geometry">
+ <rect>
+ <x>0</x>
+ <y>0</y>
+ <width>400</width>
+ <height>300</height>
+ </rect>
+ </property>
+ <property name="windowTitle">
+ <string>Form</string>
+ </property>
+ <layout class="QGridLayout" name="gridLayout_2">
+ <item row="0" column="0">
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QPushButton" name="pushButton">
+ <property name="text">
+ <string>Ceci n'est pas un bouton</string>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0">
+ <widget class="_QComboBoxSubclass" name="comboBox"/>
+ </item>
+ </layout>
+ </item>
+ </layout>
+ </widget>
+ <customwidgets>
+ <customwidget>
+ <class>_QComboBoxSubclass</class>
+ <extends>QComboBox</extends>
+ <header>qcombobox_subclass</header>
+ </customwidget>
+ </customwidgets>
+ <resources/>
+ <connections/>
+</ui>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_main.py new/QtPy-1.2.1/qtpy/tests/test_main.py
--- old/QtPy-1.1.2/qtpy/tests/test_main.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_main.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,71 @@
+import os
+
+from qtpy import QtCore, QtGui, QtWidgets, QtWebEngineWidgets
+
+
+def assert_pyside():
+ """
+ Make sure that we are using PySide
+ """
+ import PySide
+ assert QtCore.QEvent is PySide.QtCore.QEvent
+ assert QtGui.QPainter is PySide.QtGui.QPainter
+ assert QtWidgets.QWidget is PySide.QtGui.QWidget
+ assert QtWebEngineWidgets.QWebEnginePage is PySide.QtWebKit.QWebPage
+
+
+def assert_pyqt4():
+ """
+ Make sure that we are using PyQt4
+ """
+ import PyQt4
+ assert QtCore.QEvent is PyQt4.QtCore.QEvent
+ assert QtGui.QPainter is PyQt4.QtGui.QPainter
+ assert QtWidgets.QWidget is PyQt4.QtGui.QWidget
+ assert QtWebEngineWidgets.QWebEnginePage is PyQt4.QtWebKit.QWebPage
+
+
+def assert_pyqt5():
+ """
+ Make sure that we are using PyQt5
+ """
+ import PyQt5
+ assert QtCore.QEvent is PyQt5.QtCore.QEvent
+ assert QtGui.QPainter is PyQt5.QtGui.QPainter
+ assert QtWidgets.QWidget is PyQt5.QtWidgets.QWidget
+ if QtWebEngineWidgets.WEBENGINE:
+ assert QtWebEngineWidgets.QWebEnginePage is PyQt5.QtWebEngineWidgets.QWebEnginePage
+ else:
+ assert QtWebEngineWidgets.QWebEnginePage is PyQt5.QtWebKitWidgets.QWebPage
+
+
+def test_qt_api():
+ """
+ If QT_API is specified, we check that the correct Qt wrapper was used
+ """
+
+ QT_API = os.environ.get('QT_API', '').lower()
+
+ if QT_API == 'pyside':
+ assert_pyside()
+ elif QT_API in ('pyqt', 'pyqt4'):
+ assert_pyqt4()
+ elif QT_API == 'pyqt5':
+ assert_pyqt5()
+ else:
+ # If the tests are run locally, USE_QT_API and QT_API may not be
+ # defined, but we still want to make sure qtpy is behaving sensibly.
+ # We should then be loading, in order of decreasing preference, PyQt5,
+ # PyQt4, and PySide.
+ try:
+ import PyQt5
+ except ImportError:
+ try:
+ import PyQt4
+ except ImportError:
+ import PySide
+ assert_pyside()
+ else:
+ assert_pyqt4()
+ else:
+ assert_pyqt5()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_patch_qcombobox.py new/QtPy-1.2.1/qtpy/tests/test_patch_qcombobox.py
--- old/QtPy-1.1.2/qtpy/tests/test_patch_qcombobox.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_patch_qcombobox.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,95 @@
+from __future__ import absolute_import
+
+from qtpy import QtGui, QtWidgets
+
+
+def get_qapp(icon_path=None):
+ qapp = QtWidgets.QApplication.instance()
+ if qapp is None:
+ qapp = QtWidgets.QApplication([''])
+ return qapp
+
+
+class Data(object):
+ """
+ Test class to store in userData. The __getitem__ is needed in order to
+ reproduce the segmentation fault.
+ """
+ def __getitem__(self, item):
+ raise ValueError("Failing")
+
+
+def test_patched_qcombobox():
+ """
+ In PySide, using Python objects as userData in QComboBox causes
+ Segmentation faults under certain conditions. Even in cases where it
+ doesn't, findData does not work correctly. Likewise, findData also
+ does not work correctly with Python objects when using PyQt4. On the
+ other hand, PyQt5 deals with this case correctly. We therefore patch
+ QComboBox when using PyQt4 and PySide to avoid issues.
+ """
+
+ app = get_qapp()
+
+ data1 = Data()
+ data2 = Data()
+ data3 = Data()
+ data4 = Data()
+ data5 = Data()
+ data6 = Data()
+
+ icon1 = QtGui.QIcon()
+ icon2 = QtGui.QIcon()
+
+ widget = QtWidgets.QComboBox()
+ widget.addItem('a', data1)
+ widget.insertItem(0, 'b', data2)
+ widget.addItem('c', data1)
+ widget.setItemData(2, data3)
+ widget.addItem(icon1, 'd', data4)
+ widget.insertItem(3, icon2, 'e', data5)
+ widget.addItem(icon1, 'f')
+ widget.insertItem(5, icon2, 'g')
+
+ widget.show()
+
+ assert widget.findData(data1) == 1
+ assert widget.findData(data2) == 0
+ assert widget.findData(data3) == 2
+ assert widget.findData(data4) == 4
+ assert widget.findData(data5) == 3
+ assert widget.findData(data6) == -1
+
+ assert widget.itemData(0) == data2
+ assert widget.itemData(1) == data1
+ assert widget.itemData(2) == data3
+ assert widget.itemData(3) == data5
+ assert widget.itemData(4) == data4
+ assert widget.itemData(5) is None
+ assert widget.itemData(6) is None
+
+ assert widget.itemText(0) == 'b'
+ assert widget.itemText(1) == 'a'
+ assert widget.itemText(2) == 'c'
+ assert widget.itemText(3) == 'e'
+ assert widget.itemText(4) == 'd'
+ assert widget.itemText(5) == 'g'
+ assert widget.itemText(6) == 'f'
+
+
+def test_model_item():
+ """
+ This is a regression test for an issue that caused the call to item(0)
+ below to trigger segmentation faults in PySide. The issue is
+ non-deterministic when running the call once, so we include a loop to make
+ sure that we trigger the fault.
+ """
+ app = get_qapp()
+ combo = QtWidgets.QComboBox()
+ label_data = [('a', None)]
+ for iter in range(10000):
+ combo.clear()
+ for i, (label, data) in enumerate(label_data):
+ combo.addItem(label, userData=data)
+ model = combo.model()
+ model.item(0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_patch_qheaderview.py new/QtPy-1.2.1/qtpy/tests/test_patch_qheaderview.py
--- old/QtPy-1.1.2/qtpy/tests/test_patch_qheaderview.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_patch_qheaderview.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,91 @@
+from __future__ import absolute_import
+
+from qtpy import PYSIDE, PYQT4
+from qtpy.QtWidgets import QApplication
+from qtpy.QtWidgets import QHeaderView
+from qtpy.QtCore import Qt
+from qtpy.QtCore import QAbstractListModel
+
+import pytest
+
+def get_qapp(icon_path=None):
+ qapp = QApplication.instance()
+ if qapp is None:
+ qapp = QApplication([''])
+ return qapp
+
+def test_patched_qheaderview():
+ """
+ This will test whether QHeaderView has the new methods introduced in Qt5.
+ It will then create an instance of QHeaderView and test that no exceptions
+ are raised and that some basic behaviour works.
+ """
+ assert QHeaderView.sectionsClickable is not None
+ assert QHeaderView.sectionsMovable is not None
+ assert QHeaderView.sectionResizeMode is not None
+ assert QHeaderView.setSectionsClickable is not None
+ assert QHeaderView.setSectionsMovable is not None
+ assert QHeaderView.setSectionResizeMode is not None
+
+ # setup a model and add it to a headerview
+ qapp = get_qapp()
+ headerview = QHeaderView(Qt.Horizontal)
+ class Model(QAbstractListModel):
+ pass
+ model = Model()
+ headerview.setModel(model)
+ assert headerview.count() == 1
+
+ # test it
+ assert isinstance(headerview.sectionsClickable(), bool)
+ assert isinstance(headerview.sectionsMovable(), bool)
+ if PYSIDE:
+ assert isinstance(headerview.sectionResizeMode(0),
+ QHeaderView.ResizeMode)
+ else:
+ assert isinstance(headerview.sectionResizeMode(0), int)
+
+ headerview.setSectionsClickable(True)
+ assert headerview.sectionsClickable() == True
+ headerview.setSectionsClickable(False)
+ assert headerview.sectionsClickable() == False
+
+ headerview.setSectionsMovable(True)
+ assert headerview.sectionsMovable() == True
+ headerview.setSectionsMovable(False)
+ assert headerview.sectionsMovable() == False
+
+ headerview.setSectionResizeMode(QHeaderView.Interactive)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Interactive
+ headerview.setSectionResizeMode(QHeaderView.Fixed)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Fixed
+ headerview.setSectionResizeMode(QHeaderView.Stretch)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Stretch
+ headerview.setSectionResizeMode(QHeaderView.ResizeToContents)
+ assert headerview.sectionResizeMode(0) == QHeaderView.ResizeToContents
+
+ headerview.setSectionResizeMode(0, QHeaderView.Interactive)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Interactive
+ headerview.setSectionResizeMode(0, QHeaderView.Fixed)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Fixed
+ headerview.setSectionResizeMode(0, QHeaderView.Stretch)
+ assert headerview.sectionResizeMode(0) == QHeaderView.Stretch
+ headerview.setSectionResizeMode(0, QHeaderView.ResizeToContents)
+ assert headerview.sectionResizeMode(0) == QHeaderView.ResizeToContents
+
+ # test that the old methods in Qt4 raise exceptions
+ if PYQT4 or PYSIDE:
+ with pytest.raises(Exception):
+ headerview.isClickable()
+ with pytest.raises(Exception):
+ headerview.isMovable()
+ with pytest.raises(Exception):
+ headerview.resizeMode(0)
+ with pytest.raises(Exception):
+ headerview.setClickable(True)
+ with pytest.raises(Exception):
+ headerview.setMovableClickable(True)
+ with pytest.raises(Exception):
+ headerview.setResizeMode(0, QHeaderView.Interactive)
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_qtmultimedia.py new/QtPy-1.2.1/qtpy/tests/test_qtmultimedia.py
--- old/QtPy-1.1.2/qtpy/tests/test_qtmultimedia.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_qtmultimedia.py 2017-01-02 21:13:51.000000000 +0100
@@ -0,0 +1,12 @@
+from __future__ import absolute_import
+
+from qtpy import QtMultimedia
+
+
+def test_qtmultimedia():
+ """Test the qtpy.QtMultimedia namespace"""
+ assert QtMultimedia.QAbstractVideoBuffer is not None
+ assert QtMultimedia.QAudio is not None
+ assert QtMultimedia.QAudioDeviceInfo is not None
+ assert QtMultimedia.QAudioInput is not None
+ assert QtMultimedia.QSound is not None
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/tests/test_uic.py new/QtPy-1.2.1/qtpy/tests/test_uic.py
--- old/QtPy-1.1.2/qtpy/tests/test_uic.py 1970-01-01 01:00:00.000000000 +0100
+++ new/QtPy-1.2.1/qtpy/tests/test_uic.py 2017-01-06 03:16:17.000000000 +0100
@@ -0,0 +1,81 @@
+import os
+import sys
+import contextlib
+
+from qtpy import QtWidgets
+from qtpy.QtWidgets import QComboBox
+from qtpy import uic
+from qtpy.uic import loadUi
+
+
+QCOMBOBOX_SUBCLASS = """
+from qtpy.QtWidgets import QComboBox
+class _QComboBoxSubclass(QComboBox):
+ pass
+"""
+
+(a)contextlib.contextmanager
+def enabled_qcombobox_subclass(tmpdir):
+ """
+ Context manager that sets up a temporary module with a QComboBox subclass
+ and then removes it once we are done.
+ """
+
+ with open(tmpdir.join('qcombobox_subclass.py').strpath, 'w') as f:
+ f.write(QCOMBOBOX_SUBCLASS)
+
+ sys.path.insert(0, tmpdir.strpath)
+
+ yield
+
+ sys.path.pop(0)
+
+
+def get_qapp(icon_path=None):
+ """
+ Helper function to return a QApplication instance
+ """
+ qapp = QtWidgets.QApplication.instance()
+ if qapp is None:
+ qapp = QtWidgets.QApplication([''])
+ return qapp
+
+
+def test_load_ui():
+ """
+ Make sure that the patched loadUi function behaves as expected with a
+ simple .ui file.
+ """
+ app = get_qapp()
+ ui = loadUi(os.path.join(os.path.dirname(__file__), 'test.ui'))
+ assert isinstance(ui.pushButton, QtWidgets.QPushButton)
+ assert isinstance(ui.comboBox, QComboBox)
+
+
+def test_load_ui_custom_auto(tmpdir):
+ """
+ Test that we can load a .ui file with custom widgets without having to
+ explicitly specify a dictionary of custom widgets, even in the case of
+ PySide.
+ """
+
+ app = get_qapp()
+
+ with enabled_qcombobox_subclass(tmpdir):
+ from qcombobox_subclass import _QComboBoxSubclass
+ ui = loadUi(os.path.join(os.path.dirname(__file__), 'test_custom.ui'))
+
+ assert isinstance(ui.pushButton, QtWidgets.QPushButton)
+ assert isinstance(ui.comboBox, _QComboBoxSubclass)
+
+
+def test_load_full_uic():
+ """Test that we load the full uic objects for PyQt5 and PyQt4."""
+ QT_API = os.environ.get('QT_API', '').lower()
+ if QT_API == 'pyside':
+ assert hasattr(uic, 'loadUi')
+ assert not hasattr(uic, 'loadUiType')
+ else:
+ objects = ['compileUi', 'compileUiDir', 'loadUi', 'loadUiType',
+ 'widgetPluginPath']
+ assert all([hasattr(uic, o) for o in objects])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/QtPy-1.1.2/qtpy/uic.py new/QtPy-1.2.1/qtpy/uic.py
--- old/QtPy-1.1.2/qtpy/uic.py 2016-06-30 17:09:13.000000000 +0200
+++ new/QtPy-1.2.1/qtpy/uic.py 2017-01-06 03:16:17.000000000 +0100
@@ -1,20 +1,21 @@
import os
-from qtpy import PYSIDE, PYQT4, PYQT5
-from qtpy.QtWidgets import QComboBox
+from . import PYSIDE, PYQT4, PYQT5
+from .QtWidgets import QComboBox
-__all__ = ['loadUi']
if PYQT5:
- from PyQt5.uic import loadUi
+ from PyQt5.uic import *
elif PYQT4:
- from PyQt4.uic import loadUi
+ from PyQt4.uic import *
elif PYSIDE:
+ __all__ = ['loadUi']
+
# In PySide, loadUi does not exist, so we define it using QUiLoader, and
# then make sure we expose that function. This is adapted from qt-helpers
# which was released under a 3-clause BSD license:
1
0
Hello community,
here is the log from the commit of package ghc-yaml for openSUSE:Factory checked in at 2017-02-22 13:54:02
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-yaml (Old)
and /work/SRC/openSUSE:Factory/.ghc-yaml.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-yaml"
Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-yaml/ghc-yaml.changes 2017-01-12 15:53:12.433777668 +0100
+++ /work/SRC/openSUSE:Factory/.ghc-yaml.new/ghc-yaml.changes 2017-02-22 13:54:03.335868047 +0100
@@ -1,0 +2,5 @@
+Mon Jan 30 09:29:22 UTC 2017 - psimons(a)suse.com
+
+- Update to version 0.8.21.2 with cabal2obs.
+
+-------------------------------------------------------------------
Old:
----
yaml-0.8.21.1.tar.gz
New:
----
yaml-0.8.21.2.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ ghc-yaml.spec ++++++
--- /var/tmp/diff_new_pack.C4OvGf/_old 2017-02-22 13:54:04.071763335 +0100
+++ /var/tmp/diff_new_pack.C4OvGf/_new 2017-02-22 13:54:04.075762766 +0100
@@ -1,7 +1,7 @@
#
# spec file for package ghc-yaml
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -19,7 +19,7 @@
%global pkg_name yaml
%bcond_with tests
Name: ghc-%{pkg_name}
-Version: 0.8.21.1
+Version: 0.8.21.2
Release: 0
Summary: Support for parsing and rendering YAML documents
License: BSD-3-Clause
++++++ yaml-0.8.21.1.tar.gz -> yaml-0.8.21.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yaml-0.8.21.1/ChangeLog.md new/yaml-0.8.21.2/ChangeLog.md
--- old/yaml-0.8.21.1/ChangeLog.md 2016-11-29 10:43:02.000000000 +0100
+++ new/yaml-0.8.21.2/ChangeLog.md 2017-01-25 12:17:27.000000000 +0100
@@ -1,3 +1,7 @@
+## 0.8.21.2
+
+* Fix wrong file not found exception in `Data.Yaml.Include` with pre-1.2.3.0 `directory` [#104](https://github.com/snoyberg/yaml/pull/104)
+
## 0.8.21.1
* Add missing test files [#102](https://github.com/snoyberg/yaml/pull/102)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yaml-0.8.21.1/Data/Yaml/Include.hs new/yaml-0.8.21.2/Data/Yaml/Include.hs
--- old/yaml-0.8.21.1/Data/Yaml/Include.hs 2016-11-29 10:43:02.000000000 +0100
+++ new/yaml-0.8.21.2/Data/Yaml/Include.hs 2017-01-25 12:17:27.000000000 +0100
@@ -1,6 +1,13 @@
+{-# LANGUAGE CPP #-}
{-# LANGUAGE RankNTypes #-}
module Data.Yaml.Include (decodeFile, decodeFileEither) where
+#if !MIN_VERSION_directory(1, 2, 3)
+import Control.Exception (handleJust)
+import Control.Monad (guard)
+import System.IO.Error (ioeGetFileName, ioeGetLocation, isDoesNotExistError)
+#endif
+
import Control.Exception (throwIO)
import Control.Monad (when)
import Control.Monad.IO.Class (liftIO)
@@ -25,7 +32,7 @@
where
go :: MonadResource m => [FilePath] -> FilePath -> Producer m Event
go seen fp = do
- cfp <- liftIO $ canonicalizePath fp
+ cfp <- liftIO $ handleNotFound $ canonicalizePath fp
when (cfp `elem` seen) $ do
liftIO $ throwIO CyclicIncludes
Y.decodeFile cfp $= do
@@ -37,6 +44,17 @@
irrelevantEvents = [EventStreamStart, EventDocumentStart, EventDocumentEnd, EventStreamEnd]
+#if !MIN_VERSION_directory(1, 2, 3)
+ handleNotFound = handleJust
+ (\e -> do
+ guard (isDoesNotExistError e)
+ guard (ioeGetLocation e == "canonicalizePath")
+ ioeGetFileName e)
+ (throwIO . YamlException . ("Yaml file not found: " ++))
+#else
+ handleNotFound = id
+#endif
+
-- | Like `Data.Yaml.decodeFile` but with support for relative and absolute
-- includes.
--
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yaml-0.8.21.1/test/Data/Yaml/IncludeSpec.hs new/yaml-0.8.21.2/test/Data/Yaml/IncludeSpec.hs
--- old/yaml-0.8.21.1/test/Data/Yaml/IncludeSpec.hs 2016-11-29 10:43:02.000000000 +0100
+++ new/yaml-0.8.21.2/test/Data/Yaml/IncludeSpec.hs 2017-01-25 12:17:27.000000000 +0100
@@ -2,12 +2,12 @@
module Data.Yaml.IncludeSpec (main, spec) where
import Test.Hspec
-import Data.Either.Compat
+import Data.List (isPrefixOf)
import Data.Aeson
import Data.Aeson.QQ
-import Data.Yaml (ParseException)
-
+import Data.Yaml (ParseException(InvalidYaml))
import Data.Yaml.Include
+import Text.Libyaml (YamlException(YamlException))
main :: IO ()
main = hspec spec
@@ -38,7 +38,17 @@
it "aborts on cyclic includes" $ do
(decodeFile "test/resources/loop/foo.yaml" :: IO (Maybe Value)) `shouldThrow` anyException
+ context "when file does not exist" $ do
+ it "throws Left (InvalidYaml (Just (YamlException \"Yaml file not found: ...\")))" $ do
+ (decodeFile "./does_not_exist.yaml" :: IO (Maybe Value)) `shouldThrow` isYamlFileNotFoundException
+
describe "decodeFileEither" $ do
context "when file does not exist" $ do
- it "returns Left" $ do
- (decodeFileEither "./does_not_exist.yaml" :: IO (Either ParseException Value)) >>= (`shouldSatisfy` isLeft)
+ it "returns Left (InvalidYaml (Just (YamlException \"Yaml file not found: ...\")))" $ do
+ (decodeFileEither "./does_not_exist.yaml" :: IO (Either ParseException Value)) >>=
+ (`shouldSatisfy` either isYamlFileNotFoundException (const False))
+
+isYamlFileNotFoundException :: ParseException -> Bool
+isYamlFileNotFoundException (InvalidYaml (Just (YamlException msg)))
+ | "Yaml file not found: " `isPrefixOf` msg = True
+isYamlFileNotFoundException _ = False
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yaml-0.8.21.1/yaml.cabal new/yaml-0.8.21.2/yaml.cabal
--- old/yaml-0.8.21.1/yaml.cabal 2016-11-29 10:43:02.000000000 +0100
+++ new/yaml-0.8.21.2/yaml.cabal 2017-01-25 12:17:27.000000000 +0100
@@ -1,5 +1,5 @@
name: yaml
-version: 0.8.21.1
+version: 0.8.21.2
license: BSD3
license-file: LICENSE
author: Michael Snoyman <michael(a)snoyman.com>, Anton Ageev <antage(a)gmail.com>,Kirill Simonov
1
0
Hello community,
here is the log from the commit of package ghc-wl-pprint-text for openSUSE:Factory checked in at 2017-02-22 13:53:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-wl-pprint-text (Old)
and /work/SRC/openSUSE:Factory/.ghc-wl-pprint-text.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-wl-pprint-text"
Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-wl-pprint-text/ghc-wl-pprint-text.changes 2016-07-21 08:13:16.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.ghc-wl-pprint-text.new/ghc-wl-pprint-text.changes 2017-02-22 13:53:58.204598192 +0100
@@ -1,0 +2,5 @@
+Mon Jan 30 09:26:24 UTC 2017 - psimons(a)suse.com
+
+- Update to version 1.1.1.0 with cabal2obs.
+
+-------------------------------------------------------------------
Old:
----
wl-pprint-text-1.1.0.4.tar.gz
New:
----
wl-pprint-text-1.1.1.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ ghc-wl-pprint-text.spec ++++++
--- /var/tmp/diff_new_pack.3b7Dtm/_old 2017-02-22 13:53:58.804512827 +0100
+++ /var/tmp/diff_new_pack.3b7Dtm/_new 2017-02-22 13:53:58.804512827 +0100
@@ -1,7 +1,7 @@
#
# spec file for package ghc-wl-pprint-text
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -18,19 +18,18 @@
%global pkg_name wl-pprint-text
Name: ghc-%{pkg_name}
-Version: 1.1.0.4
+Version: 1.1.1.0
Release: 0
Summary: A Wadler/Leijen Pretty Printer for Text values
License: BSD-3-Clause
-Group: System/Libraries
+Group: Development/Languages/Other
Url: https://hackage.haskell.org/package/%{pkg_name}
Source0: https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{ve…
BuildRequires: ghc-Cabal-devel
+BuildRequires: ghc-base-compat-devel
BuildRequires: ghc-rpm-macros
-# Begin cabal-rpm deps:
BuildRequires: ghc-text-devel
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-# End cabal-rpm deps
%description
A clone of wl-pprint for use with the text library.
@@ -49,15 +48,12 @@
%prep
%setup -q -n %{pkg_name}-%{version}
-
%build
%ghc_lib_build
-
%install
%ghc_lib_install
-
%post devel
%ghc_pkg_recache
@@ -70,5 +66,6 @@
%files devel -f %{name}-devel.files
%defattr(-,root,root,-)
+%doc Changelog.md README.md
%changelog
++++++ wl-pprint-text-1.1.0.4.tar.gz -> wl-pprint-text-1.1.1.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wl-pprint-text-1.1.0.4/Changelog.md new/wl-pprint-text-1.1.1.0/Changelog.md
--- old/wl-pprint-text-1.1.0.4/Changelog.md 1970-01-01 01:00:00.000000000 +0100
+++ new/wl-pprint-text-1.1.1.0/Changelog.md 2017-01-26 12:56:06.000000000 +0100
@@ -0,0 +1,59 @@
+1.1.1.0 (2017-01-26)
+====================
+
+* Support strict `Text` values (thanks to Elliot Cameron).
+
+* Loosened constraints from `Monad` to `Functor` where applicable
+ (thanks to Elliot Cameron).
+
+* Uses `base-compat` to make it easier to support multiple GHC
+ versions.
+
+* Add `isEmpty :: Doc -> Bool`.
+
+* Support `Semigroup` in `base >= 4.9.0.0`.
+
+1.1.0.4 (2015-04-06)
+====================
+
+* Support `GHC-7.10`.
+
+1.1.0.3 (2014-12-24)
+====================
+
+* Support `text-1.2.*`.
+
+1.1.0.2 (2014-01-16)
+====================
+
+* Support `text-1.1.0.0`.
+
+1.1.0.1 (2013-12-23)
+====================
+
+_This probably should have been 1.1.1.0._
+
+* Documentation fixes.
+
+* Add `displayB`, `spacebreak` and `<++>`.
+
+* Smarter treatment of spaces, newlines, etc. (including how `line`
+ behaves in `renderOneLine`).
+
+1.1.0.0 (2012-08-22)
+====================
+
+* `Doc` is now an instance of `Monoid`.
+
+* Add `renderOneLine` function.
+
+* Add `IsString` instances.
+
+* Make `SimpleDoc` an instance of `Show` for convenience.
+
+* Make the `Show` instance for `Doc` match the documentation.
+
+1.0.0.0 (2012-05-22)
+====================
+
+* Initial version,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wl-pprint-text-1.1.0.4/README.md new/wl-pprint-text-1.1.1.0/README.md
--- old/wl-pprint-text-1.1.0.4/README.md 1970-01-01 01:00:00.000000000 +0100
+++ new/wl-pprint-text-1.1.1.0/README.md 2017-01-26 12:56:06.000000000 +0100
@@ -0,0 +1,8 @@
+wl-pprint-text
+==============
+
+[![Hackage](https://img.shields.io/hackage/v/wl-pprint-text.svg)](https://hackage.haskell.org/package/wl-pprint-text) [![Build Status](https://travis-ci.org/ivan-m/wl-pprint-text.svg)](https://travis-ci…
+
+A clone of [wl-pprint](http://hackage.haskell.org/package/wl-pprint)
+for use with the [text](http://hackage.haskell.org/package/text)
+library (with some improved handling of whitespace).
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wl-pprint-text-1.1.0.4/Text/PrettyPrint/Leijen/Text/Monadic.hs new/wl-pprint-text-1.1.1.0/Text/PrettyPrint/Leijen/Text/Monadic.hs
--- old/wl-pprint-text-1.1.0.4/Text/PrettyPrint/Leijen/Text/Monadic.hs 2015-04-06 14:24:45.000000000 +0200
+++ new/wl-pprint-text-1.1.1.0/Text/PrettyPrint/Leijen/Text/Monadic.hs 2017-01-26 12:56:06.000000000 +0100
@@ -21,7 +21,7 @@
Doc, -- putDoc, hPutDoc,
-- * Basic combinators
- empty, char, text, (<>), nest, line, linebreak, group, softline,
+ empty, char, text, textStrict, (<>), nest, line, linebreak, group, softline,
softbreak, spacebreak,
-- * Alignment
@@ -55,7 +55,7 @@
squote, dquote, semi, colon, comma, space, dot, backslash, equals,
-- * Primitive type documents
- string, int, integer, float, double, rational, bool,
+ string, stringStrict, int, integer, float, double, rational, bool,
-- * Position-based combinators
column, nesting, width,
@@ -65,28 +65,29 @@
-- * Rendering
SimpleDoc(..), renderPretty, renderCompact, renderOneLine,
- displayB, displayT, displayIO, putDoc, hPutDoc
+ displayB, displayT, displayTStrict, displayIO, putDoc, hPutDoc
) where
-#if defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ >= 710
-import Prelude hiding ((<$>))
-#endif
+import Prelude ()
+import Prelude.Compat hiding ((<$>))
+
import Text.PrettyPrint.Leijen.Text (Doc, Pretty (..), SimpleDoc (..),
- displayB, displayIO, displayT,
+ displayB, displayIO, displayT, displayTStrict,
hPutDoc, putDoc, renderCompact,
renderOneLine, renderPretty)
import qualified Text.PrettyPrint.Leijen.Text as PP
-import Control.Monad (liftM, liftM2, liftM3, liftM4)
+import Control.Applicative (liftA2, liftA3)
import Data.String (IsString (..))
+import qualified Data.Text as TS
import Data.Text.Lazy (Text)
infixr 5 </>,<//>,<$>,<$$>
infixr 6 <>,<+>,<++>
-instance Monad m => IsString (m Doc) where
+instance (Applicative m) => IsString (m Doc) where
fromString = string . fromString
-----------------------------------------------------------
@@ -96,24 +97,24 @@
-- horizontally if that fits the page. Otherwise they are aligned
-- vertically. All comma separators are put in front of the
-- elements.
-list :: (Monad m) => m [Doc] -> m Doc
-list = liftM PP.list
+list :: (Functor m) => m [Doc] -> m Doc
+list = fmap PP.list
-- | The document @(tupled xs)@ comma separates the documents @xs@ and
-- encloses them in parenthesis. The documents are rendered
-- horizontally if that fits the page. Otherwise they are aligned
-- vertically. All comma separators are put in front of the
-- elements.
-tupled :: (Monad m) => m [Doc] -> m Doc
-tupled = liftM PP.tupled
+tupled :: (Functor m) => m [Doc] -> m Doc
+tupled = fmap PP.tupled
-- | The document @(semiBraces xs)@ separates the documents @xs@ with
-- semi colons and encloses them in braces. The documents are
-- rendered horizontally if that fits the page. Otherwise they are
-- aligned vertically. All semi colons are put in front of the
-- elements.
-semiBraces :: (Monad m) => m [Doc] -> m Doc
-semiBraces = liftM PP.semiBraces
+semiBraces :: (Functor m) => m [Doc] -> m Doc
+semiBraces = fmap PP.semiBraces
-- | The document @(encloseSep l r sep xs)@ concatenates the documents
-- @xs@ separated by @sep@ and encloses the resulting document by
@@ -138,8 +139,8 @@
-- ,200
-- ,3000]
-- @
-encloseSep :: (Monad m) => m Doc -> m Doc -> m Doc -> m [Doc] -> m Doc
-encloseSep = liftM4 PP.encloseSep
+encloseSep :: (Applicative m) => m Doc -> m Doc -> m Doc -> m [Doc] -> m Doc
+encloseSep a b c d = liftA3 PP.encloseSep a b c <*> d
-- | @(punctuate p xs)@ concatenates all documents in @xs@ with
-- document @p@ except for the last document.
@@ -164,16 +165,16 @@
--
-- (If you want put the commas in front of their elements instead of
-- at the end, you should use 'tupled' or, in general, 'encloseSep'.)
-punctuate :: (Monad m) => m Doc -> m [Doc] -> m [Doc]
-punctuate = liftM2 PP.punctuate
+punctuate :: (Applicative m) => m Doc -> m [Doc] -> m [Doc]
+punctuate = liftA2 PP.punctuate
-- | The document @(sep xs)@ concatenates all documents @xs@ either
-- horizontally with @(\<+\>)@, if it fits the page, or vertically
-- with @(\<$\>)@.
--
-- > sep xs = group (vsep xs)
-sep :: (Monad m) => m [Doc] -> m Doc
-sep = liftM PP.sep
+sep :: (Functor m) => m [Doc] -> m Doc
+sep = fmap PP.sep
-- | The document @(fillSep xs)@ concatenates documents @xs@
-- horizontally with @(\<+\>)@ as long as its fits the page, then
@@ -181,13 +182,13 @@
-- @xs@.
--
-- > fillSep xs = foldr (</>) empty xs
-fillSep :: (Monad m) => m [Doc] -> m Doc
-fillSep = liftM PP.fillSep
+fillSep :: (Functor m) => m [Doc] -> m Doc
+fillSep = fmap PP.fillSep
-- | The document @(hsep xs)@ concatenates all documents @xs@
-- horizontally with @(\<+\>)@.
-hsep :: (Monad m) => m [Doc] -> m Doc
-hsep = liftM PP.hsep
+hsep :: (Functor m) => m [Doc] -> m Doc
+hsep = fmap PP.hsep
-- | The document @(vsep xs)@ concatenates all documents @xs@
-- vertically with @(\<$\>)@. If a 'group' undoes the line breaks
@@ -219,16 +220,16 @@
-- lay
-- out
-- @
-vsep :: (Monad m) => m [Doc] -> m Doc
-vsep = liftM PP.vsep
+vsep :: (Functor m) => m [Doc] -> m Doc
+vsep = fmap PP.vsep
-- | The document @(cat xs)@ concatenates all documents @xs@ either
-- horizontally with @(\<\>)@, if it fits the page, or vertically
-- with @(\<$$\>)@.
--
-- > cat xs = group (vcat xs)
-cat :: (Monad m) => m [Doc] -> m Doc
-cat = liftM PP.cat
+cat :: (Functor m) => m [Doc] -> m Doc
+cat = fmap PP.cat
-- | The document @(fillCat xs)@ concatenates documents @xs@
-- horizontally with @(\<\>)@ as long as its fits the page, then
@@ -236,181 +237,181 @@
-- in @xs@.
--
-- > fillCat xs = foldr (<//>) empty xs
-fillCat :: (Monad m) => m [Doc] -> m Doc
-fillCat = liftM PP.fillCat
+fillCat :: (Functor m) => m [Doc] -> m Doc
+fillCat = fmap PP.fillCat
-- | The document @(hcat xs)@ concatenates all documents @xs@
-- horizontally with @(\<\>)@.
-hcat :: (Monad m) => m [Doc] -> m Doc
-hcat = liftM PP.hcat
+hcat :: (Functor m) => m [Doc] -> m Doc
+hcat = fmap PP.hcat
-- | The document @(vcat xs)@ concatenates all documents @xs@
-- vertically with @(\<$$\>)@. If a 'group' undoes the line breaks
-- inserted by @vcat@, all documents are directly concatenated.
-vcat :: (Monad m) => m [Doc] -> m Doc
-vcat = liftM PP.vcat
+vcat :: (Functor m) => m [Doc] -> m Doc
+vcat = fmap PP.vcat
-- | The document @(x \<\> y)@ concatenates document @x@ and document
-- @y@. It is an associative operation having 'empty' as a left and
-- right unit. (infixr 6)
-(<>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<>) = liftM2 (PP.<>)
+(<>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<>) = liftA2 (PP.<>)
-- | The document @(x \<+\> y)@ concatenates document @x@ and @y@ with
-- a 'space' in between. (infixr 6)
-(<+>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<+>) = liftM2 (PP.<+>)
+(<+>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<+>) = liftA2 (PP.<+>)
-- | The document @(x \<++\> y)@ concatenates document @x@ and @y@ with
-- a 'spacebreak' in between. (infixr 6)
-(<++>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<++>) = liftM2 (PP.<++>)
+(<++>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<++>) = liftA2 (PP.<++>)
-- | The document @(x \<\/\> y)@ concatenates document @x@ and @y@
-- with a 'softline' in between. This effectively puts @x@ and @y@
-- either next to each other (with a @space@ in between) or
-- underneath each other. (infixr 5)
-(</>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(</>) = liftM2 (PP.</>)
+(</>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(</>) = liftA2 (PP.</>)
-- | The document @(x \<\/\/\> y)@ concatenates document @x@ and @y@
-- with a 'softbreak' in between. This effectively puts @x@ and @y@
-- either right next to each other or underneath each other. (infixr
-- 5)
-(<//>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<//>) = liftM2 (PP.<//>)
+(<//>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<//>) = liftA2 (PP.<//>)
-- | The document @(x \<$\> y)@ concatenates document @x@ and @y@ with
-- a 'line' in between. (infixr 5)
-(<$>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<$>) = liftM2 (PP.<$>)
+(<$>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<$>) = liftA2 (PP.<$>)
-- | The document @(x \<$$\> y)@ concatenates document @x@ and @y@
-- with a 'linebreak' in between. (infixr 5)
-(<$$>) :: (Monad m) => m Doc -> m Doc -> m Doc
-(<$$>) = liftM2 (PP.<$$>)
+(<$$>) :: (Applicative m) => m Doc -> m Doc -> m Doc
+(<$$>) = liftA2 (PP.<$$>)
-- | The document @softline@ behaves like 'space' if the resulting
-- output fits the page, otherwise it behaves like 'line'.
-softline :: (Monad m) => m Doc
-softline = return PP.softline
+softline :: (Applicative m) => m Doc
+softline = pure PP.softline
-- | The document @softbreak@ behaves like 'empty' if the resulting
-- output fits the page, otherwise it behaves like 'line'.
-softbreak :: (Monad m) => m Doc
-softbreak = return PP.softbreak
+softbreak :: (Applicative m) => m Doc
+softbreak = pure PP.softbreak
-- | The document @spacebreak@ behaves like 'space' when rendered normally
-- but like 'empty' when using 'renderCompact' or 'renderOneLine'.
-spacebreak :: (Monad m) => m Doc
-spacebreak = return PP.spacebreak
+spacebreak :: (Applicative m) => m Doc
+spacebreak = pure PP.spacebreak
-- | Document @(squotes x)@ encloses document @x@ with single quotes
-- \"'\".
-squotes :: (Monad m) => m Doc -> m Doc
-squotes = liftM PP.squotes
+squotes :: (Functor m) => m Doc -> m Doc
+squotes = fmap PP.squotes
-- | Document @(dquotes x)@ encloses document @x@ with double quotes
-- '\"'.
-dquotes :: (Monad m) => m Doc -> m Doc
-dquotes = liftM PP.dquotes
+dquotes :: (Functor m) => m Doc -> m Doc
+dquotes = fmap PP.dquotes
-- | Document @(braces x)@ encloses document @x@ in braces, \"{\" and
-- \"}\".
-braces :: (Monad m) => m Doc -> m Doc
-braces = liftM PP.braces
+braces :: (Functor m) => m Doc -> m Doc
+braces = fmap PP.braces
-- | Document @(parens x)@ encloses document @x@ in parenthesis, \"(\"
-- and \")\".
-parens :: (Monad m) => m Doc -> m Doc
-parens = liftM PP.parens
+parens :: (Functor m) => m Doc -> m Doc
+parens = fmap PP.parens
-- | Document @(angles x)@ encloses document @x@ in angles, \"\<\" and
-- \"\>\".
-angles :: (Monad m) => m Doc -> m Doc
-angles = liftM PP.angles
+angles :: (Functor m) => m Doc -> m Doc
+angles = fmap PP.angles
-- | Document @(brackets x)@ encloses document @x@ in square brackets,
-- \"[\" and \"]\".
-brackets :: (Monad m) => m Doc -> m Doc
-brackets = liftM PP.brackets
+brackets :: (Functor m) => m Doc -> m Doc
+brackets = fmap PP.brackets
-- | The document @(enclose l r x)@ encloses document @x@ between
-- documents @l@ and @r@ using @(\<\>)@.
--
-- > enclose l r x = l <> x <> r
-enclose :: (Monad m) => m Doc -> m Doc -> m Doc -> m Doc
-enclose = liftM3 PP.enclose
+enclose :: (Applicative m) => m Doc -> m Doc -> m Doc -> m Doc
+enclose = liftA3 PP.enclose
-- | The document @lparen@ contains a left parenthesis, \"(\".
-lparen :: (Monad m) => m Doc
-lparen = return PP.lparen
+lparen :: (Applicative m) => m Doc
+lparen = pure PP.lparen
-- | The document @rparen@ contains a right parenthesis, \")\".
-rparen :: (Monad m) => m Doc
-rparen = return PP.rparen
+rparen :: (Applicative m) => m Doc
+rparen = pure PP.rparen
-- | The document @langle@ contains a left angle, \"\<\".
-langle :: (Monad m) => m Doc
-langle = return PP.langle
+langle :: (Applicative m) => m Doc
+langle = pure PP.langle
-- | The document @rangle@ contains a right angle, \">\".
-rangle :: (Monad m) => m Doc
-rangle = return PP.rangle
+rangle :: (Applicative m) => m Doc
+rangle = pure PP.rangle
-- | The document @lbrace@ contains a left brace, \"{\".
-lbrace :: (Monad m) => m Doc
-lbrace = return PP.lbrace
+lbrace :: (Applicative m) => m Doc
+lbrace = pure PP.lbrace
-- | The document @rbrace@ contains a right brace, \"}\".
-rbrace :: (Monad m) => m Doc
-rbrace = return PP.rbrace
+rbrace :: (Applicative m) => m Doc
+rbrace = pure PP.rbrace
-- | The document @lbracket@ contains a left square bracket, \"[\".
-lbracket :: (Monad m) => m Doc
-lbracket = return PP.lbracket
+lbracket :: (Applicative m) => m Doc
+lbracket = pure PP.lbracket
-- | The document @rbracket@ contains a right square bracket, \"]\".
-rbracket :: (Monad m) => m Doc
-rbracket = return PP.rbracket
+rbracket :: (Applicative m) => m Doc
+rbracket = pure PP.rbracket
-- | The document @squote@ contains a single quote, \"'\".
-squote :: (Monad m) => m Doc
-squote = return PP.squote
+squote :: (Applicative m) => m Doc
+squote = pure PP.squote
-- | The document @dquote@ contains a double quote, '\"'.
-dquote :: (Monad m) => m Doc
-dquote = return PP.dquote
+dquote :: (Applicative m) => m Doc
+dquote = pure PP.dquote
-- | The document @semi@ contains a semi colon, \";\".
-semi :: (Monad m) => m Doc
-semi = return PP.semi
+semi :: (Applicative m) => m Doc
+semi = pure PP.semi
-- | The document @colon@ contains a colon, \":\".
-colon :: (Monad m) => m Doc
-colon = return PP.colon
+colon :: (Applicative m) => m Doc
+colon = pure PP.colon
-- | The document @comma@ contains a comma, \",\".
-comma :: (Monad m) => m Doc
-comma = return PP.comma
+comma :: (Applicative m) => m Doc
+comma = pure PP.comma
-- | The document @space@ contains a single space, \" \".
--
-- > x <+> y = x <> space <> y
-space :: (Monad m) => m Doc
-space = return PP.space
+space :: (Applicative m) => m Doc
+space = pure PP.space
-- | The document @dot@ contains a single dot, \".\".
-dot :: (Monad m) => m Doc
-dot = return PP.dot
+dot :: (Applicative m) => m Doc
+dot = pure PP.dot
-- | The document @backslash@ contains a back slash, \"\\\".
-backslash :: (Monad m) => m Doc
-backslash = return PP.backslash
+backslash :: (Applicative m) => m Doc
+backslash = pure PP.backslash
-- | The document @equals@ contains an equal sign, \"=\".
-equals :: (Monad m) => m Doc
-equals = return PP.equals
+equals :: (Applicative m) => m Doc
+equals = pure PP.equals
-----------------------------------------------------------
-- Combinators for prelude types
@@ -420,45 +421,48 @@
-- using @line@ for newline characters and @char@ for all other
-- characters. It is used instead of 'text' whenever the text
-- contains newline characters.
-string :: (Monad m) => Text -> m Doc
-string = return . PP.string
+string :: (Applicative m) => Text -> m Doc
+string = pure . PP.string
+
+stringStrict :: Monad m => TS.Text -> m Doc
+stringStrict = return . PP.stringStrict
-- | The document @(bool b)@ shows the literal boolean @b@ using
-- 'text'.
-bool :: (Monad m) => Bool -> m Doc
-bool = return . PP.bool
+bool :: (Applicative m) => Bool -> m Doc
+bool = pure . PP.bool
-- | The document @(int i)@ shows the literal integer @i@ using
-- 'text'.
-int :: (Monad m) => Int -> m Doc
-int = return . PP.int
+int :: (Applicative m) => Int -> m Doc
+int = pure . PP.int
-- | The document @(integer i)@ shows the literal integer @i@ using
-- 'text'.
-integer :: (Monad m) => Integer -> m Doc
-integer = return . PP.integer
+integer :: (Applicative m) => Integer -> m Doc
+integer = pure . PP.integer
-- | The document @(float f)@ shows the literal float @f@ using
-- 'text'.
-float :: (Monad m) => Float -> m Doc
-float = return . PP.float
+float :: (Applicative m) => Float -> m Doc
+float = pure . PP.float
-- | The document @(double d)@ shows the literal double @d@ using
-- 'text'.
-double :: (Monad m) => Double -> m Doc
-double = return . PP.double
+double :: (Applicative m) => Double -> m Doc
+double = pure . PP.double
-- | The document @(rational r)@ shows the literal rational @r@ using
-- 'text'.
-rational :: (Monad m) => Rational -> m Doc
-rational = return . PP.rational
+rational :: (Applicative m) => Rational -> m Doc
+rational = pure . PP.rational
-- | A monadic version of 'pretty'; this is to allow you to use the
-- 'Pretty' class without having to create extra instances.
-- Alternatively, you may wish to make a variant of 'Pretty' using
-- the actual 'Monad' to be used.
-prettyM :: (Pretty a, Monad m) => a -> m Doc
-prettyM = return . pretty
+prettyM :: (Pretty a, Applicative m) => a -> m Doc
+prettyM = pure . pretty
-- | The document @(fill i x)@ renders document @x@. It then appends
-- @space@s until the width is equal to @i@. If the width of @x@ is
@@ -482,12 +486,12 @@
-- nest :: Int -> Doc -> Doc
-- linebreak :: Doc
-- @
-fill :: (Monad m) => Int -> m Doc -> m Doc
-fill = liftM . PP.fill
+fill :: (Functor m) => Int -> m Doc -> m Doc
+fill = fmap . PP.fill
-width :: (Monad m) => m Doc -> m (Int -> Doc) -> m Doc
-width = liftM2 PP.width
+width :: (Applicative m) => m Doc -> m (Int -> Doc) -> m Doc
+width = liftA2 PP.width
-- | The document @(fillBreak i x)@ first renders document @x@. It
-- then appends @space@s until the width is equal to @i@. If the
@@ -507,8 +511,8 @@
-- linebreak
-- :: Doc
-- @
-fillBreak :: (Monad m) => Int -> m Doc -> m Doc
-fillBreak = liftM . PP.fillBreak
+fillBreak :: (Functor m) => Int -> m Doc -> m Doc
+fillBreak = fmap . PP.fillBreak
-- | The document @(indent i x)@ indents document @x@ with @i@ spaces.
--
@@ -523,8 +527,8 @@
-- indents these
-- words !
-- @
-indent :: (Monad m) => Int -> m Doc -> m Doc
-indent = liftM . PP.indent
+indent :: (Functor m) => Int -> m Doc -> m Doc
+indent = fmap . PP.indent
-- | The hang combinator implements hanging indentation. The document
-- @(hang i x)@ renders document @x@ with a nesting level set to the
@@ -545,8 +549,8 @@
-- The @hang@ combinator is implemented as:
--
-- > hang i x = align (nest i x)
-hang :: (Monad m) => Int -> m Doc -> m Doc
-hang = liftM . PP.hang
+hang :: (Functor m) => Int -> m Doc -> m Doc
+hang = fmap . PP.hang
-- | The document @(align x)@ renders document @x@ with the nesting
-- level set to the current column. It is used for example to
@@ -565,40 +569,43 @@
-- hi nice
-- world
-- @
-align :: (Monad m) => m Doc -> m Doc
-align = liftM PP.align
+align :: (Functor m) => m Doc -> m Doc
+align = fmap PP.align
-- | The empty document is, indeed, empty. Although @empty@ has no
-- content, it does have a \'height\' of 1 and behaves exactly like
-- @(text \"\")@ (and is therefore not a unit of @\<$\>@).
-empty :: (Monad m) => m Doc
-empty = return PP.empty
+empty :: (Applicative m) => m Doc
+empty = pure PP.empty
-- | The document @(char c)@ contains the literal character @c@. The
-- character shouldn't be a newline (@'\n'@), the function 'line'
-- should be used for line breaks.
-char :: (Monad m) => Char -> m Doc
-char = return . PP.char
+char :: (Applicative m) => Char -> m Doc
+char = pure . PP.char
-- | The document @(text s)@ contains the literal string @s@. The
-- string shouldn't contain any newline (@'\n'@) characters. If the
-- string contains newline characters, the function 'string' should
-- be used.
-text :: (Monad m) => Text -> m Doc
-text = return . PP.text
+text :: (Applicative m) => Text -> m Doc
+text = pure . PP.text
+
+textStrict :: Monad m => TS.Text -> m Doc
+textStrict = return . PP.textStrict
-- | The @line@ document advances to the next line and indents to the
-- current nesting level. Document @line@ behaves like @(text \"
-- \")@ if the line break is undone by 'group' or if rendered with
-- 'renderOneLine'.
-line :: (Monad m) => m Doc
-line = return PP.line
+line :: (Applicative m) => m Doc
+line = pure PP.line
-- | The @linebreak@ document advances to the next line and indents to
-- the current nesting level. Document @linebreak@ behaves like
-- 'empty' if the line break is undone by 'group'.
-linebreak :: (Monad m) => m Doc
-linebreak = return PP.linebreak
+linebreak :: (Applicative m) => m Doc
+linebreak = pure PP.linebreak
-- | The document @(nest i x)@ renders document @x@ with the current
-- indentation level increased by @i@ (See also 'hang', 'align' and
@@ -613,22 +620,22 @@
-- world
-- !
-- @
-nest :: (Monad m) => Int -> m Doc -> m Doc
-nest = liftM . PP.nest
+nest :: (Functor m) => Int -> m Doc -> m Doc
+nest = fmap . PP.nest
-- | Specifies how to create the document based upon which column it is in.
-column :: (Monad m) => m (Int -> Doc) -> m Doc
-column = liftM PP.column
+column :: (Functor m) => m (Int -> Doc) -> m Doc
+column = fmap PP.column
-- | Specifies how to nest the document based upon which column it is
-- being nested in.
-nesting :: (Monad m) => m (Int -> Doc) -> m Doc
-nesting = liftM PP.nesting
+nesting :: (Functor m) => m (Int -> Doc) -> m Doc
+nesting = fmap PP.nesting
-- | The @group@ combinator is used to specify alternative
-- layouts. The document @(group x)@ undoes all line breaks in
-- document @x@. The resulting line is added to the current line if
-- that fits the page. Otherwise, the document @x@ is rendered
-- without any changes.
-group :: (Monad m) => m Doc -> m Doc
-group = liftM PP.group
+group :: (Functor m) => m Doc -> m Doc
+group = fmap PP.group
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wl-pprint-text-1.1.0.4/Text/PrettyPrint/Leijen/Text.hs new/wl-pprint-text-1.1.1.0/Text/PrettyPrint/Leijen/Text.hs
--- old/wl-pprint-text-1.1.0.4/Text/PrettyPrint/Leijen/Text.hs 2015-04-06 14:24:45.000000000 +0200
+++ new/wl-pprint-text-1.1.1.0/Text/PrettyPrint/Leijen/Text.hs 2017-01-26 12:56:06.000000000 +0100
@@ -70,8 +70,8 @@
Doc,
-- * Basic combinators
- empty, char, text, (<>), nest, line, linebreak, group, softline,
- softbreak, spacebreak,
+ empty, isEmpty, char, text, textStrict, (<>), nest, line, linebreak, group,
+ softline, softbreak, spacebreak,
-- * Alignment
--
@@ -104,7 +104,7 @@
squote, dquote, semi, colon, comma, space, dot, backslash, equals,
-- * Primitive type documents
- string, int, integer, float, double, rational, bool,
+ string, stringStrict, int, integer, float, double, rational, bool,
-- * Position-based combinators
column, nesting, width,
@@ -114,28 +114,34 @@
-- * Rendering
SimpleDoc(..), renderPretty, renderCompact, renderOneLine,
- displayB, displayT, displayIO, putDoc, hPutDoc
+ displayB, displayT, displayTStrict, displayIO, putDoc, hPutDoc
) where
-#if defined(__GLASGOW_HASKELL__) && __GLASGOW_HASKELL__ >= 710
-import Prelude hiding ((<$>))
-#endif
+import Prelude ()
+import Prelude.Compat hiding ((<$>))
-import Data.String (IsString (..))
+import Data.String (IsString(..))
import System.IO (Handle, hPutChar, stdout)
import Data.Int (Int64)
-import Data.Monoid (Monoid (..))
+import Data.List (intersperse)
+import Data.Monoid (Monoid(..))
+import qualified Data.Text as TS
import Data.Text.Lazy (Text)
import qualified Data.Text.Lazy as T
import Data.Text.Lazy.Builder (Builder)
import qualified Data.Text.Lazy.Builder as B
import qualified Data.Text.Lazy.IO as T
+#if MIN_VERSION_base (4,9,0)
+import Data.Semigroup (Semigroup(..))
+#else
+import Data.Monoid ((<>))
+#endif
infixr 5 </>,<//>,<$>,<$$>
-infixr 6 <>,<+>,<++>
+infixr 6 <+>,<++>
-----------------------------------------------------------
@@ -227,8 +233,8 @@
-- (If you want put the commas in front of their elements instead of
-- at the end, you should use 'tupled' or, in general, 'encloseSep'.)
punctuate :: Doc -> [Doc] -> [Doc]
-punctuate _ [] = []
-punctuate _ [d] = [d]
+punctuate _ [] = []
+punctuate _ [d] = [d]
punctuate p (d:ds) = (d <> p) : punctuate p ds
@@ -324,12 +330,6 @@
fold _ [] = empty
fold f ds = foldr1 f ds
--- | The document @(x \<\> y)@ concatenates document @x@ and document
--- @y@. It is an associative operation having 'empty' as a left and
--- right unit. (infixr 6)
-(<>) :: Doc -> Doc -> Doc
-x <> y = x `beside` y
-
-- | The document @(x \<+\> y)@ concatenates document @x@ and @y@ with
-- a 'space' in between. (infixr 6)
(<+>) :: Doc -> Doc -> Doc
@@ -516,41 +516,40 @@
-- characters. It is used instead of 'text' whenever the text
-- contains newline characters.
string :: Text -> Doc
-string str = case T.uncons str of
- Nothing -> empty
- Just ('\n',str') -> line <> string str'
- _ -> case (T.span (/='\n') str) of
- (xs,ys) -> text xs <> string ys
+string = mconcat . intersperse line . map text . T.lines
+
+stringStrict :: TS.Text -> Doc
+stringStrict = mconcat . intersperse line . map textStrict . TS.lines
-- | The document @(bool b)@ shows the literal boolean @b@ using
-- 'text'.
bool :: Bool -> Doc
-bool b = text' b
+bool = text'
-- | The document @(int i)@ shows the literal integer @i@ using
-- 'text'.
int :: Int -> Doc
-int i = text' i
+int = text'
-- | The document @(integer i)@ shows the literal integer @i@ using
-- 'text'.
integer :: Integer -> Doc
-integer i = text' i
+integer = text'
-- | The document @(float f)@ shows the literal float @f@ using
-- 'text'.
float :: Float -> Doc
-float f = text' f
+float = text'
-- | The document @(double d)@ shows the literal double @d@ using
-- 'text'.
double :: Double -> Doc
-double d = text' d
+double = text'
-- | The document @(rational r)@ shows the literal rational @r@ using
-- 'text'.
rational :: Rational -> Doc
-rational r = text' r
+rational = text'
text' :: (Show a) => a -> Doc
text' = text . T.pack . show
@@ -577,40 +576,43 @@
instance Pretty Text where
pretty = string
+instance Pretty TS.Text where
+ pretty = stringStrict
+
instance Pretty () where
pretty () = text' ()
instance Pretty Bool where
- pretty b = bool b
+ pretty = bool
instance Pretty Char where
- pretty c = char c
+ pretty = char
- prettyList s = string $ T.pack s
+ prettyList = string . T.pack
instance Pretty Int where
- pretty i = int i
+ pretty = int
instance Pretty Integer where
- pretty i = integer i
+ pretty = integer
instance Pretty Float where
- pretty f = float f
+ pretty = float
instance Pretty Double where
- pretty d = double d
+ pretty = double
--instance Pretty Rational where
-- pretty r = rational r
-instance (Pretty a,Pretty b) => Pretty (a,b) where
+instance (Pretty a, Pretty b) => Pretty (a,b) where
pretty (x,y) = tupled [pretty x, pretty y]
-instance (Pretty a,Pretty b,Pretty c) => Pretty (a,b,c) where
+instance (Pretty a, Pretty b, Pretty c) => Pretty (a,b,c) where
pretty (x,y,z)= tupled [pretty x, pretty y, pretty z]
instance Pretty a => Pretty (Maybe a) where
- pretty Nothing = empty
+ pretty Nothing = empty
pretty (Just x) = pretty x
@@ -638,7 +640,7 @@
-- @
fillBreak :: Int -> Doc -> Doc
fillBreak f x = width x (\w ->
- if (w > f)
+ if w > f
then nest f linebreak
else spaced (f - w)
)
@@ -668,7 +670,7 @@
-- @
fill :: Int -> Doc -> Doc
fill f d = width d (\w ->
- if (w >= f)
+ if w >= f
then empty
else spaced (f - w)
)
@@ -773,6 +775,14 @@
instance IsString Doc where
fromString = string . T.pack
+-- | In particular, note that the document @(x '<>' y)@ concatenates
+-- document @x@ and document @y@. It is an associative operation
+-- having 'empty' as a left and right unit. (infixr 6)
+#if MIN_VERSION_base (4,9,0)
+instance Semigroup Doc where
+ (<>) = beside
+
+#endif
instance Monoid Doc where
mempty = empty
mappend = beside
@@ -796,6 +806,11 @@
empty :: Doc
empty = Empty
+-- | Determine if the document is empty or not.
+isEmpty :: Doc -> Bool
+isEmpty Empty = True
+isEmpty _ = False
+
-- | The document @(char c)@ contains the literal character @c@. The
-- character shouldn't be a newline (@'\n'@), the function 'line'
-- should be used for line breaks.
@@ -812,6 +827,11 @@
| T.null s = Empty
| otherwise = Text (T.length s) (B.fromLazyText s)
+textStrict :: TS.Text -> Doc
+textStrict s
+ | TS.null s = Empty
+ | otherwise = Text (fromIntegral $ TS.length s) (B.fromText s)
+
-- | The @line@ document advances to the next line and indents to the
-- current nesting level. Document @line@ behaves like @(text \"
-- \")@ if the line break is undone by 'group' or if rendered with
@@ -1011,14 +1031,16 @@
displayT :: SimpleDoc -> Text
displayT = B.toLazyText . displayB
+displayTStrict :: SimpleDoc -> TS.Text
+displayTStrict = T.toStrict . displayT
+
-- | @(displayIO handle simpleDoc)@ writes @simpleDoc@ to the
-- file handle @handle@. This function is used for example by
-- 'hPutDoc':
--
-- > hPutDoc handle doc = displayIO handle (renderPretty 0.4 100 doc)
displayIO :: Handle -> SimpleDoc -> IO ()
-displayIO handle simpleDoc
- = display simpleDoc
+displayIO handle = display
where
display SEmpty = return ()
display (SChar c x) = hPutChar handle c >> display x
@@ -1051,7 +1073,7 @@
-- hello world
-- @
putDoc :: Doc -> IO ()
-putDoc doc = hPutDoc stdout doc
+putDoc = hPutDoc stdout
-- | @(hPutDoc handle doc)@ pretty prints document @doc@ to the file
-- handle @handle@ with a page width of 100 characters and a ribbon
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/wl-pprint-text-1.1.0.4/wl-pprint-text.cabal new/wl-pprint-text-1.1.1.0/wl-pprint-text.cabal
--- old/wl-pprint-text-1.1.0.4/wl-pprint-text.cabal 2015-04-06 14:24:45.000000000 +0200
+++ new/wl-pprint-text-1.1.1.0/wl-pprint-text.cabal 2017-01-26 12:56:06.000000000 +0100
@@ -1,5 +1,5 @@
Name: wl-pprint-text
-Version: 1.1.0.4
+Version: 1.1.1.0
Synopsis: A Wadler/Leijen Pretty Printer for Text values
Description: A clone of wl-pprint for use with the text library.
License: BSD3
@@ -9,14 +9,19 @@
Copyright: 2007 Daan Leijen, 2010 Ivan Lazar Miljenovic
Category: Text
Build-type: Simple
+Tested-With: GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4,
+ GHC == 7.10.2, GHC == 8.0.1, GHC == 8.1.*
Cabal-version: >=1.6
+Extra-Source-Files: Changelog.md
+ README.md
Source-Repository head
type: git
- location: git://github.com/ivan-m/wl-pprint-text.git
+ location: https://github.com/ivan-m/wl-pprint-text.git
Library
Exposed-modules: Text.PrettyPrint.Leijen.Text,
Text.PrettyPrint.Leijen.Text.Monadic
- Build-depends: base < 5,
+ Build-depends: base >= 4.5.0.0 && < 5,
+ base-compat >= 0.9 && < 0.10,
text >= 0.11.0.0 && < 1.3.0.0
1
0
Hello community,
here is the log from the commit of package ghc-web-routes-th for openSUSE:Factory checked in at 2017-02-22 13:53:50
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-web-routes-th (Old)
and /work/SRC/openSUSE:Factory/.ghc-web-routes-th.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-web-routes-th"
Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-web-routes-th/ghc-web-routes-th.changes 2017-02-03 17:40:33.496437051 +0100
+++ /work/SRC/openSUSE:Factory/.ghc-web-routes-th.new/ghc-web-routes-th.changes 2017-02-22 13:53:51.417563949 +0100
@@ -1,0 +2,5 @@
+Mon Jan 30 09:29:41 UTC 2017 - psimons(a)suse.com
+
+- Update to version 0.22.6.1 with cabal2obs.
+
+-------------------------------------------------------------------
Old:
----
web-routes-th-0.22.6.tar.gz
New:
----
web-routes-th-0.22.6.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ ghc-web-routes-th.spec ++++++
--- /var/tmp/diff_new_pack.x0zjM6/_old 2017-02-22 13:53:51.973484845 +0100
+++ /var/tmp/diff_new_pack.x0zjM6/_new 2017-02-22 13:53:51.973484845 +0100
@@ -1,7 +1,7 @@
#
# spec file for package ghc-web-routes-th
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 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
@@ -19,7 +19,7 @@
%global pkg_name web-routes-th
%bcond_with tests
Name: ghc-%{pkg_name}
-Version: 0.22.6
+Version: 0.22.6.1
Release: 0
Summary: Support for deriving PathInfo using Template Haskell
License: BSD-3-Clause
++++++ web-routes-th-0.22.6.tar.gz -> web-routes-th-0.22.6.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/web-routes-th-0.22.6/web-routes-th.cabal new/web-routes-th-0.22.6.1/web-routes-th.cabal
--- old/web-routes-th-0.22.6/web-routes-th.cabal 2016-11-03 01:39:34.000000000 +0100
+++ new/web-routes-th-0.22.6.1/web-routes-th.cabal 2017-01-25 20:25:41.000000000 +0100
@@ -1,5 +1,5 @@
Name: web-routes-th
-Version: 0.22.6
+Version: 0.22.6.1
License: BSD3
License-File: LICENSE
Author: jeremy(a)seereason.com
@@ -23,7 +23,7 @@
main-is : Test.hs
hs-source-dirs : test
build-depends : base == 4.*,
- hspec >= 2.2 && < 2.4,
+ hspec >= 2.2 && < 2.5,
HUnit,
QuickCheck,
web-routes,
1
0