Mcp23017 stopped working

half of a year ago i tried to update the binding, but as i found out, 2.5 mcp23017 does not work so i had to downgrad back to 2.4. Everything seemed to be working ok, until yeserday :slight_smile: somehome it stopped working even i did not make any changes. i started getting this error:

2021-06-06 09:39:39.953 [ERROR] [nal.common.AbstractInvocationHandler] - An error occurred while calling method ‘ThingHandler.handleCommand()’ on ‘org.openhab.binding.mcp23017.handler.Mcp23017Handler@6f9f8f’: null

java.lang.NullPointerException: null

at com.pi4j.io.gpio.impl.GpioControllerImpl.provisionPin(GpioControllerImpl.java:545) ~[?:?]

at com.pi4j.io.gpio.impl.GpioControllerImpl.provisionDigitalOutputPin(GpioControllerImpl.java:717) ~[?:?]

at org.openhab.binding.mcp23017.handler.Mcp23017PinStateHolder.initializeOutputPin(Mcp23017PinStateHolder.java:71) ~[?:?]

at org.openhab.binding.mcp23017.handler.Mcp23017PinStateHolder.getOutputPin(Mcp23017PinStateHolder.java:59) ~[?:?]

at org.openhab.binding.mcp23017.handler.Mcp23017Handler.handleOutputCommand(Mcp23017Handler.java:110) ~[?:?]

at org.openhab.binding.mcp23017.handler.Mcp23017Handler.handleCommand(Mcp23017Handler.java:79) ~[?:?]

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_152]

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_152]

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_152]

at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_152]

at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:152) [bundleFile:?]

at org.eclipse.smarthome.core.internal.common.InvocationHandlerSync.invoke(InvocationHandlerSync.java:59) [bundleFile:?]

at com.sun.proxy.$Proxy211.handleCommand(Unknown Source) [?:?]

at org.eclipse.smarthome.core.thing.internal.profiles.ProfileCallbackImpl.handleCommand(ProfileCallbackImpl.java:74) [bundleFile:?]

at org.eclipse.smarthome.core.thing.internal.profiles.SystemDefaultProfile.onCommandFromItem(SystemDefaultProfile.java:48) [bundleFile:?]

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_152]

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_152]

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_152]

at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_152]

at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:152) [bundleFile:?]

at org.eclipse.smarthome.core.internal.common.Invocation.call(Invocation.java:52) [bundleFile:?]

at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_152]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_152]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_152]

at java.lang.Thread.run(Thread.java:748) [?:1.8.0_152]

my configuration:
Thing mcp23017:mcp23017:chipCC “MCP23017 chip CC” [address=24,bus=1] {
Type output_pin : output#A0 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A1 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A2 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A3 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A4 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A5 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A6 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#A7 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B0 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B1 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B2 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B3 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B4 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B5 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B6 [default_state=“LOW”, active_low=“n”]
Type output_pin : output#B7 [default_state=“LOW”, active_low=“n”]
}

Thing mcp23017:mcp23017:chipINPUT778 “MCP23017 chip INPUT7” [address=22,bus=1] {

Type input_pin : input#A0 [pull_mode="PULL_UP"]
Type input_pin : input#A1 [pull_mode="PULL_UP"]
Type input_pin : input#A2 [pull_mode="PULL_UP"]
Type input_pin : input#A3 [pull_mode="PULL_UP"]
Type input_pin : input#A4 [pull_mode="PULL_UP"]
Type input_pin : input#A5 [pull_mode="PULL_UP"]
Type input_pin : input#A6 [pull_mode="PULL_UP"]
Type input_pin : input#A7 [pull_mode="PULL_UP"]
Type input_pin : input#B0 [pull_mode="PULL_UP"]
Type input_pin : input#B1 [pull_mode="PULL_UP"]
Type input_pin : input#B2 [pull_mode="PULL_UP"]
Type input_pin : input#B3 [pull_mode="PULL_UP"]
Type input_pin : input#B4 [pull_mode="PULL_UP"]
Type input_pin : input#B5 [pull_mode="PULL_UP"]
Type input_pin : input#B6 [pull_mode="PULL_UP"]
Type input_pin : input#B7 [pull_mode="PULL_UP"]

}

items:
Switch switch33 “switch33” (gGenericSwitches,gNezinomi){channel=“mcp23017:mcp23017:chipCC:output#A0”}
Switch switch34 “switch34” (gGenericSwitches,gNezinomi) {channel=“mcp23017:mcp23017:chipCC:output#A1”}
Switch switch35 “switch35” (gGenericSwitches,gNezinomi) {channel=“mcp23017:mcp23017:chipCC:output#A2”}
Switch switch36 “switch36” (gGenericSwitches,gNezinomi) {channel=“mcp23017:mcp23017:chipCC:output#A3”}
Switch switch37 “switch37” (gGenericSwitches,gNezinomi) {channel=“mcp23017:mcp23017:chipCC:output#A4”}
Switch switch38 “Garažo vartai” (gGenericSwitches,gGarazas) {channel=“mcp23017:mcp23017:chipCC:output#A5” , expire=“0s,command=OFF”}
Switch switch39 “Kiemo varteliai” (gGenericSwitches,gKiemoVartai) {channel=“mcp23017:mcp23017:chipCC:output#A6” , expire=“2m,command=OFF”}
Switch switch40 “Kiemo vartai” (gGenericSwitches,gKiemoVartai) {channel=“mcp23017:mcp23017:chipCC:output#A7”, expire=“0s,command=OFF” }
Switch switch41 “switch41” (gGenericSwitches,gNezinomi) {channel=“mcp23017:mcp23017:chipCC:output#B0”}
Switch switch42 “Prie lovos” (gGenericSwitches,gJokubo,gHouseSleep) {channel=“mcp23017:mcp23017:chipCC:output#B1”}
Switch switch43 “Vonios veidrodis” (gGenericSwitches,gVonia,gHouseSleep) {channel=“mcp23017:mcp23017:chipCC:output#B2”}
Switch switch44 “Ventiliacija” (gGenericSwitches,gGarazas) {channel=“mcp23017:mcp23017:chipCC:output#B3”}
Switch switch45 “Akvariumo 220v” (gGenericSwitches,gAkvariumas) {channel=“mcp23017:mcp23017:chipCC:output#B4”}
Switch switch46 “BRA dešinėj” (gGenericSwitches,gMiegamasis,gHouseSleep) {channel=“mcp23017:mcp23017:chipCC:output#B5”}
Switch switch47 “Šoninis” (gGenericSwitches,gVejosLaistymas) {channel=“mcp23017:mcp23017:chipCC:output#B6”}
Switch switch48 “Kiemo” (gGenericSwitches,gVejosLaistymas) {channel=“mcp23017:mcp23017:chipCC:output#B7”}

Contact contact1 “contact1” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A0”}
Contact contact2 “contact2” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A1”}
Contact contact3 “contact3” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A2”}
Contact contact4 “contact4” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A3”}
Contact contact5 “contact5” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A4”}
Contact contact6 “contact6” (gGenericContacts,gCustomContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A5”}
Contact contact7 “contact7” (gGenericContacts,gCustomContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A6”}
Contact contact8 “contact8” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#A7”}
Contact contact9 “contact9” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B0”}
Contact contact10 “contact10” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B1”}
Contact contact11 “contact11” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B2”}
Contact contact12 “contact12” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B3”}
Contact contact13 “contact13” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B4”}
Contact contact14 “contact14” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B5”}
Contact contact15 “contact15” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B6”}
Contact contact16 “contact16” (gGenericContacts) {channel=“mcp23017:mcp23017:chipINPUT778:input#B7”}