Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37042974
en ru br
ALT Linux repos
S:2.4.0-alt1

Group :: Development/Python3
RPM: python3-module-qtpy

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

%define _unpackaged_files_terminate_build 1

%define oname qtpy

%def_with check

Name: python3-module-%oname
Version: 2.3.1
Release: alt1
Summary: Provides an uniform layer to support PyQt5, PySide2, PyQt6, PySide6 with a single codebase
License: MIT
Group: Development/Python3
Url: https://pypi.org/project/QtPy/
Vcs: https://github.com/spyder-ide/qtpy.git

BuildArch: noarch

Source: %name-%version.tar

BuildRequires(pre): rpm-build-python3
BuildRequires: python3-module-setuptools
BuildRequires: python3-module-wheel
%if_with check
BuildRequires: xvfb-run
BuildRequires: python3-module-pytest
BuildRequires: python3-module-pytest-qt
BuildRequires: python3-module-PyQt5
%endif

%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, PyQt6, PySide6, PySide2 using the Qt5 layout
(where the QtGui module has been split into QtGui and QtWidgets).

Basically, you can write your code as if you were using PyQt or PySide directly,
but import Qt modules from qtpy instead of PyQt5, PySide2, PyQt6 or PySide6.

%package tests
Summary: Tests for %oname
Group: Development/Python3
Requires: %name = %EVR

%description tests
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, PySide2 and PySide
using the Qt5 layout
(where the QtGui module has been split into QtGui and QtWidgets).

Basically, you can write your code as if you were using PySide2
but import Qt modules from qtpy instead of PySide2 (or PyQt5)

This package contains tests for %oname.

%prep
%setup

%build
%pyproject_build

%install
%pyproject_install

%check
sed -i 's/--cov=qtpy --cov-report=term-missing//' pytest.ini
sed -i 's/--color=yes//' pytest.ini
%pyproject_run -- xvfb-run pytest qtpy -k 'not test_qttexttospeech'

%files
%doc LICENSE.txt
%doc AUTHORS.md CHANGELOG.md README.md
%_bindir/%oname
%python3_sitelibdir/QtPy-%version.dist-info
%python3_sitelibdir/%oname
%exclude %python3_sitelibdir/%oname/tests

%files tests
%python3_sitelibdir/%oname/tests

%changelog

Full changelog you can see here

 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin