question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NotImplementedError when trying to run cq-editor

See original GitHub issue

Date: 27 November 2020 Version: the master in Conda at the time of writing.

The instructions for installing cadquery and CQ-editor:

Installation Use conda to install: conda install -c cadquery -c conda-forge cq-editor=master

The installation seems to work fine.

But I get an error when I do

and then simply type cq-editor to run it.

The error is as follows:

Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 535, in get
    value = obj._trait_values[self.name]
KeyError: 'iopub_socket'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 535, in get
    value = obj._trait_values[self.name]
KeyError: 'iopub_thread'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\ProgramData\Anaconda3\Scripts\CQ-editor-script.py", line 10, in <module>
    sys.exit(main())
  File "C:\ProgramData\Anaconda3\lib\site-packages\cq_editor\__main__.py", line 16, in main
    win = MainWindow()
  File "C:\ProgramData\Anaconda3\lib\site-packages\cq_editor\main_window.py", line 38, in __init__
    self.prepare_panes()
  File "C:\ProgramData\Anaconda3\lib\site-packages\cq_editor\main_window.py", line 93, in prepare_panes
    ConsoleWidget(self),
  File "C:\ProgramData\Anaconda3\lib\site-packages\cq_editor\widgets\console.py", line 21, in __init__
    kernel_manager.start_kernel(show_banner=False)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\inprocess\manager.py", line 46, in start_kernel
    self.kernel = InProcessKernel(parent=self, session=self.session)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\inprocess\ipkernel.py", line 72, in __init__
    super(InProcessKernel, self).__init__(**traits)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\ipkernel.py", line 71, in __init__
    self.shell.displayhook.pub_socket = self.iopub_socket
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 575, in __get__
    return self.get(obj, cls)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 538, in get
    default = obj.trait_defaults(self.name)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 1578, in trait_defaults
    return self._get_trait_default_generator(names[0])(self)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 975, in __call__
    return self.func(*args, **kwargs)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\inprocess\ipkernel.py", line 67, in _default_iopub_socket
    return self.iopub_thread.background_socket
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 575, in __get__
    return self.get(obj, cls)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 538, in get
    default = obj.trait_defaults(self.name)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 1578, in trait_defaults
    return self._get_trait_default_generator(names[0])(self)
  File "C:\ProgramData\Anaconda3\lib\site-packages\traitlets\traitlets.py", line 975, in __call__
    return self.func(*args, **kwargs)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\inprocess\ipkernel.py", line 59, in _default_iopub_thread
    thread = IOPubThread(self._underlying_iopub_socket)
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\iostream.py", line 71, in __init__
    self._setup_event_pipe()
  File "C:\ProgramData\Anaconda3\lib\site-packages\ipykernel\iostream.py", line 90, in _setup_event_pipe
    self._event_puller = ZMQStream(pipe_in, self.io_loop)
  File "C:\ProgramData\Anaconda3\lib\site-packages\zmq\eventloop\zmqstream.py", line 127, in __init__
    self._init_io_state()
  File "C:\ProgramData\Anaconda3\lib\site-packages\zmq\eventloop\zmqstream.py", line 552, in _init_io_state
    self.io_loop.add_handler(self.socket, self._handle_events, self.io_loop.READ)
  File "C:\ProgramData\Anaconda3\lib\site-packages\tornado\platform\asyncio.py", line 100, in add_handler
    self.asyncio_loop.add_reader(fd, self._handle_events, fd, IOLoop.READ)
  File "C:\ProgramData\Anaconda3\lib\asyncio\events.py", line 501, in add_reader
    raise NotImplementedError
NotImplementedError```

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
CZDanolcommented, Nov 28, 2020

There are also experimental binary packages available now if you want to try that route. Oh maan that is such a life saver. I was having the exact same issue. I hate dealing with those obscure package managers, it’s just a bloatware and they never work properly.

0reactions
GeorgesPaulcommented, Nov 28, 2020

@GeorgesPaul If you grab a copy of the repo and run CQ-editor with python run.py do you get the same result?

In that case I get the following (not the same result):

CQ-editor-master>python run.py
  File "run.py", line 1
    ruimport os, sys, asyncio
             ^
SyntaxError: invalid syntax

My Conda environments use Python 3.8 as interpreters.

Did you install CQ-editor into your default environment, or create a new one?

Into the default environment (which is called “base” by default) as well as in a new environment. I tried to run cq-editor in both environments (after activating each environment individually and after installing cq-editor as per instructions for each conda environment). Both Conda environments give the same error message.

There are also experimental binary packages available now if you want to try that route.

I just tried this and this is a much easier way to get started and to play around with CQ. It could be a good idea to add this to a “Quick start” chapter in the manuals for CQ-editor and CadQuery for people (like myself) to have a quick peak at what the project is all about? The “non-binary way” to setup everything is really time consuming even for people who know some python who would happily use the software. I tried to pull request a link to the binaries into the CQ(editor) project readmes, but apparently stuff is not ready yet for that. Anyway, love the project now that I can fiddle around with it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

NotImplementedError for cache clear · Issue #570 - GitHub
As my backend, I'm running memcached. Disabling the DDT works; no exception is raised. Note that I'm trying to clear the cache from...
Read more >
NotImplementedError() what does this mean, event profiler ...
I'm trying to run pyalgotrade's event profiler. I'm using custom data, it works when I run it with the default stratergy/predicate ...
Read more >
installation error (cq-editor, Win10) - Google Groups
I really want to try cq-editor though but cannot get it to install and run. I hadn't used Anaconda before, so I went...
Read more >
The CadQuery Gateway Interface
CQ-editor, which runs scripts inside of a CadQuery IDE, and displays objects in the display window and includes features like debugging.
Read more >
Use createTextMatcher in Playwright Internal With Examples ...
Run Playwright Internal automation tests on LambdaTest cloud grid ; { platform, isPlatform, isRegex } = require("../utils"); ; { NotImplementedError, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found