I wanted to test today’s kicad-nightly-9.99.0.2573.g5895c27f4a-x86_64.exe release. It installs fine, but doesn’t run. Kicad.exe appears only for about a second in Windows task manager, then disapppears. Could someone else confirm this? Thanks.
I can open a project, schematic and pcb normally with it. Windows 11, a bit older laptop.
You can try closing KiCad, renaming %appdata%\kicad\9.99\ and opening KiCad again to see if it’s about some non-default setting.
In my environment it started normally.
Platform: Windows 11 (build 26100), 64bit edition, 64 bit
Version: 9.99.0-2573-g5895c27f4a, release build
I’m testing it on old PC with Windows 10 64-bit which I keep for such experiments. I tried deleting all KiCad-related directories in /Users/, but it didn’t help. That’s not suprising, because they were already empty, as I uninstalled the previous version with “remove config files” option. I tried installing today’s kicad-nightly-9.99.0.2590.g9fcee70827-x86_64.exe and it doesn’t run either. Windows crash dumps say the problem occurs in kicommon.dll.
Of course, they’re just develompment builds and some wrinkles can be expected with so many additions lately. (I’m particularly hyped about the latest lasso selection feature and multi-unit symbol placement fix.) If it persists in a few next nightlies, I’ll make a bug report on Gitlab.
If you start cmd.exe with administrator privileges and attach the following execution results, you may be able to get more details.
wevtutil qe Application /c:5 /f:Text /rd:true "/q:*[System[(EventID=1000)]]"
dir %appdata%\kicad
dir %LOCALAPPDATA%\CrashDumps
sfc /scannow
If you get WinDbg and provide the traceback information of the crash dump, you can visualize the sequence of function calls and the cause of the abnormal termination.
Install only WinDbg from here. (Win10) Windows SDK - Windows app development | Microsoft Developer
Select the file saved in the %LOCALAPPDATA%\CrashDumps folder with Open Crash Dump and run the following command to get more details:
k
!analyze -v
Ex.
In addition to the above, it would be helpful if you could also provide information about the operations and steps to generate a crash dump.
For example:
- In Windows Explorer, select an existing project file created with a previous version of KiCAD. (-> KiCad | master | English | Documentation | KiCad )
- Launch KiCAD from the Windows Start menu.
(-> KiCad | master | English | Documentation | KiCad ) - Launch another KiCAD program from the Windows Start menu.
Same here with kicad-nightly-9.99.0.2648.g9883c798fe-x86_64-lite
I did as @tama suggested. Lauching from start menu or launching other (standalone) KiCad apps failed as well.
Here is the WinDbg analysis:
0:000> k
# Child-SP RetAddr Call Site
00 00000067`d28fc3a8 00007ffc`9618df43 ntdll!NtWaitForMultipleObjects+0x14
01 00000067`d28fc3b0 00007ffc`9618de11 KERNELBASE!WaitForMultipleObjectsEx+0x123
02 00000067`d28fc6a0 00007ffc`979812b0 KERNELBASE!WaitForMultipleObjects+0x11
03 00000067`d28fc6e0 00007ffc`979a898d kernel32!WerpReportFaultInternal+0x62c
04 00000067`d28fc860 00007ffc`96259e4c kernel32!WerpReportFault+0xc5
05 00000067`d28fc8b0 00007ffc`98dea01f KERNELBASE!UnhandledExceptionFilter+0x34c
06 00000067`d28fc9a0 00007ffc`98da6553 ntdll!RtlUserThreadStart$filt$0+0x3f
07 00000067`d28fc9d0 00007ffc`98de6fef ntdll!_C_specific_handler+0x93
08 00000067`d28fca40 00007ffc`98cf4557 ntdll!RtlpExecuteHandlerForException+0xf
09 00000067`d28fca70 00007ffc`98de692e ntdll!RtlDispatchException+0x437
0a 00000067`d28fd1c0 00007ffb`8a1d809c ntdll!KiUserExceptionDispatch+0x2e
0b 00000067`d28fdf20 00007ffb`8a1dae5e kicommon!DIALOG_SHIM::LoadControlState+0x4c
0c 00000067`d28fe070 00007ffb`a02ab338 kicommon!DIALOG_SHIM::onInitDialog+0xe
0d 00000067`d28fe0a0 00007ffb`a039a9ef wxbase330u_vc_x64_custom!wxAppConsoleBase::CallEventHandler+0x58
0e 00000067`d28fe0e0 00007ffb`a039b6af wxbase330u_vc_x64_custom!wxEvtHandler::ProcessEventIfMatchesId+0x4f
0f 00000067`d28fe110 00007ffb`a039ba2b wxbase330u_vc_x64_custom!wxEvtHandler::SearchDynamicEventTable+0x15f
10 00000067`d28fe190 00007ffb`a039a953 wxbase330u_vc_x64_custom!wxEvtHandler::TryHereOnly+0x2b
11 00000067`d28fe1c0 00007ffb`a05e46d1 wxbase330u_vc_x64_custom!wxEvtHandler::ProcessEvent+0xe3
12 00000067`d28fe200 00007ffb`a07d3b45 wxmsw330u_core_vc_x64_custom!wxPanel::InitDialog+0x41
13 00000067`d28fe280 00007ffb`8a1d9e2e wxmsw330u_core_vc_x64_custom!wxDialog::Show+0x85
14 00000067`d28fe2b0 00007ffb`a07d3d04 kicommon!DIALOG_SHIM::Show+0x4e
15 00000067`d28fe410 00007ffb`8a0c1644 wxmsw330u_core_vc_x64_custom!wxDialog::ShowModal+0xd4
16 00000067`d28fe480 00007ffb`8a0ba27e kicommon!SETTINGS_MANAGER::MigrateIfNeeded+0x924
17 00000067`d28ff410 00007ffb`8a229575 kicommon!SETTINGS_MANAGER::SETTINGS_MANAGER+0x1de
18 00000067`d28ff5a0 00007ff7`d80bc8fd kicommon!PGM_BASE::InitPgm+0x5a5
19 00000067`d28ff880 00007ff7`d80bc283 kicad!LIB_TREE_ITEM::GetChooserFields+0x16cd
1a 00000067`d28ffdc0 00007ffb`a031fda6 kicad!LIB_TREE_ITEM::GetChooserFields+0x1053
1b 00000067`d28ffe30 00007ffb`a031fb37 wxbase330u_vc_x64_custom!wxInitData::wxInitData+0xa6
1c 00000067`d28ffe70 00007ffb`a0320db8 wxbase330u_vc_x64_custom!wxStringHash::stringHash+0x217
1d 00000067`d28ffea0 00007ffb`a03eb838 wxbase330u_vc_x64_custom!wxEntryCleanup+0x138
1e 00000067`d28ffee0 00007ff7`d829127a wxbase330u_vc_x64_custom!wxEntry+0x28
1f 00000067`d28fff10 00007ffc`9795e8d7 kicad!make_fcontext+0x4aaca
20 00000067`d28fff50 00007ffc`98cbc34c kernel32!BaseThreadInitThunk+0x17
21 00000067`d28fff80 00000000`00000000 ntdll!RtlUserThreadStart+0x2c
0:000> ! anaylze -v
anaylze is not extension gallery command
No export anaylze found
0:000> ! analyze -v
*******************************************************************************
* *
* Exception Analysis *
* *
*******************************************************************************
KEY_VALUES_STRING: 1
Key : AV.Dereference
Value: NullClassPtr
Key : AV.Fault
Value: Read
Key : Analysis.CPU.mSec
Value: 843
Key : Analysis.Elapsed.mSec
Value: 900
Key : Analysis.IO.Other.Mb
Value: 0
Key : Analysis.IO.Read.Mb
Value: 0
Key : Analysis.IO.Write.Mb
Value: 0
Key : Analysis.Init.CPU.mSec
Value: 3327
Key : Analysis.Init.Elapsed.mSec
Value: 120846
Key : Analysis.Memory.CommitPeak.Mb
Value: 119
Key : Failure.Bucket
Value: NULL_CLASS_PTR_READ_c0000005_kicommon.dll!Unknown
Key : Failure.Hash
Value: {f1e46ee9-6c2a-cede-ca5e-81860d16a649}
Key : Timeline.OS.Boot.DeltaSec
Value: 7842
Key : Timeline.Process.Start.DeltaSec
Value: 3
Key : WER.OS.Branch
Value: ge_release
Key : WER.OS.Version
Value: 10.0.26100.1
Key : WER.Process.Version
Value: 9.99.0.44252
FILE_IN_CAB: kicad.exe.24800.dmp
NTGLOBALFLAG: 0
APPLICATION_VERIFIER_FLAGS: 0
CONTEXT: (.ecxr)
rax=0000000000000000 rbx=00000067d28fe220 rcx=00007ff7d83e5320
rdx=00007ff7d82d1e88 rsi=0000000000000000 rdi=00000067d28fe220
rip=00007ffb8a1d809c rsp=00000067d28fdf20 rbp=00000067d28fe020
r8=00000067d28fe0c0 r9=00000067d28fe220 r10=00007ffb8a1dae50
r11=0000000000000000 r12=00000067d28fef50 r13=00000067d28fef50
r14=000001edea1afe00 r15=00007ffb8a5d8400
iopl=0 nv up ei pl nz na po nc
cs=0033 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010206
kicommon!DIALOG_SHIM::LoadControlState+0x4c:
00007ffb`8a1d809c 488bb8f8000000 mov rdi,qword ptr [rax+0F8h] ds:00000000`000000f8=????????????????
Resetting default scope
EXCEPTION_RECORD: (.exr -1)
ExceptionAddress: 00007ffb8a1d809c (kicommon!DIALOG_SHIM::LoadControlState+0x000000000000004c)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 0000000000000000
Parameter[1]: 00000000000000f8
Attempt to read from address 00000000000000f8
PROCESS_NAME: kicad.exe
READ_ADDRESS: 00000000000000f8
ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.
EXCEPTION_CODE_STR: c0000005
EXCEPTION_PARAMETER1: 0000000000000000
EXCEPTION_PARAMETER2: 00000000000000f8
STACK_TEXT:
00000067`d28fdf20 00007ffb`8a1dae5e : 00000000`00000000 00000067`d28fe220 00000067`d28fef50 00000067`d28fe220 : kicommon!DIALOG_SHIM::LoadControlState+0x4c
00000067`d28fe070 00007ffb`a02ab338 : 00000000`00000000 000005a0`00000a00 00000000`00000000 00000000`00000010 : kicommon!DIALOG_SHIM::onInitDialog+0xe
00000067`d28fe0a0 00007ffb`a039a9ef : 00000067`d28fe220 000001ed`ed388080 00000000`00000009 000001ed`ea0c0000 : wxbase330u_vc_x64_custom!wxAppConsoleBase::CallEventHandler+0x58
00000067`d28fe0e0 00007ffb`a039b6af : 00000000`00000008 00007ffc`98c8f2a4 000001ed`ea1c0000 000001ed`00000000 : wxbase330u_vc_x64_custom!wxEvtHandler::ProcessEventIfMatchesId+0x4f
00000067`d28fe110 00007ffb`a039ba2b : 00000067`d28fe3e8 00000067`d28fe220 000001ed`ea0c2ac0 00007ffc`98c8f164 : wxbase330u_vc_x64_custom!wxEvtHandler::SearchDynamicEventTable+0x15f
00000067`d28fe190 00007ffb`a039a953 : 00000000`00000000 00000000`00000000 00000000`00000030 00007ffc`98c8f2a4 : wxbase330u_vc_x64_custom!wxEvtHandler::TryHereOnly+0x2b
00000067`d28fe1c0 00007ffb`a05e46d1 : 00000067`d28fef50 00000000`00000000 00000000`00000001 00000000`00000000 : wxbase330u_vc_x64_custom!wxEvtHandler::ProcessEvent+0xe3
00000067`d28fe200 00007ffb`a07d3b45 : 00000000`00000114 00000000`000003d4 00000000`00000246 00000067`d28fef50 : wxmsw330u_core_vc_x64_custom!wxPanel::InitDialog+0x41
00000067`d28fe280 00007ffb`8a1d9e2e : 00000067`00000114 000001ed`000003d4 00000067`d28fef50 00000000`00000000 : wxmsw330u_core_vc_x64_custom!wxDialog::Show+0x85
00000067`d28fe2b0 00007ffb`a07d3d04 : 000001ed`ed529fb0 00000067`d28fef50 00000067`d28fef50 00000000`00000000 : kicommon!DIALOG_SHIM::Show+0x4e
00000067`d28fe410 00007ffb`8a0c1644 : 000001ed`ed35ef00 00000067`d28fef50 000001ed`ed529fb0 00000067`d28fe580 : wxmsw330u_core_vc_x64_custom!wxDialog::ShowModal+0xd4
00000067`d28fe480 00007ffb`8a0ba27e : 000001ed`ed35ee08 000001ed`ed35ef00 00000000`00000000 000001ed`ed35eda0 : kicommon!SETTINGS_MANAGER::MigrateIfNeeded+0x924
00000067`d28ff410 00007ffb`8a229575 : 000001ed`ec96d3a0 00000067`d28ff6c0 00007ff7`d83e5320 000001ed`ecf95180 : kicommon!SETTINGS_MANAGER::SETTINGS_MANAGER+0x1de
00000067`d28ff5a0 00007ff7`d80bc8fd : 00000000`00000001 00000000`00000001 00000000`00000000 000001ed`ea1bd570 : kicommon!PGM_BASE::InitPgm+0x5a5
00000067`d28ff880 00007ff7`d80bc283 : 00000067`d28ffef8 00000000`00000000 000001ed`ea1a94e0 00000000`00000000 : kicad!LIB_TREE_ITEM::GetChooserFields+0x16cd
00000067`d28ffdc0 00007ffb`a031fda6 : 00000000`00000000 00000000`00000007 00000000`00000000 00000000`00000000 : kicad!LIB_TREE_ITEM::GetChooserFields+0x1053
00000067`d28ffe30 00007ffb`a031fb37 : 000001ed`ea1afe00 000001ed`ea1afe00 00007ffb`a04d5408 00000000`00000000 : wxbase330u_vc_x64_custom!wxInitData::wxInitData+0xa6
00000067`d28ffe70 00007ffb`a0320db8 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : wxbase330u_vc_x64_custom!wxStringHash::stringHash+0x217
00000067`d28ffea0 00007ffb`a03eb838 : 000001ed`ea1a94e0 00007ffb`a04d07f8 00000000`00000001 00000000`00000000 : wxbase330u_vc_x64_custom!wxEntryCleanup+0x138
00000067`d28ffee0 00007ff7`d829127a : 00000000`00000001 00000000`00000000 00000000`00000000 00000000`00000000 : wxbase330u_vc_x64_custom!wxEntry+0x28
00000067`d28fff10 00007ffc`9795e8d7 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : kicad!make_fcontext+0x4aaca
00000067`d28fff50 00007ffc`98cbc34c : 00000000`00000000 00000000`00000000 000004f0`fffffb30 000004d0`fffffb30 : kernel32!BaseThreadInitThunk+0x17
00000067`d28fff80 00000000`00000000 : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : ntdll!RtlUserThreadStart+0x2c
STACK_COMMAND: ~0s; .ecxr ; kb
SYMBOL_NAME: kicommon+4c
MODULE_NAME: kicommon
IMAGE_NAME: kicommon.dll
FAILURE_BUCKET_ID: NULL_CLASS_PTR_READ_c0000005_kicommon.dll!Unknown
OS_VERSION: 10.0.26100.1
BUILDLAB_STR: ge_release
OSPLATFORM_TYPE: x64
OSNAME: Windows 10
IMAGE_VERSION: 9.99.0.44252
FAILURE_ID_HASH: {f1e46ee9-6c2a-cede-ca5e-81860d16a649}
Followup: MachineOwner
---------
```
FWIW: this is an fresh install on a new machine I setup yesterday (with a shiny new 9600X ). So this might be related to the initial dialog that only comes up on a clean install with no pre-existing installs.
Or not …
[EDIT]: also explains why @eelik and @tama did not run into this fault.
BTW, the Linus Torvalds registered on Gitlab and reported a KiCad bug yesterday:
Apparently, he now tries his hand on hardware design, too:
Didn’t see that one coming!
I tried today’s kicad-nightly-9.99.0.2706.g23c1a68da8-x86_64.exe and it works again. Whoever fixed it, thanks!
Jeff did it. Added 2 lines of code to take care of a NULL pointer …
For example, can we improve quality by using tools like these?
There seem to be a lot of other tools out there. I wonder if they’re not being used in this project?
Btw, this forum is not the right place for this kind of discussion. Devs do not show up here by default and it is not helpful information about the USE of Kicad.
So my mentioning what was done is a transgression in and of itself.
I think it’s completely appropriate to discuss this here. Even if the core devs don’t participate in the discussion, it helps others understand current problems with the product.
It also helps highlight the rapid response to serious bugs in KiCad, especially in comparison with many commercial products. For example, I just wasted an entire day dealing with a bug in AMD (Xilinx) Vitis, only to discover it’s a known problem that has existed for at least two years and at least one major release.
just to be clear: it is not “the product”, it is a nightly which can do anything and be faulty by definition. While asking about an error here is completely appropriate, discussion of coding errors (which it was in this case) is not IMHO.
[EDIT] By “this type of discussion” I obviously meant the discussion about code/syntax checking tools.
Static analysis is used (Coverity - which has been in use by KiCad since 2015), and we get daily emails of new issues. As always, it comes down to having enough developer time to triage these issues, along with user-filed bug reports, bugs we find ourselves, and finding time to implement new features.
on the Wiki.
In addition to what James said above about Coverity, if you do get some other static analyser set up and it finds issues in KiCad, you can report them. But they need to be actual practical issues that can plausibly cause a crash, data loss or bad performance in realistic scenarios. Just don’t spam low-grade “potential issues”, issues where the performance gain is substantially less than the drop in code readability, and definitely don’t use AI to auto-find and report issues (like cURL is getting: Curl creator mulls nixing bug bounty awards to stop AI slop • The Register).
You can also carefully document exactly how to set the analyser up for KiCad and post that process, as that can help others set it up and look at issues. If the analyser is actually any good and detects issues, who knows, maybe one day it’ll get used in the CI system!