jupyter-2.7 vs. ipython

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

jupyter-2.7 vs. ipython

Robert Goldman

I can't tell if this is a bug in MacPorts, or if I have simply misconfigured something.

When I start up ipython notebook, with python-2.7 as my selected python, everything works fine, but I get a complaint echoed to the shell:

[TerminalIPythonApp] WARNING | Subcommand `ipython notebook` is deprecated and will be removed in future versions.
[TerminalIPythonApp] WARNING | You likely want to use `jupyter notebook` in the future

All works well, nevertheless, and I'm happy, except for the crabby note from ipython.

But, if I try to do what the message says, and run jupyter notebook instead, I get an error:

$ jupyter-2.7 notebook
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin/jupyter-notebook", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3195, in <module>
    @_call_aside
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3179, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3208, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 681, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 999, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 885, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'futures' distribution was not found and is required by tornado

So I was wondering if there's an issue with jupyter or, if somehow I've gotten things misconfigured.

Thanks

Reply | Threaded
Open this post in threaded view
|

Re: jupyter-2.7 vs. ipython

Marius Schamschula-3
I just posted a ticket for this very issue: https://trac.macports.org/ticket/56111

On Mar 20, 2018, at 1:19 PM, Robert Goldman <[hidden email]> wrote:

I can't tell if this is a bug in MacPorts, or if I have simply misconfigured something.

When I start up ipython notebook, with python-2.7 as my selected python, everything works fine, but I get a complaint echoed to the shell:

[TerminalIPythonApp] WARNING | Subcommand `ipython notebook` is deprecated and will be removed in future versions.
[TerminalIPythonApp] WARNING | You likely want to use `jupyter notebook` in the future

All works well, nevertheless, and I'm happy, except for the crabby note from ipython.

But, if I try to do what the message says, and run jupyter notebook instead, I get an error:

$ jupyter-2.7 notebook
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin/jupyter-notebook", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3195, in <module>
    @_call_aside
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3179, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3208, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 681, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 999, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 885, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'futures' distribution was not found and is required by tornado

So I was wondering if there's an issue with jupyter or, if somehow I've gotten things misconfigured.

Thanks


Marius
--
Marius Schamschula



Reply | Threaded
Open this post in threaded view
|

Re: jupyter-2.7 vs. ipython

Nathan Brazil-2
In my experience, “jupyter notebook” is the correct startup command.  Here is what I do, using Python 2.7:
  1. Install pyenv (https://github.com/pyenv/pyenv)
  2. pyenv install 2.7.14
  3. sudo port install py27-virtualenv
  4. mkdir jupyter
  5. cd jupyter
  6. pyenv virtualenv 2.7.14 jupyter
  7. echo "jupyter" > .python-version
  8. pip install jupyter
  9. jupyter notebook


On Mar 20, 2018, at 11:27 AM, Marius Schamschula <[hidden email]> wrote:

I just posted a ticket for this very issue: https://trac.macports.org/ticket/56111

On Mar 20, 2018, at 1:19 PM, Robert Goldman <[hidden email]> wrote:

I can't tell if this is a bug in MacPorts, or if I have simply misconfigured something.

When I start up ipython notebook, with python-2.7 as my selected python, everything works fine, but I get a complaint echoed to the shell:

[TerminalIPythonApp] WARNING | Subcommand `ipython notebook` is deprecated and will be removed in future versions.
[TerminalIPythonApp] WARNING | You likely want to use `jupyter notebook` in the future

All works well, nevertheless, and I'm happy, except for the crabby note from ipython.

But, if I try to do what the message says, and run jupyter notebook instead, I get an error:

$ jupyter-2.7 notebook
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin/jupyter-notebook", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3195, in <module>
    @_call_aside
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3179, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3208, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 681, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 999, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 885, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'futures' distribution was not found and is required by tornado

So I was wondering if there's an issue with jupyter or, if somehow I've gotten things misconfigured.

Thanks


Marius
--
Marius Schamschula




Reply | Threaded
Open this post in threaded view
|

Re: jupyter-2.7 vs. ipython

pagani laurent via macports-users
In reply to this post by Marius Schamschula-3
Marius,

I just installed py27-jupyter today, checked the py27-future presence but it crashes in a similar way to what Bob reported below :

  py27-futures @3.2.0_0 (active)
  py27-tornado @5.0.1_1 (active)

NICER>jupyter-2.7 notebook
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin/jupyter-notebook", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3195, in <module>
    @_call_aside
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3179, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3208, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 681, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 999, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 885, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'testpath' distribution was not found and is required by nbconvert

What’s wrong ?

Thanks
Laurent

Le 20 mars 2018 à 19:27, Marius Schamschula <[hidden email]> a écrit :

I just posted a ticket for this very issue: https://trac.macports.org/ticket/56111

On Mar 20, 2018, at 1:19 PM, Robert Goldman <[hidden email]> wrote:

I can't tell if this is a bug in MacPorts, or if I have simply misconfigured something.

When I start up ipython notebook, with python-2.7 as my selected python, everything works fine, but I get a complaint echoed to the shell:

[TerminalIPythonApp] WARNING | Subcommand `ipython notebook` is deprecated and will be removed in future versions.
[TerminalIPythonApp] WARNING | You likely want to use `jupyter notebook` in the future

All works well, nevertheless, and I'm happy, except for the crabby note from ipython.

But, if I try to do what the message says, and run jupyter notebook instead, I get an error:

$ jupyter-2.7 notebook
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/bin/jupyter-notebook", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3195, in <module>
    @_call_aside
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3179, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3208, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 681, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 999, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 885, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'futures' distribution was not found and is required by tornado

So I was wondering if there's an issue with jupyter or, if somehow I've gotten things misconfigured.

Thanks


Marius
--
Marius Schamschula




"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème" (devise Shadok)

Reply | Threaded
Open this post in threaded view
|

Re: jupyter-2.7 vs. ipython

Ken Cunningham

On 2018-03-21, at 11:49 PM, pagani laurent via macports-users wrote:

pkg_resources.DistributionNotFound: The 'testpath' distribution was not found and is required by nbconvert


Looks like you should install py27-testpath and see if that fixes it.

Best,

Ken
Reply | Threaded
Open this post in threaded view
|

Re: jupyter-2.7 vs. ipython

pagani laurent via macports-users
Nope.

The following ports are currently installed:
  py27-terminado @0.8.1_0 (active)
  py27-testpath @0.3.1_0 (active)
  py27-tkinter @2.7.14_0 (active)
  py27-toolz @0.9.0_0 (active)
  py27-tornado @4.5.2_0
  py27-tornado @5.0.1_1 (active)
  py27-traitlets @4.3.2_0 (active)
  py27-typing @3.6.2_0 (active)
  py27-tz @2018.3_0 (active)

and the message is still the same.

Laurent

Le 22 mars 2018 à 07:33, Kenneth F. Cunningham <[hidden email]> a écrit :


On 2018-03-21, at 11:49 PM, pagani laurent via macports-users wrote:

pkg_resources.DistributionNotFound: The 'testpath' distribution was not found and is required by nbconvert


Looks like you should install py27-testpath and see if that fixes it.

Best,

Ken

"S'il n'y a pas de solution, c'est qu'il n'y a pas de problème" (devise Shadok)