Error Running README skidl file

As i ran the sample code on my computer (Mac) i get the following error:

FileNotFoundError: Unable to open KiCad Schematic Library File Device (Can’t open file: Device.

Do you have KiCad installed? For the example, SKiDL needs to load the KiCad schematic symbol library named Device.lib.

KiCad is installed and the device library is active as well

I also added the python file as part of a new KiCad project.

You can see the problem right at the top of your screen: “WARNING: KICAD_SYMBOL_DIR environment variable is missing, so the default KiCad symbol libraries won’t be searched.” So SKiDL can’t find the directory where the Device.lib file is stored.

You can either set the environment variable, or add the library path explicitly: