zykrah / kicad-kle-placer

KiCAD plugin to help place switch footprints based on a KLE
MIT License
68 stars 8 forks source link

ValueError: invalid null reference in method 'BOARD_ITEM___eq__', argument 2 of type 'BOARD_ITEM const &' #15

Open knaegt opened 1 week ago

knaegt commented 1 week ago

Hi! I'm trying to run the KLE plugin, but whenever I do, I get this message:

Traceback (most recent call last):

File "/Users/svamp/Documents/KiCad/8.0/3rdparty/plugins/com_github_zykrah_kicad-kle-placer/kle_placer_action.py", line 514, in Run
placer.Run(dlg.get_key_annotation_format(), dlg.get_stabilizer_annotation_format(), dlg.get_diode_annotation_format(), dlg.get_move_diodes_bool(), dlg.get_relative_diode_bool(), dlg.get_specific_ref_mode_bool())

File "/Users/svamp/Documents/KiCad/8.0/3rdparty/plugins/com_github_zykrah_kicad-kle-placer/kle_placer_action.py", line 296, in Run
first_key = self.get_footprint(key_format.format(1))

File "/Users/svamp/Documents/KiCad/8.0/3rdparty/plugins/com_github_zykrah_kicad-kle-placer/kle_placer_action.py", line 136, in get_footprint
if footprint == None and required:

File "/Volumes/sol2/Apps/KiCad/KiCad.app/Contents/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pcbnew.py", line 9450, in __eq__
return _pcbnew.BOARD_ITEM___eq__(self, aItem)

ValueError: invalid null reference in method 'BOARD_ITEM___eq__', argument 2 of type 'BOARD_ITEM const &'

For reference, I'm using KiCad 8.0.3 on an M1 mac, running Sonoma 14.5, and I renamed the switches to MX instead of the default SW. I used marbastlib footprints for the hotswap switches and default library footprints for the rest. The layout is a custom version of a 40% keyboard where the bottom row isn't as wide as the rest of the keyboard.

zegonix commented 1 week ago

I use manjaro (xfce) and used the plugin with kicad 7 earlier this year. kicad automatically updated to version 8 and now even after a clean and reinstall the plugin won't work (I tested the exact same situation as in kicad 7). I would assume that this is a version mismatch problem? best regards, zegonix