From 0d6a518aeb8ea1e47da4575d85f83a71e3d271fc Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Thu, 23 Jun 2016 18:12:08 -0500 Subject: [PATCH 1/4] Increase minimal Pygments version to 2.0 Spyder doesn't work now with the 1.x series --- README.md | 4 ++-- conda.recipe/meta.yaml | 4 ++-- setup.py | 2 +- spyderlib/utils/syntaxhighlighters.py | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 65a81b3972a..2f3891e1aaa 100644 --- a/README.md +++ b/README.md @@ -144,7 +144,7 @@ a Python version greater than 2.7 (Python 3.2 is not supported anymore). and go-to-definition. * **Pyflakes**: Real-time code analysis. * **Sphinx**: Rich text mode for the Help pane. -* **Pygments**: Syntax highlighting for all file types it supports. +* **Pygments** 2.0+: Syntax highlighting for all file types it supports. * **Pylint**: Static code analysis. * **Pep8**: Style analysis. * **Psutil**: CPU and memory usage on the status bar. @@ -152,7 +152,7 @@ a Python version greater than 2.7 (Python 3.2 is not supported anymore). * **Qtawesome**: To have an icon theme based on FontAwesome. * **Pickleshare**: Show import completions on the Python consoles. * **PyZMQ**: Run introspection services asynchronously. -* **QtPy**: Abstracion layer for Python Qt bindings so that Spyder can run on PyQt4 +* **QtPy** 1.0.2+: Abstracion layer for Python Qt bindings so that Spyder can run on PyQt4 and PyQt5. ### Optional dependencies diff --git a/conda.recipe/meta.yaml b/conda.recipe/meta.yaml index dce81a08a6f..df04a98294c 100644 --- a/conda.recipe/meta.yaml +++ b/conda.recipe/meta.yaml @@ -24,13 +24,13 @@ requirements: - jedi - qtconsole - nbconvert - - pygments + - pygments >=2.0 - sphinx - pep8 - psutil - pylint - qtawesome - - qtpy >=1.0.2 + - qtpy >=1.0.2 - pyzmq about: diff --git a/setup.py b/setup.py index 0a365d7f18a..e64b47febac 100644 --- a/setup.py +++ b/setup.py @@ -266,7 +266,7 @@ def run(self): 'rope_py3k' if PY3 else 'rope>=0.9.4', 'jedi', 'pyflakes', - 'pygments', + 'pygments>=2.0', 'qtconsole', 'nbconvert', 'sphinx', diff --git a/spyderlib/utils/syntaxhighlighters.py b/spyderlib/utils/syntaxhighlighters.py index 3c23edd6163..79101c2d2f2 100644 --- a/spyderlib/utils/syntaxhighlighters.py +++ b/spyderlib/utils/syntaxhighlighters.py @@ -29,7 +29,7 @@ from spyderlib.utils.sourcecode import CELL_LANGUAGES -PYGMENTS_REQVER = '>=1.6' +PYGMENTS_REQVER = '>=2.0' dependencies.add("pygments", _("Syntax highlighting for Matlab, Julia and " "other file types"), required_version=PYGMENTS_REQVER) From 3f1b31ee4456dc247c9650c5ecf89319bcc03bd1 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Thu, 23 Jun 2016 18:19:40 -0500 Subject: [PATCH 2/4] IPython Console: Don't use default_gui_banner because it'll be deprecated since IPython 5.0 --- spyderlib/widgets/ipython.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/spyderlib/widgets/ipython.py b/spyderlib/widgets/ipython.py index 4ac11e6980f..f5083a69deb 100644 --- a/spyderlib/widgets/ipython.py +++ b/spyderlib/widgets/ipython.py @@ -198,12 +198,12 @@ def set_ipyclient(self, ipyclient): """Bind this shell widget to an IPython client one""" self.ipyclient = ipyclient self.exit_requested.connect(ipyclient.exit_callback) - + def long_banner(self): """Banner for IPython widgets with pylab message""" - from IPython.core.usage import default_gui_banner - banner = default_gui_banner - + from IPython.core.usage import default_banner + banner = default_banner + pylab_o = CONF.get('ipython_console', 'pylab', True) autoload_pylab_o = CONF.get('ipython_console', 'pylab/autoload', True) mpl_installed = programs.is_module_installed('matplotlib') From 19ad9746b48b3c899533be38fb73a9af941801c1 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Thu, 23 Jun 2016 18:27:40 -0500 Subject: [PATCH 3/4] IPython Console: Don't use gui_reference from IPython because it's deprecated - We now use it from qtconsole, which requires qtconsole 4.2.0+ --- README.md | 2 +- conda.recipe/meta.yaml | 2 +- setup.py | 2 +- spyderlib/plugins/ipythonconsole.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2f3891e1aaa..4e3fdd2d68f 100644 --- a/README.md +++ b/README.md @@ -139,7 +139,7 @@ a Python version greater than 2.7 (Python 3.2 is not supported anymore). * **Python** 2.7 or 3.3+ * **PyQt5** 5.2+ or **PyQt4** 4.6+: PyQt5 is recommended. -* **qtconsole**: Enhanced Python interpreter. +* **qtconsole** 4.2.0+: Enhanced Python interpreter. * **Rope** and **Jedi**: Editor code completion, calltips and go-to-definition. * **Pyflakes**: Real-time code analysis. diff --git a/conda.recipe/meta.yaml b/conda.recipe/meta.yaml index df04a98294c..2b269167664 100644 --- a/conda.recipe/meta.yaml +++ b/conda.recipe/meta.yaml @@ -22,7 +22,7 @@ requirements: - rope # [py27] - pyflakes - jedi - - qtconsole + - qtconsole >=4.2.0 - nbconvert - pygments >=2.0 - sphinx diff --git a/setup.py b/setup.py index e64b47febac..914308ed9b9 100644 --- a/setup.py +++ b/setup.py @@ -267,7 +267,7 @@ def run(self): 'jedi', 'pyflakes', 'pygments>=2.0', - 'qtconsole', + 'qtconsole>=4.2.0', 'nbconvert', 'sphinx', 'pep8', diff --git a/spyderlib/plugins/ipythonconsole.py b/spyderlib/plugins/ipythonconsole.py index b5a155f53d5..88cc8c57719 100644 --- a/spyderlib/plugins/ipythonconsole.py +++ b/spyderlib/plugins/ipythonconsole.py @@ -1194,7 +1194,7 @@ def show_intro(self): @Slot() def show_guiref(self): """Show qtconsole help""" - from IPython.core.usage import gui_reference + from qtconsole.usage import gui_reference self.help.show_rich_text(gui_reference, collapse=True) @Slot() From f6b6e13216530974f263960c1e7aa414d8868db3 Mon Sep 17 00:00:00 2001 From: Carlos Cordoba Date: Thu, 23 Jun 2016 18:33:01 -0500 Subject: [PATCH 4/4] Docs: Update minimal required versions of our deps --- doc/installation.rst | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/doc/installation.rst b/doc/installation.rst index bd838352752..e143782db02 100644 --- a/doc/installation.rst +++ b/doc/installation.rst @@ -157,7 +157,7 @@ The requirements to run Spyder are: `PyQt4 `_ >=4.6.0 (PyQt5 is recommended). -* `Qtconsole `_ >=4.0 -- for an +* `Qtconsole `_ >=4.2.0 -- for an enhanced Python interpreter. * `Rope `_ >=0.9.4 and @@ -170,8 +170,8 @@ The requirements to run Spyder are: * `Sphinx `_ -- for the Help pane rich text mode and to get our documentation. -* `Pygments `_ -- for syntax highlighting in the Editor of - all file types it supports. +* `Pygments `_ >=2.0 -- for syntax highlighting and code + completion in the Editor of all file types it supports. * `Pylint `_ -- for static code analysis. @@ -191,22 +191,23 @@ The requirements to run Spyder are: * `PyZMQ `_ -- To run introspection services on the Editor asynchronously. -* `QtPy `_ -- To run Spyder in PyQt4 and PyQt5. +* `QtPy `_ >=1.0.2 -- To run Spyder in PyQt4 and + PyQt5. Optional modules ~~~~~~~~~~~~~~~~ -* `Matplotlib `_ -- for 2D and 3D plotting in - the consoles. +* `Matplotlib `_ >=1.0 -- for 2D and 3D plotting + in the consoles. -* `Pandas `_ -- for view and editing DataFrames and - Series in the Variable Explorer. +* `Pandas `_ >=0.13.1 -- for view and editing DataFrames + and Series in the Variable Explorer. * `Numpy `_ -- for view and editing two or three dimensional arrays in the Variable Explorer. -* `Sympy `_ -- for working with symbolic mathematics +* `Sympy `_ >=0.7.3 -- for working with symbolic mathematics in the IPython console. * `Scipy `_ -- for importing Matlab workspace files in