Unable to start KiCAD 6.x on Wndows 10

Hello!
I just downloaded and installed KiCAD 6.0.2 for the first time on my Windows 10 HP ZBook laptop with German language pack. The installation is successful, but when I start the application kicad.exe I first get a dialog that allows me to take over old settings. Since I didn’t use KiCAD before, I continued with the default.
But then nothing happens! As long as the initial dialog is shown I can see KiCAD.exe as an active process in task manager, but after clicking OK it’s gone.
The Windows version I run is Windows 10 21H1 (Build 19043.1586). RAM: 32GB; HDD about 360GB free on a SSD drive. 4K internal laptop monitor with a resolution of 3840 x 2160 at 200%.
For other programs I have several python versions installed (e.g. v2.7.7, 3.0.10). Can this be the reason or maybe the graphics card?
How can I eventially turn on some kind of logging in KiCAD to find out what’s going on?

For testing perposes, I just installed KiCAD 5 (latest release) and it starts up without any problems.

Regards,

Martin

Hi, Martin

Your inquiry deserves an answer and I do not have it. But I hope that by responding, I can elevate your thread up higher on the list so as to help it get some attention.

FYI I run 6.0 on a Dell laptop with Windows 10 and 8G of RAM, and my external (better) monitor is 2K. This works well for me. So you have a lot more hardware capability than I do…

There is no logging but you can get a crash report. It’s fairly involved and technical process described here

You will need pdb files from here, pick the ones that match your installer
https://downloads.kicad.org/kicad/windows/explore/stable

Hi;
Thanks for your reply. The problem here is, that the application is not crashing. I turned on Windows error reporting for KICAD.exe to get a crash dump, but the process is stopped immediately. Eventually abort() is called. It’s absolutely strange.
What’s the difference in startup between v5 and v6? As mentioned before, v5 starts up successfully and I can work with it without any problems.

I will give windbg a try!

Martin

If kicad.exe suddenly exits it most definitely crashes.

There are too many things that changed between v5 and v6, one of the biggest ones is switching to completely different compiler and libraries ecosystem (msys/mingw to msvc/vcpkg).

Hi;
I finally found the reason for the sudden stop. It’s Python related. I have installed Python 3.10 on my local machine in C:\Python and the error I get on startup is shown in the screenshot:


Python (3.9) can’t initialize the sys standard streams.
Would be great to get an error message when this happens.
I just renamed my Python directory on drive C: to something different and then KiCAD.exe started up.

Does anyone know what to do in this case? I need Python 3.10 for several other applications, so I don’t want to uninstall it or rename it every time I use KiCAD.
BTW: KiCAD 5.x works without any problems.

Don’t let python installer add any system wide environment variables and it should coexist normally with KiCad.

@mgampi can you check if you have a PYTHON PATH environment variable defined?

Its supposed to co-exist already but python by design is the broken so just another thing that needs hotglue.

I’m using the python capi to initialize the paths in python but I have a strange feeling that they failed to follow their own documentation and override with the env variable anyway. Argh

Yep, I skimmed over that code and am aware of what the intention there is. Hence my recommendation to avoid system wide variables.

Python in general tries to solve the dependency hell with semi sane solution of venvs and focuses on that. IIRC standalone python installer even warns about this.

I just created a small .cmd file on Windows to start KiCAD with the correct Python environment:

@echo off
c:
set pythonpath=%PROGRAMFILES%\KiCad\6.0\bin
cd %PROGRAMFILES%\KiCad\6.0\bin
start kicad.exe
exit

For me, this is all I need. The core installment of Python is required for several other applications on my machine.

@marekr Yes there is - at least - one active PYTHONPATH environment variable defined. To be more precise, I have installed Python 2.7, 3.6., 3.8. and 3.10 - and now with KiCAD Python 3.9 on one machine.
I need all the versions due to projects I have to support for our customers.

You can have all the python versions, just remove the system environment variable. You should be able to point your projects to use any specific environment either with a batch file like you did with kicad or simply by invoking correct python.exe which is less work.

Fixed in the next release. It will also be available in the next 6.0 testing builds tommorrow

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