From d13b26c9fb89beebe9ff9e9dfc86ba8ddb8d01cd Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sat, 24 Jan 2015 11:05:13 -0800 Subject: [PATCH] swc-installation-test-2.py: Add minimum browser requirements for IPython MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit IPython notebooks (at least for version 1.2.1 [1], 2.3.0 [2], and 3.0.0 [3]) have the following minimum browser requirements: Chrome ≥ 13 Safari ≥ 5 Firefox ≥ 6 Due to the notebook's usage of WebSockets and the flexible box model [1,2,3]. This commit ensures that folks requiring IPython have a notebook-compatible browser. We don't actually check the Safari version, because I'm not sure what the appropriate command-line switch is to get it to print version information. [1]: http://ipython.org/ipython-doc/1/install/install.html#browser-compatibility [2]: http://ipython.org/ipython-doc/2/install/install.html#browser-compatibility [3]: http://ipython.org/ipython-doc/dev/install/install.html#browser-compatibility --- swc-installation-test-2.py | 43 +++++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/swc-installation-test-2.py b/swc-installation-test-2.py index 5d794c7..16532ff 100755 --- a/swc-installation-test-2.py +++ b/swc-installation-test-2.py @@ -775,7 +775,48 @@ for package,name,long_name,minimum_version,and_dependencies in [ ('jinja2', 'jinja', 'Jinja', (2, 6), None), ('zmq', 'pyzmq', 'PyZMQ', (2, 1, 4), None), ('IPython', None, 'IPython Python package', - CHECKER['ipython'].minimum_version, ['jinja', 'tornado', 'pyzmq']), + CHECKER['ipython'].minimum_version, [ + 'jinja', + 'tornado', + 'pyzmq', + VirtualDependency( + name='virtual-browser-ipython', + long_name='IPython-compatible web browser', + or_dependencies=[ + CommandDependency( + command=CHECKER['firefox'].command, + paths=CHECKER['firefox'].paths, + name='{0}-for-ipython'.format( + CHECKER['firefox'].name), + long_name='{0} for IPython'.format( + CHECKER['firefox'].long_name), + minimum_version=(6, 0)), + CommandDependency( + command=CHECKER['google-chrome'].command, + paths=CHECKER['google-chrome'].paths, + name='{0}-for-ipython'.format( + CHECKER['google-chrome'].name), + long_name='{0} for IPython'.format( + CHECKER['google-chrome'].long_name), + minimum_version=(13, 0)), + CommandDependency( + command=CHECKER['chromium'].command, + paths=CHECKER['chromium'].paths, + name='{0}-for-ipython'.format( + CHECKER['chromium'].name), + long_name='{0} for IPython'.format( + CHECKER['chromium'].long_name), + minimum_version=(13, 0)), + PathCommandDependency( + command=CHECKER['safari'].command, + paths=CHECKER['safari'].paths, + name='{0}-for-ipython'.format( + CHECKER['safari'].name), + long_name='{0} for IPython'.format( + CHECKER['safari'].long_name), + minimum_version=(5, 0)), + ]), + ]), ('argparse', None, 'Argparse', None, None), ('numpy', None, 'NumPy', None, None), ('scipy', None, 'SciPy', None, None), -- 2.26.2