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.loren...@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/pypi/qtpy)
+[![Join the chat at 
https://gitter.im/spyder-ide/public](https://badges.gitter.im/spyder-ide/spyder.svg)](https://gitter.im/spyder-ide/public)
+
+## Build status
+[![Build 
status](https://ci.appveyor.com/api/projects/status/62y6i02vhn4hefg0/branch/master?svg=true)](https://ci.appveyor.com/project/spyder-ide/qtpy/branch/master)
+[![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/c769241c7d7f4463b1e6f67863dabace/badge.svg)](https://www.quantifiedcode.com/app/project/c769241c7d7f4463b1e6f67863dabace)
+[![Scrutinizer Code 
Quality](https://scrutinizer-ci.com/g/spyder-ide/qtpy/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/spyder-ide/qtpy/?branch=master)
+
+## 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
+"""
+
+@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:


Reply via email to