Eeschema - possible python library issue

This affects likewise BOTH, the current stock version 5.1.4, and most recent master 5.99 commits as of this writing.

  • System is Linux using xubuntu 18.04.3
  • kernel after update is 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

The issue

An attempt to add (A command) a new symbol in any eeschema sheet, whether blank or not, makes the entire KiCad infrastructure hang indefinitely. The only way to close Kicad from within is a click on the little cross. This times out after a while with a system dialog whether to close the application or not. Alternatively a command line ‘killall kicad’ will do.

Apart from that. Without adding a symbol with (A) it is still possible to duplicate any already existing symbol followed by an E to change the library reference to obtain a different symbol, footprint etc. Just a workaround the above issue. This of course works only if there is a symbol already present. Anything else from there works as expected.

This problem showed up after a regular OS update on the 19 October 2019. Part of that update were 9 python 3.6 related files as well as 7 python 2.7 related files. List of files updated in their order of occurrence in the log file below.

  • versions appear to be python 3.6.8
    libpython3.6-minimal:amd64
    python3-gpg:amd64
    libpython3.6-dev:amd64
    python3.6-venv:amd64
    libpython3.6-stdlib:amd64
    libpython3.6:amd64
    python3.6:amd64
    python3.6-minimal:amd64
    python3.6-dev:amd64

  • versions appear to be 2.7.15
    python2.7-dev:amd64
    python2.7-minimal:amd64
    libpython2.7:amd64
    python2.7:amd64
    libpython2.7-dev:amd64
    libpython2.7-minimal:amd64
    libpython2.7-stdlib:amd64

What raised a big red flag is the fact that the current 5.1.4 stock version is affected by that as well. Yikes.

Any ideas?

Application: KiCad
Version: 5.1.4-e60b266~84~ubuntu18.04.1, release build
Libraries:
wxWidgets 3.0.4
libcurl/7.58.0 OpenSSL/1.1.1 zlib/1.2.11 libidn2/2.0.4 libpsl/0.19.1 (+libidn2/2.0.4) nghttp2/1.30.0 librtmp/2.3
Platform: Linux 4.15.0-66-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.22
Boost: 1.65.1
OpenCASCADE Community Edition: 6.9.1
Curl: 7.58.0
Compiler: GCC 7.4.0 with C++ ABI 1011
Build settings:
USE_WX_GRAPHICS_CONTEXT=OFF
USE_WX_OVERLAY=ON
KICAD_SCRIPTING=ON
KICAD_SCRIPTING_MODULES=ON
KICAD_SCRIPTING_PYTHON3=ON
KICAD_SCRIPTING_WXPYTHON=ON
KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
KICAD_SCRIPTING_ACTION_MENU=ON
BUILD_GITHUB_PLUGIN=ON
KICAD_USE_OCE=ON
KICAD_USE_OCC=OFF
KICAD_SPICE=ON

Application: KiCad
Version: (5.99.0-258-gc6416066b-dirty), release build
Libraries:
wxWidgets 3.0.4
libcurl/7.58.0 GnuTLS/3.5.18 zlib/1.2.11 libidn2/2.0.4 libpsl/0.19.1 (+libidn2/2.0.4) nghttp2/1.30.0 librtmp/2.3
Platform: Linux 4.15.0-66-generic x86_64, 64 bit, Little endian, wxGTK
Build Info:
Build date: Oct 24 2019 11:31:10
wxWidgets: 3.0.4 (wchar_t,wx containers,compatible with 2.8) GTK+ 3.22
Boost: 1.65.1
OpenCASCADE Community Edition: 6.9.1
Curl: 7.58.0
Compiler: GCC 9.2.1 with C++ ABI 1013
Build settings:
KICAD_SCRIPTING=ON
KICAD_SCRIPTING_MODULES=ON
KICAD_SCRIPTING_PYTHON3=ON
KICAD_SCRIPTING_WXPYTHON=ON
KICAD_SCRIPTING_WXPYTHON_PHOENIX=ON
KICAD_SCRIPTING_ACTION_MENU=ON
BUILD_GITHUB_PLUGIN=ON
KICAD_USE_OCE=ON
KICAD_USE_OCC=OFF
KICAD_SPICE=ON

Why do you think python libs have anything to do with this issue? Eeschema doesn’t use anything python related at all (some python bom scripts don’t count, they launch as separate process).
Try opening symbol editor directly from kicad main window, without opening eeschema. Does that load all libs properly?

1 Like

There are no issues with normal library functionality, otherwise I would have stated it.

It only applies on attempts to add a new symbol from any library.

Trying to figure out where this came from. Python might be an issue. Can’t tell for sure. In any case after that update both Kicad versions are affected after all.

I am aware of some aspects of Kicad source though not all of them (yet). Before I start a ‘witch hunt’ through the source myself, someone might have an idea or two.

Cheers

Does this happen on a new empty schematic?
Does this happen if you temporarily remove all libs from the library table?
When adding a symbol for the first time kicad caches all libs, that’s why I think it has to do with libs.

If you are familiar with code you can build a debug build and run it under gdb and see what is going on when you trigger the bug by looking at stack.

It happens regardless.

Just started a new project with empty everything and it does the same.

Looks like I shall give gdb a run.

Do you have the experimental footprint preview turned on?

Preferences → General Options.
On the Display tab: “Footprint previews in symbol chooser (experimental)”.

Shouldn’t this discussion be moved to bugtracker?

Thanks Rene for that hint. A simple uncheck did it.

Still, this shows that there is some ‘sharing’ of settings between different Kicad versions on the same system going on in some ways.

It used to read ‘(experimental)’ many commits ago. Not anymore. I did not use that setting until the experimental remark vanished. After that it appeared to work until that OS update day.

Is your platform even one of the few that officially support running nightly and stable side by side? (I am only aware of ubuntu. I am quite sure windows does not officially support it. There are ways to set it up that way but this is not done by the official installer)

xfce flavour aka xubuntu 18.04.3 LTS it is. Should be alright methinks.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.