1
0
Files
python-spyder-terminal/python-spyder-terminal.spec

124 lines
4.7 KiB
RPMSpec
Raw Permalink Normal View History

#
# spec file for package python-spyder-terminal
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
# Not really singlespec: Spyder is an app only for the primary python3 interpreter
# But we need the python3-spyder-terminal name, provided by the python_subpackages rewrite
%define pythons python3
Name: python-spyder-terminal
Version: 1.2.2
Release: 0
Summary: Operating system virtual terminal plugin for the Spyder IDE
License: MIT
Group: Development/Languages/Python
URL: https://github.com/spyder-ide/spyder-terminal
Accepting request 830082 from home:bnavigator:branches:devel:languages:python:numeric - Updated to Version 0.4.2 * PR 237 - PR: Add Xonsh to list of supported terminals in Unix and Windows, by @steff456 - Version 0.4.1 (2020/08/05) * Issue 235 - Plugin fails on Python 3.8 and Windows (PR 236 by @steff456) * PR 236 - PR: Add tornado patch for python 3.8 in windows, by @steff456 (235) - Version 0.4.0 (2020/07/21) * Issue 233 - Update translations * Issue 227 - Add option to set buffer limit (PR 228 by @steff456) * Issue 225 - Terminal error "ValueError: Invalid cookie 'cwd'" (PR 229 by @steff456) * Issue 224 - Add widget for find functionality in the terminal (PR 226 by @steff456) * Issue 219 - Remove QWebKit from the code (PR 221 by @steff456) * Issue 218 - Shortcuts are not appearing in the preferences pane (PR 222 by @steff456) * Issue 213 - Update to xterm.js latest version (PR 214 by @steff456) * Issue 212 - Migrate this plugin to Python 3 (PR 215 by @steff456) * Issue 206 - Correctly generate logging files (PR 210 by @steff456) * Issue 202 - Problems when highlight text on terminal (PR 216 by @steff456) * Issue 148 - How to increase/decrease size of font in terminal? (PR 217 by @steff456) * In this release 11 issues were closed. * PR 232 - New Crowdin updates, by @spyder-bot * PR 231 - PR: Update translation files, by @steff456 * PR 229 - PR: Percent encode/decode cwd to encode spaces and special characters, by @steff456 (225) * PR 228 - PR: Add scrollback option to the terminal, by @steff456 (227) * PR 226 - PR: Add find widget to the terminal, by @steff456 (224) * PR 223 - PR: Improve clipboard support in the terminal, by @steff456 * PR 222 - PR: Fix shortcuts to new API, by @steff456 (218) * PR 221 - PR: Remove deprecated QWebKit code, by @steff456 (219) * PR 217 - PR: Add option to zoom in/zoom out in the terminal, by @steff456 (148) * PR 216 - PR: Fix highlight text on the terminal, by @steff456 (202) * PR 215 - PR: Move Spyder-terminal plugin to Python 3, by @steff456 (212) * PR 214 - PR: Upgrade xterm to 4.7 release, by @steff456 (213) * PR 211 - PR: Fix issues when running our test suite in Azure, by @ccordoba12 * PR 210 - PR: Generate logging files with Spyder's debug level, by @steff456 (206) * PR 208 - Bump websocket-extensions from 0.1.3 to 0.1.4, by @dependabot[bot] * PR 204 - Bump jquery from 3.4.1 to 3.5.0, by @dependabot[bot] OBS-URL: https://build.opensuse.org/request/show/830082 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-spyder-terminal?expand=0&rev=14
2020-08-28 07:53:40 +00:00
# The PyPI tarfile is the official release but does not include the tests.
# The Github tarfile does not include the bundled nodejs dependencies in
# server/static/components. Thus we use the PyPI release and add the testdir
# from the Github package.
Source0: https://files.pythonhosted.org/packages/source/s/spyder-terminal/spyder-terminal-%{version}.tar.gz#/%{name}-%{version}-pypi.tar.gz
Source1: https://github.com/spyder-ide/spyder-terminal/archive/v%{version}.tar.gz#/%{name}-%{version}-gh.tar.gz
# The bundled nodejs stuff has a few files tripping rpmlint
Source2: %{name}-rpmlintrc
# PATCH-FIX-OPENSUSE fix-test-terminal-closing.patch
Patch0: fix-test-terminal-closing.patch
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildRequires: python3-setuptools
Accepting request 830082 from home:bnavigator:branches:devel:languages:python:numeric - Updated to Version 0.4.2 * PR 237 - PR: Add Xonsh to list of supported terminals in Unix and Windows, by @steff456 - Version 0.4.1 (2020/08/05) * Issue 235 - Plugin fails on Python 3.8 and Windows (PR 236 by @steff456) * PR 236 - PR: Add tornado patch for python 3.8 in windows, by @steff456 (235) - Version 0.4.0 (2020/07/21) * Issue 233 - Update translations * Issue 227 - Add option to set buffer limit (PR 228 by @steff456) * Issue 225 - Terminal error "ValueError: Invalid cookie 'cwd'" (PR 229 by @steff456) * Issue 224 - Add widget for find functionality in the terminal (PR 226 by @steff456) * Issue 219 - Remove QWebKit from the code (PR 221 by @steff456) * Issue 218 - Shortcuts are not appearing in the preferences pane (PR 222 by @steff456) * Issue 213 - Update to xterm.js latest version (PR 214 by @steff456) * Issue 212 - Migrate this plugin to Python 3 (PR 215 by @steff456) * Issue 206 - Correctly generate logging files (PR 210 by @steff456) * Issue 202 - Problems when highlight text on terminal (PR 216 by @steff456) * Issue 148 - How to increase/decrease size of font in terminal? (PR 217 by @steff456) * In this release 11 issues were closed. * PR 232 - New Crowdin updates, by @spyder-bot * PR 231 - PR: Update translation files, by @steff456 * PR 229 - PR: Percent encode/decode cwd to encode spaces and special characters, by @steff456 (225) * PR 228 - PR: Add scrollback option to the terminal, by @steff456 (227) * PR 226 - PR: Add find widget to the terminal, by @steff456 (224) * PR 223 - PR: Improve clipboard support in the terminal, by @steff456 * PR 222 - PR: Fix shortcuts to new API, by @steff456 (218) * PR 221 - PR: Remove deprecated QWebKit code, by @steff456 (219) * PR 217 - PR: Add option to zoom in/zoom out in the terminal, by @steff456 (148) * PR 216 - PR: Fix highlight text on the terminal, by @steff456 (202) * PR 215 - PR: Move Spyder-terminal plugin to Python 3, by @steff456 (212) * PR 214 - PR: Upgrade xterm to 4.7 release, by @steff456 (213) * PR 211 - PR: Fix issues when running our test suite in Azure, by @ccordoba12 * PR 210 - PR: Generate logging files with Spyder's debug level, by @steff456 (206) * PR 208 - Bump websocket-extensions from 0.1.3 to 0.1.4, by @dependabot[bot] * PR 204 - Bump jquery from 3.4.1 to 3.5.0, by @dependabot[bot] OBS-URL: https://build.opensuse.org/request/show/830082 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-spyder-terminal?expand=0&rev=14
2020-08-28 07:53:40 +00:00
Requires: python-coloredlogs
Requires: python-requests
Requires: python-terminado >= 0.13.1
Accepting request 830082 from home:bnavigator:branches:devel:languages:python:numeric - Updated to Version 0.4.2 * PR 237 - PR: Add Xonsh to list of supported terminals in Unix and Windows, by @steff456 - Version 0.4.1 (2020/08/05) * Issue 235 - Plugin fails on Python 3.8 and Windows (PR 236 by @steff456) * PR 236 - PR: Add tornado patch for python 3.8 in windows, by @steff456 (235) - Version 0.4.0 (2020/07/21) * Issue 233 - Update translations * Issue 227 - Add option to set buffer limit (PR 228 by @steff456) * Issue 225 - Terminal error "ValueError: Invalid cookie 'cwd'" (PR 229 by @steff456) * Issue 224 - Add widget for find functionality in the terminal (PR 226 by @steff456) * Issue 219 - Remove QWebKit from the code (PR 221 by @steff456) * Issue 218 - Shortcuts are not appearing in the preferences pane (PR 222 by @steff456) * Issue 213 - Update to xterm.js latest version (PR 214 by @steff456) * Issue 212 - Migrate this plugin to Python 3 (PR 215 by @steff456) * Issue 206 - Correctly generate logging files (PR 210 by @steff456) * Issue 202 - Problems when highlight text on terminal (PR 216 by @steff456) * Issue 148 - How to increase/decrease size of font in terminal? (PR 217 by @steff456) * In this release 11 issues were closed. * PR 232 - New Crowdin updates, by @spyder-bot * PR 231 - PR: Update translation files, by @steff456 * PR 229 - PR: Percent encode/decode cwd to encode spaces and special characters, by @steff456 (225) * PR 228 - PR: Add scrollback option to the terminal, by @steff456 (227) * PR 226 - PR: Add find widget to the terminal, by @steff456 (224) * PR 223 - PR: Improve clipboard support in the terminal, by @steff456 * PR 222 - PR: Fix shortcuts to new API, by @steff456 (218) * PR 221 - PR: Remove deprecated QWebKit code, by @steff456 (219) * PR 217 - PR: Add option to zoom in/zoom out in the terminal, by @steff456 (148) * PR 216 - PR: Fix highlight text on the terminal, by @steff456 (202) * PR 215 - PR: Move Spyder-terminal plugin to Python 3, by @steff456 (212) * PR 214 - PR: Upgrade xterm to 4.7 release, by @steff456 (213) * PR 211 - PR: Fix issues when running our test suite in Azure, by @ccordoba12 * PR 210 - PR: Generate logging files with Spyder's debug level, by @steff456 (206) * PR 208 - Bump websocket-extensions from 0.1.3 to 0.1.4, by @dependabot[bot] * PR 204 - Bump jquery from 3.4.1 to 3.5.0, by @dependabot[bot] OBS-URL: https://build.opensuse.org/request/show/830082 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-spyder-terminal?expand=0&rev=14
2020-08-28 07:53:40 +00:00
Requires: python-tornado
Requires: spyder >= 5.2.1
# SECTION test requirements
BuildRequires: python3-coloredlogs
BuildRequires: python3-flaky
BuildRequires: python3-pytest
BuildRequires: python3-pytest-qt
BuildRequires: python3-pytest-timeout
BuildRequires: python3-pytest-xvfb
BuildRequires: python3-requests
BuildRequires: python3-terminado >= 0.13.1
BuildRequires: python3-tornado
BuildRequires: spyder >= 5.2.1
BuildRequires: xdpyinfo
# /SECTION
Accepting request 830082 from home:bnavigator:branches:devel:languages:python:numeric - Updated to Version 0.4.2 * PR 237 - PR: Add Xonsh to list of supported terminals in Unix and Windows, by @steff456 - Version 0.4.1 (2020/08/05) * Issue 235 - Plugin fails on Python 3.8 and Windows (PR 236 by @steff456) * PR 236 - PR: Add tornado patch for python 3.8 in windows, by @steff456 (235) - Version 0.4.0 (2020/07/21) * Issue 233 - Update translations * Issue 227 - Add option to set buffer limit (PR 228 by @steff456) * Issue 225 - Terminal error "ValueError: Invalid cookie 'cwd'" (PR 229 by @steff456) * Issue 224 - Add widget for find functionality in the terminal (PR 226 by @steff456) * Issue 219 - Remove QWebKit from the code (PR 221 by @steff456) * Issue 218 - Shortcuts are not appearing in the preferences pane (PR 222 by @steff456) * Issue 213 - Update to xterm.js latest version (PR 214 by @steff456) * Issue 212 - Migrate this plugin to Python 3 (PR 215 by @steff456) * Issue 206 - Correctly generate logging files (PR 210 by @steff456) * Issue 202 - Problems when highlight text on terminal (PR 216 by @steff456) * Issue 148 - How to increase/decrease size of font in terminal? (PR 217 by @steff456) * In this release 11 issues were closed. * PR 232 - New Crowdin updates, by @spyder-bot * PR 231 - PR: Update translation files, by @steff456 * PR 229 - PR: Percent encode/decode cwd to encode spaces and special characters, by @steff456 (225) * PR 228 - PR: Add scrollback option to the terminal, by @steff456 (227) * PR 226 - PR: Add find widget to the terminal, by @steff456 (224) * PR 223 - PR: Improve clipboard support in the terminal, by @steff456 * PR 222 - PR: Fix shortcuts to new API, by @steff456 (218) * PR 221 - PR: Remove deprecated QWebKit code, by @steff456 (219) * PR 217 - PR: Add option to zoom in/zoom out in the terminal, by @steff456 (148) * PR 216 - PR: Fix highlight text on the terminal, by @steff456 (202) * PR 215 - PR: Move Spyder-terminal plugin to Python 3, by @steff456 (212) * PR 214 - PR: Upgrade xterm to 4.7 release, by @steff456 (213) * PR 211 - PR: Fix issues when running our test suite in Azure, by @ccordoba12 * PR 210 - PR: Generate logging files with Spyder's debug level, by @steff456 (206) * PR 208 - Bump websocket-extensions from 0.1.3 to 0.1.4, by @dependabot[bot] * PR 204 - Bump jquery from 3.4.1 to 3.5.0, by @dependabot[bot] OBS-URL: https://build.opensuse.org/request/show/830082 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-spyder-terminal?expand=0&rev=14
2020-08-28 07:53:40 +00:00
BuildArch: noarch
Provides: spyder-terminal = %{version}-%{release}
Obsoletes: spyder-terminal < %{version}-%{release}
Provides: spyder3-terminal = %{version}-%{release}
Obsoletes: spyder3-terminal < %{version}-%{release}
%python_subpackages
%description
Spyder, the Scientific Python Development Environment, is an
IDE for researchers, engineers and data analysts.
This package contains the plugin for displaying a virtual terminal
(OS independent) inside the main Spyder window. It uses a nodejs
backend.
%prep
%setup -q -n spyder-terminal-%{version}
Accepting request 830082 from home:bnavigator:branches:devel:languages:python:numeric - Updated to Version 0.4.2 * PR 237 - PR: Add Xonsh to list of supported terminals in Unix and Windows, by @steff456 - Version 0.4.1 (2020/08/05) * Issue 235 - Plugin fails on Python 3.8 and Windows (PR 236 by @steff456) * PR 236 - PR: Add tornado patch for python 3.8 in windows, by @steff456 (235) - Version 0.4.0 (2020/07/21) * Issue 233 - Update translations * Issue 227 - Add option to set buffer limit (PR 228 by @steff456) * Issue 225 - Terminal error "ValueError: Invalid cookie 'cwd'" (PR 229 by @steff456) * Issue 224 - Add widget for find functionality in the terminal (PR 226 by @steff456) * Issue 219 - Remove QWebKit from the code (PR 221 by @steff456) * Issue 218 - Shortcuts are not appearing in the preferences pane (PR 222 by @steff456) * Issue 213 - Update to xterm.js latest version (PR 214 by @steff456) * Issue 212 - Migrate this plugin to Python 3 (PR 215 by @steff456) * Issue 206 - Correctly generate logging files (PR 210 by @steff456) * Issue 202 - Problems when highlight text on terminal (PR 216 by @steff456) * Issue 148 - How to increase/decrease size of font in terminal? (PR 217 by @steff456) * In this release 11 issues were closed. * PR 232 - New Crowdin updates, by @spyder-bot * PR 231 - PR: Update translation files, by @steff456 * PR 229 - PR: Percent encode/decode cwd to encode spaces and special characters, by @steff456 (225) * PR 228 - PR: Add scrollback option to the terminal, by @steff456 (227) * PR 226 - PR: Add find widget to the terminal, by @steff456 (224) * PR 223 - PR: Improve clipboard support in the terminal, by @steff456 * PR 222 - PR: Fix shortcuts to new API, by @steff456 (218) * PR 221 - PR: Remove deprecated QWebKit code, by @steff456 (219) * PR 217 - PR: Add option to zoom in/zoom out in the terminal, by @steff456 (148) * PR 216 - PR: Fix highlight text on the terminal, by @steff456 (202) * PR 215 - PR: Move Spyder-terminal plugin to Python 3, by @steff456 (212) * PR 214 - PR: Upgrade xterm to 4.7 release, by @steff456 (213) * PR 211 - PR: Fix issues when running our test suite in Azure, by @ccordoba12 * PR 210 - PR: Generate logging files with Spyder's debug level, by @steff456 (206) * PR 208 - Bump websocket-extensions from 0.1.3 to 0.1.4, by @dependabot[bot] * PR 204 - Bump jquery from 3.4.1 to 3.5.0, by @dependabot[bot] OBS-URL: https://build.opensuse.org/request/show/830082 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-spyder-terminal?expand=0&rev=14
2020-08-28 07:53:40 +00:00
tar --strip-components=1 -xzf %{SOURCE1} \
spyder-terminal-%{version}/conftest.py \
spyder-terminal-%{version}/spyder_terminal/tests \
spyder-terminal-%{version}/spyder_terminal/server/tests
%autopatch -p1
# fix rpmlint non-executable-script
sed -i -e '/^#!\//, 1d' spyder_terminal/server/__main__.py
sed -i -e '/^#!\//, 1d' spyder_terminal/server/tests/print_size.py
# fix error with qtbot >= 4
sed -i 's/qtbot_module.addWidget(terminal)/qtbot_module.addWidget(terminal.get_widget())/' spyder_terminal/tests/test_terminal.py
%build
%python3_build
%install
%python3_install
%find_lang spyder_terminal
find %{buildroot}%{python3_sitelib}/spyder_terminal/locale -name '*.po*' -delete
%fdupes %{buildroot}%{python3_sitelib}
%check
# The unittests fail with a seccomp-bpf crash if the sandbox
# is not disabled on i586
export QTWEBENGINE_DISABLE_SANDBOX=1
# qtbot timeout: "Doesn't work on Linux CIs"
donttest="test_terminal_paste"
# no conda
donttest+=" or test_conda_path"
%pytest -k "not ($donttest)" --timeout 120
%files %{python_files} -f spyder_terminal.lang
%defattr(-,root,root,-)
%doc CHANGELOG.md README.rst
%license LICENSE.txt
%dir %{python_sitelib}/spyder_terminal
%{python_sitelib}/spyder_terminal/{*.py*,server,widgets}
%{python_sitelib}/spyder_terminal/__pycache__/
%dir %{python_sitelib}/spyder_terminal/locale
%dir %{python_sitelib}/spyder_terminal/locale/*
%dir %{python_sitelib}/spyder_terminal/locale/*/LC_MESSAGES
%exclude %{python_sitelib}/spyder_terminal/tests
%exclude %{python_sitelib}/spyder_terminal/server/tests
%{python_sitelib}/spyder_terminal-%{version}*-info
%changelog