Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jupyter-client v6.1.13 breaks qtconsole #476

Open
carlosperate opened this issue Apr 7, 2021 · 1 comment
Open

jupyter-client v6.1.13 breaks qtconsole #476

carlosperate opened this issue Apr 7, 2021 · 1 comment

Comments

@carlosperate
Copy link

I've reported this in the jupyter-client repository as well, as it looks like a breaking change in a patch release (not sure if the project using semver though). This might be a wrong assumption, so it's worth reporting here as well for visibility: jupyter/jupyter_client#635

Can be replicated using the latest qtconsole 5.0.3, which by default installs the latest jupyter-client:

$ pip install qtconsole PyQt5
...

$ pip list
Package          Version
---------------- -------
appnope          0.1.2
backcall         0.2.0
decorator        5.0.5
ipykernel        5.5.3
ipython          7.16.1
ipython-genutils 0.2.0
jedi             0.18.0
jupyter-client   6.1.13
jupyter-core     4.7.1
nest-asyncio     1.5.1
parso            0.8.2
pexpect          4.8.0
pickleshare      0.7.5
pip              21.0.1
prompt-toolkit   3.0.18
ptyprocess       0.7.0
Pygments         2.8.1
PyQt5            5.15.4
PyQt5-Qt5        5.15.2
PyQt5-sip        12.8.1
python-dateutil  2.8.1
pyzmq            22.0.3
qtconsole        5.0.3
QtPy             1.9.0
setuptools       54.2.0
six              1.15.0
tornado          6.1
traitlets        4.3.3
wcwidth          0.2.5
wheel            0.36.2

$ jupyter qtconsole
Traceback (most recent call last):
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/bin/jupyter-qtconsole", line 8, in <module>
    sys.exit(main())
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/qtconsole/qtconsoleapp.py", line 462, in main
    JupyterQtConsoleApp.launch_instance()
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_core/application.py", line 254, in launch_instance
    return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/traitlets/config/application.py", line 663, in launch_instance
    app.initialize(argv)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/decorator.py", line 232, in fun
    return caller(func, *(extras + args), **kw)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/traitlets/config/application.py", line 87, in catch_config_error
    return method(app, *args, **kwargs)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/qtconsole/qtconsoleapp.py", line 432, in initialize
    JupyterConsoleApp.initialize(self,argv)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_client/consoleapp.py", line 366, in initialize
    self.init_kernel_client()
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_client/consoleapp.py", line 354, in init_kernel_client
    self.kernel_client.start_channels()
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/qtconsole/kernel_mixins.py", line 47, in start_channels
    super().start_channels(*args, **kw)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_client/threaded.py", line 248, in start_channels
    super().start_channels(shell, iopub, stdin, hb, control)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_client/client.py", line 295, in start_channels
    self.hb_channel.start()
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/jupyter_client/client.py", line 364, in hb_channel
    self._hb_channel = self.hb_channel_class(self.context, self.session, url)
  File "/Users/microbit-carlos/workspace/deleteme/really-delete/qtconsole/.venv/lib/python3.6/site-packages/qtconsole/util.py", line 64, in __new__
    QClass.__init__(inst)
TypeError: __init__() missing 1 required positional argument: 'context'

Reverting to 6.1.12 and it all works:

$ pip install jupyter-client==6.1.12
Collecting jupyter-client==6.1.12
  Using cached jupyter_client-6.1.12-py3-none-any.whl (112 kB)
Requirement already satisfied: tornado>=4.1 in ./.venv/lib/python3.6/site-packages (from jupyter-client==6.1.12) (6.1)
Requirement already satisfied: jupyter-core>=4.6.0 in ./.venv/lib/python3.6/site-packages (from jupyter-client==6.1.12) (4.7.1)
Requirement already satisfied: python-dateutil>=2.1 in ./.venv/lib/python3.6/site-packages (from jupyter-client==6.1.12) (2.8.1)
Requirement already satisfied: traitlets in ./.venv/lib/python3.6/site-packages (from jupyter-client==6.1.12) (4.3.3)
Requirement already satisfied: pyzmq>=13 in ./.venv/lib/python3.6/site-packages (from jupyter-client==6.1.12) (22.0.3)
Requirement already satisfied: six>=1.5 in ./.venv/lib/python3.6/site-packages (from python-dateutil>=2.1->jupyter-client==6.1.12) (1.15.0)
Requirement already satisfied: ipython-genutils in ./.venv/lib/python3.6/site-packages (from traitlets->jupyter-client==6.1.12) (0.2.0)
Requirement already satisfied: decorator in ./.venv/lib/python3.6/site-packages (from traitlets->jupyter-client==6.1.12) (5.0.5)
Installing collected packages: jupyter-client
  Attempting uninstall: jupyter-client
    Found existing installation: jupyter-client 6.1.13
    Uninstalling jupyter-client-6.1.13:
      Successfully uninstalled jupyter-client-6.1.13
Successfully installed jupyter-client-6.1.12

$ pip list
Package          Version
---------------- -------
appnope          0.1.2
backcall         0.2.0
decorator        5.0.5
ipykernel        5.5.3
ipython          7.16.1
ipython-genutils 0.2.0
jedi             0.18.0
jupyter-client   6.1.12
jupyter-core     4.7.1
nest-asyncio     1.5.1
parso            0.8.2
pexpect          4.8.0
pickleshare      0.7.5
pip              21.0.1
prompt-toolkit   3.0.18
ptyprocess       0.7.0
Pygments         2.8.1
PyQt5            5.15.4
PyQt5-Qt5        5.15.2
PyQt5-sip        12.8.1
python-dateutil  2.8.1
pyzmq            22.0.3
qtconsole        5.0.3
QtPy             1.9.0
setuptools       54.2.0
six              1.15.0
tornado          6.1
traitlets        4.3.3
wcwidth          0.2.5
wheel            0.36.2

$ jupyter qtconsole
# At this point there is no output in the terminal, but the qtconsole window opens successfully
@carlosperate carlosperate changed the title jupyter-client v6.1.13 break sqtconsole jupyter-client v6.1.13 breaks qtconsole Apr 7, 2021
@ccordoba12
Copy link
Collaborator

Thanks a lot for reporting @carlosperate! I'll try to fix it as soon as possible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants