Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,5 @@ omit =
*/tests/*
# Omit other files
*/__init__.py
*/py3compat.py
*/compat.py
*/_version.py
9 changes: 3 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
strategy:
fail-fast: false
matrix:
PYTHON_VERSION: ['2.7', '3.6', '3.8']
PYTHON_VERSION: ['3.6', '3.8']
USE_CONDA: ['Yes', 'No']
steps:
- name: Checkout branch
Expand Down Expand Up @@ -61,11 +61,8 @@ jobs:
strategy:
fail-fast: false
matrix:
PYTHON_VERSION: ['2.7', '3.6', '3.8']
PYTHON_VERSION: ['3.6', '3.8']
USE_CONDA: ['Yes', 'No']
exclude:
- PYTHON_VERSION: '2.7'
USE_CONDA: 'Yes'
steps:
- name: Checkout branch
uses: actions/checkout@v2
Expand Down Expand Up @@ -95,7 +92,7 @@ jobs:
strategy:
fail-fast: false
matrix:
PYTHON_VERSION: ['2.7', '3.6', '3.8']
PYTHON_VERSION: ['3.6', '3.8']
USE_CONDA: ['Yes', 'No']
steps:
- name: Checkout branch
Expand Down
27 changes: 8 additions & 19 deletions .github/workflows/test-pyqt5.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,29 +7,23 @@ conda activate test-pyqt5
# Select build with QtMultimedia
if [ "$(uname)" == "Darwin" ]; then

if [ "$PYTHON_VERSION" = "2.7" ]; then
export QT_VER=5.9
elif [ "$PYTHON_VERSION" = "3.6" ]; then
if [ "$PYTHON_VERSION" = "3.6" ]; then
export QT_VER=5.12
else
export QT_VER=5.*
fi

elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then

if [ "$PYTHON_VERSION" = "2.7" ]; then
export QT_VER=5.9
elif [ "$PYTHON_VERSION" = "3.6" ]; then
if [ "$PYTHON_VERSION" = "3.6" ]; then
export QT_VER=5.12
else
export QT_VER=5.*
fi

else

if [ "$PYTHON_VERSION" = "2.7" ]; then
exit 0
elif [ "$PYTHON_VERSION" = "3.6" ]; then
if [ "$PYTHON_VERSION" = "3.6" ]; then
export QT_VER=5.9
else
export QT_VER=5.*
Expand All @@ -38,17 +32,12 @@ else
fi

if [ "$USE_CONDA" = "Yes" ]; then
conda install coveralls mock pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge -q
conda install -q qt=$QT_VER pyqt=$QT_VER -c conda-forge -q
conda install -q coveralls pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge
conda install -q qt=$QT_VER pyqt=$QT_VER -c conda-forge
else
if [ "$PYTHON_VERSION" = "2.7" ]; then
# There are no pyqt5 wheels for Python 2
exit 0
else
# We are getting segfaults in 5.10
conda install coveralls mock pytest pytest-cov python="$PYTHON_VERSION" -c anaconda -q
pip install -q pyqt5 PyQtWebEngine
fi
# We are getting segfaults in 5.10
conda install -q coveralls pytest pytest-cov python="$PYTHON_VERSION" -c anaconda
pip install -q pyqt5 PyQtWebEngine
fi

# Install package
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test-pyside2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ if [ "$USE_CONDA" = "Yes" ]; then
# There are no conda packages for PySide2
exit 0
elif [ "$PYTHON_VERSION" != "3.6" ] && [ "$RUNNER_OS" = "Windows" ]; then
# There is no wheel for PySide 5.12 on Windows and Python 2.7 or 3.8
# There is no wheel for PySide 5.12 on Windows and Python 3.8
exit 0
else
# Simple solution to avoid failures with the Qt3D modules
conda install coveralls mock pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge -q
conda install -q coveralls pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge
pip install -q pyside2==5.12
fi

Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/test-pyside6.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,9 @@ conda activate test-pyside6
if [ "$USE_CONDA" = "Yes" ]; then
# There are no conda packages for PySide6
exit 0
elif [ "$PYTHON_VERSION" == "2.7" ]; then
# There is no wheel for PySide6 on Python 2.7
exit 0
else
# Simple solution to avoid failures with the Qt3D modules
conda install coveralls mock pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge -q
conda install -q coveralls pytest pytest-cov python="$PYTHON_VERSION" -c conda-forge
pip install -q pyside6==6.2.0
fi

Expand Down
12 changes: 8 additions & 4 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,27 @@ To release a new version of qtpy on PyPI:

* git clean -xfdi

* Update CHANGELOG.md
* Update CHANGELOG.md using `loghub` to generate the list of issues and PRs merged to add at the top of the file

loghub -m vX.X.X spyder-ide/qtpy

* Update `_version.py` (set release version, remove 'dev0')

* git add and git commit
* git add . && git commit -m 'Release X.X.X'

* python setup.py sdist

* python setup.py bdist_wheel

* twine check dist/*

* twine upload dist/*

* git tag -a vX.X.X -m 'comment'
* git tag -a vX.X.X -m 'Release X.X.X'

* Update `_version.py` (add 'dev0' and increment minor)

* git add and git commit
* git add . && git commit -m 'Back to work'

* git push

Expand Down
15 changes: 5 additions & 10 deletions qtpy/Qt3DAnimation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -9,18 +8,14 @@

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2

if PYQT5:
from PyQt5.Qt3DAnimation import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DAnimation as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DAnimation):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DAnimation as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DAnimation):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
17 changes: 6 additions & 11 deletions qtpy/Qt3DCore.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -8,19 +7,15 @@
"""Provides Qt3DCore classes and functions."""

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2
from . import PYQT5, PYSIDE2, PythonQtError

if PYQT5:
from PyQt5.Qt3DCore import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DCore as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DCore):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DCore as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DCore):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
17 changes: 6 additions & 11 deletions qtpy/Qt3DExtras.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -8,19 +7,15 @@
"""Provides Qt3DExtras classes and functions."""

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2
from . import PYQT5, PYSIDE2, PythonQtError

if PYQT5:
from PyQt5.Qt3DExtras import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DExtras as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DExtras):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DExtras as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DExtras):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
17 changes: 6 additions & 11 deletions qtpy/Qt3DInput.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -8,19 +7,15 @@
"""Provides Qt3DInput classes and functions."""

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2
from . import PYQT5, PYSIDE2, PythonQtError

if PYQT5:
from PyQt5.Qt3DInput import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DInput as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DInput):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DInput as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DInput):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
17 changes: 6 additions & 11 deletions qtpy/Qt3DLogic.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -8,19 +7,15 @@
"""Provides Qt3DLogic classes and functions."""

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2
from . import PYQT5, PYSIDE2, PythonQtError

if PYQT5:
from PyQt5.Qt3DLogic import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DLogic as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DLogic):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DLogic as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DLogic):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
17 changes: 6 additions & 11 deletions qtpy/Qt3DRender.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand All @@ -8,19 +7,15 @@
"""Provides Qt3DRender classes and functions."""

# Local imports
from . import PYQT5, PYSIDE2, PythonQtError, PYSIDE_VERSION
from .py3compat import PY2
from . import PYQT5, PYSIDE2, PythonQtError

if PYQT5:
from PyQt5.Qt3DRender import *
elif PYSIDE2:
if not PY2 or (PY2 and PYSIDE_VERSION < '5.12.4'):
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DRender as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DRender):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('A bug in Shiboken prevents this')
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-1026
import PySide2.Qt3DRender as __temp
import inspect
for __name in inspect.getmembers(__temp.Qt3DRender):
globals()[__name[0]] = __name[1]
else:
raise PythonQtError('No Qt bindings could be found')
1 change: 0 additions & 1 deletion qtpy/QtCharts.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2019- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtCore.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2014-2015 Colin Duquesnoy
# Copyright © 2009- The Spyder Development Team
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtDataVisualization.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtDesigner.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2014-2015 Colin Duquesnoy
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtGui.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2014-2015 Colin Duquesnoy
# Copyright © 2009- The Spyder Development Team
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtHelp.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2009- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtLocation.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtMultimediaWidgets.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtNetwork.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2014-2015 Colin Duquesnoy
# Copyright © 2009- The Spyder Development Team
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtOpenGL.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtPositioning.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
# -----------------------------------------------------------------------------
# Copyright 2020 Antonio Valentino
#
Expand Down
1 change: 0 additions & 1 deletion qtpy/QtPrintSupport.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
#
# Copyright © 2009- The Spyder Development Team
#
Expand Down
Loading