Hello community,
here is the log from the commit of package python-spyder-notebook for
openSUSE:Factory checked in at 2020-09-27 11:50:08
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-spyder-notebook (Old)
and /work/SRC/openSUSE:Factory/.python-spyder-notebook.new.4249 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-spyder-notebook"
Sun Sep 27 11:50:08 2020 rev:7 rq:837845 version:0.3.0
Changes:
--------
---
/work/SRC/openSUSE:Factory/python-spyder-notebook/python-spyder-notebook.changes
2020-04-22 20:51:00.555159292 +0200
+++
/work/SRC/openSUSE:Factory/.python-spyder-notebook.new.4249/python-spyder-notebook.changes
2020-09-27 11:50:11.104069857 +0200
@@ -1,0 +2,28 @@
+Fri Sep 25 17:45:33 UTC 2020 - Benjamin Greiner <[email protected]>
+
+- Update to version 0.3.0
+ * The plugin now uses JupyterLab instead of Jupyter
+ Notebook to render notebooks. This ensures that the new
+ features developed by the Jupyter team, such as drag
+ and drop to reorder code cells, are available in
+ Spyder.
+ * Support for Python 2 is dropped. The plugin now
+ requires Python 3.5 and Spyder 3.1 or later.
+ * Notebooks are rendered in a dark theme if Spyder is
+ run using a dark theme.
+ * A new item, "Server Info", in the option menu of the
+ plugin. This should help with troubleshooting in case
+ of problems.
+ * Translations for Brazilian Portuguese, German and
+ Spanish are now available.
+ * When you open Spyder, the plugin will open the
+ notebooks that were open when you last quit Spyder.
+- For a full list of 16 issues closed and 13 PRs merged see
+ https://github.com/spyder-ide/spyder-notebook/blob/master/CHANGELOG.md
+- Tag lang files
+- Get tests from Github archive because the unit tests are not
+ packaged on PyPI anymore (but we need the JS stuff from PyPI)
+- gh#pytest-dev/pytest-qt#319 patch against qtwebengine segfault
+ spyder-notebook-destroyqtwidgets.patch
+
+-------------------------------------------------------------------
Old:
----
spyder-notebook-0.2.3.tar.gz
New:
----
spyder-notebook-0.3.0-gh.tar.gz
spyder-notebook-0.3.0.tar.gz
spyder-notebook-destroyqtwidgets.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-spyder-notebook.spec ++++++
--- /var/tmp/diff_new_pack.moEWun/_old 2020-09-27 11:50:13.840072805 +0200
+++ /var/tmp/diff_new_pack.moEWun/_new 2020-09-27 11:50:13.844072809 +0200
@@ -19,35 +19,43 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-spyder-notebook
-Version: 0.2.3
+Version: 0.3.0
Release: 0
Summary: Jupyter notebook integration with Spyder
License: MIT
Group: Development/Languages/Python
URL: https://github.com/spyder-ide/spyder-notebook
-Source:
https://files.pythonhosted.org/packages/source/s/spyder-notebook/spyder-notebook-%{version}.tar.gz
+# We need the bundled JavaScript stuff from the PyPI archive ...
+Source0:
https://files.pythonhosted.org/packages/source/s/spyder-notebook/spyder-notebook-%{version}.tar.gz
+# ... but only the GitHub archive provides the unit tests
+Source1:
https://github.com/spyder-ide/spyder-notebook/archive/v%{version}.tar.gz#/spyder-notebook-%{version}-gh.tar.gz
+# PATCH-FIX-OPENSUSE https://github.com/pytest-dev/pytest-qt/issues/319
+Patch0: spyder-notebook-destroyqtwidgets.patch
Requires: python-QtPy
Requires: python-nbformat
Requires: python-notebook >= 4.3
Requires: python-psutil
Requires: python-requests
-Requires: spyder >= 4
+Requires: spyder >= 4.1
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
# SECTION test requirements
+BuildRequires: %{python_module QtPy}
BuildRequires: %{python_module flaky}
BuildRequires: %{python_module nbformat}
BuildRequires: %{python_module notebook}
+BuildRequires: %{python_module opengl}
BuildRequires: %{python_module psutil}
BuildRequires: %{python_module pytest-mock}
BuildRequires: %{python_module pytest-qt}
BuildRequires: %{python_module pytest-xvfb}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module requests}
-BuildRequires: spyder >= 4
+BuildRequires: spyder >= 4.1
BuildRequires: xdpyinfo
# /SECTION
+BuildArch: noarch
%python_subpackages
%description
@@ -72,28 +80,45 @@
%prep
%setup -q -n spyder-notebook-%{version}
+tar --strip-components=1 -xzf %{SOURCE1} \
+ spyder-notebook-%{version}/spyder_notebook/server/test.ipynb \
+ spyder-notebook-%{version}/spyder_notebook/tests \
+ spyder-notebook-%{version}/spyder_notebook/utils/tests \
+ spyder-notebook-%{version}/spyder_notebook/widgets/tests
+%patch0 -p1
sed -i 's/\r$//' CHANGELOG.md README.md
+chmod -x spyder_notebook/utils/templates/welcome-dark.html
%build
%python_build
%install
%python_install
-%python_expand %fdupes %{buildroot}%{$python_sitelib}
+%{python_expand # tag language files and deduplicate
+%find_lang spyder_notebook
+mv spyder_notebook.lang spyder_notebook-%{$python_bin_suffix}.lang
+%fdupes %{buildroot}%{$python_sitelib}
+}
%check
# The unittests fail with a seccomp-bpf crash if the sandbox
# is not disabled on i586
-%ifarch %ix86
export QTWEBENGINE_DISABLE_SANDBOX=1
-%endif
-export PYTHONDONTWRITEBYTECODE=1
-%pytest
+# test_plugin::test_shutdown_notebook_kernel: session request is always empty
+# rest of deselcted test_plugin tests: passing but produces XIO errors with
xvfb at the end
+%pytest -k "not (test_plugin and (shutdown or register or close or save))"
-%files -n spyder-notebook
+# Caution: Package name is not singlespec ready
+%files -n spyder-notebook -f spyder_notebook-%{python_bin_suffix}.lang
%doc CHANGELOG.md README.md
%license LICENSE
-%{python_sitelib}/spyder_notebook
+%dir %{python_sitelib}/spyder_notebook
+%dir %{python_sitelib}/spyder_notebook/locale
+%dir %{python_sitelib}/spyder_notebook/locale/*
+%dir %{python_sitelib}/spyder_notebook/locale/*/LC_MESSAGES
+%{python_sitelib}/spyder_notebook/*.py
+%{python_sitelib}/spyder_notebook/{images,server,utils,widgets}
+%pycache_only %{python_sitelib}/spyder_notebook/__pycache__
%{python_sitelib}/spyder_notebook-%{version}-py*.egg-info
%changelog
++++++ spyder-notebook-0.2.3.tar.gz -> spyder-notebook-0.3.0.tar.gz ++++++
++++ 7877 lines of diff (skipped)
++++++ spyder-notebook-destroyqtwidgets.patch ++++++
diff --git a/spyder_notebook/tests/test_plugin.py
b/spyder_notebook/tests/test_plugin.py
index c6c54d4..91320fa 100644
--- a/spyder_notebook/tests/test_plugin.py
+++ b/spyder_notebook/tests/test_plugin.py
@@ -21,6 +21,7 @@ import requests
from qtpy.QtWebEngineWidgets import WEBENGINE
from qtpy.QtCore import Qt, QTimer
from qtpy.QtWidgets import QFileDialog, QApplication, QLineEdit
+from PyQt5 import sip
# Local imports
from spyder_notebook.notebookplugin import NotebookPlugin
@@ -97,6 +98,7 @@ def notebook(qtbot):
notebook_plugin.create_new_client()
yield notebook_plugin
notebook_plugin.closing_plugin()
+ sip.delete(notebook_plugin)
@pytest.fixture
@@ -114,6 +116,7 @@ def plugin_no_server(mocker, qtbot):
qtbot.addWidget(plugin)
yield plugin
plugin.closing_plugin()
+ sip.delete(plugin)
# =============================================================================
# Tests
diff --git a/spyder_notebook/widgets/tests/test_client.py
b/spyder_notebook/widgets/tests/test_client.py
index 8b26e19..9780b25 100644
--- a/spyder_notebook/widgets/tests/test_client.py
+++ b/spyder_notebook/widgets/tests/test_client.py
@@ -9,6 +9,7 @@
import pytest
from qtpy.QtWidgets import QWidget
import requests
+from PyQt5 import sip
# Local imports
from spyder_notebook.widgets.client import NotebookClient
@@ -18,6 +19,7 @@ class MockPlugin(QWidget):
def get_plugin_actions(self):
return []
+
@pytest.fixture
def plugin(qtbot):
"""
@@ -33,7 +35,8 @@ def plugin(qtbot):
'url': 'fake_url',
'token': 'fake_token'}
client.register(server_info)
- return plugin
+ yield plugin
+ sip.delete(plugin)
def test_notebookclient_get_kernel_id(plugin, mocker):
diff --git a/spyder_notebook/widgets/tests/test_notebooktabwidget.py
b/spyder_notebook/widgets/tests/test_notebooktabwidget.py
index 8425934..ef5b1e7 100755
--- a/spyder_notebook/widgets/tests/test_notebooktabwidget.py
+++ b/spyder_notebook/widgets/tests/test_notebooktabwidget.py
@@ -11,6 +11,7 @@ import os.path as osp
# Third party imports
import pytest
+from PyQt5 import sip
# Local imports
from spyder_notebook.utils.servermanager import ServerManager
@@ -27,7 +28,8 @@ def tabwidget(mocker, qtbot):
spec=ServerManager, get_server=fake_get_server)
widget = NotebookTabWidget(None, fake_server_manager)
qtbot.addWidget(widget)
- return widget
+ yield widget
+ sip.delete(widget)
def test_is_newly_created_with_new_notebook(tabwidget):