Im using GIMP 2.8.22 bundled for OSX with Python 2.7.9 installed alongside Python 3.5.2 since before. I start my plugins by pointing to the 2.7.9 version of python. OSX version is Sierra (10.12.5 (16F73)).
After some debugging and going through a few youtube videos on building python plugins for Gimp I copied an example made by Kota Weaver in a youtube tutorial (https://youtu.be/M0IrGCyQAJA) but even before adding the actual logic, when he got his plug-in to show up in the selected menu, mine did not (around 3:00 into the tutorial).
I made sure there was no syntax-errors in the code by running the script from the command line. It resulted in the gimpfu import error since that package isn't loaded when run from outside gimp, but I've learned that syntax checking occurs before this step.
The thing that I wonder about here, and where I am stuck is the ImportError. Why is this, and how can I correct it? The files it cannot load are all in the right place.