Contribution - LG Thinq [Air Conditioner/Heat Pump] [WIP]

How did you configure the bridge? Its is a very unexpected error message since this is actually pointing to an invalide certificate in the LG API.

Please, put the binding in debug mode and share the log here, but before, try to remove and reinstall the bridge by the UI interface

UID: lgthinq:bridge:bcee17b7e9
label: LG ThinQ GatewayBridge
thingTypeUID: lgthinq:bridge
configuration:
  manualLanguage: RU
  country: --
  password: *****
  poolingIntervalSec: 86400
  language: --
  manualCountry: RU
  username: *******

The old version worked, but did not correctly show the status of the washing machine. I installed a new one and now it doesn’t connect. How do I enable debugging mode?

log

2023-09-22 17:45:03.151 [ERROR] [nding.lgthinq.internal.api.RestUtils] - ExecutionException occurred during POST execution: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
java.util.concurrent.ExecutionException: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
	at org.eclipse.jetty.client.util.FutureResponseListener.getResult(FutureResponseListener.java:118) ~[?:?]
	at org.eclipse.jetty.client.util.FutureResponseListener.get(FutureResponseListener.java:101) ~[?:?]
	at org.eclipse.jetty.client.HttpRequest.send(HttpRequest.java:732) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.RestUtils.postCall(RestUtils.java:170) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.RestUtils.postCall(RestUtils.java:145) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.OauthLgEmpAuthenticator.loginUser(OauthLgEmpAuthenticator.java:219) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.TokenManager.oauthFirstRegistration(TokenManager.java:104) ~[?:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQBridgeHandler$PollingRunnable.run(LGThinQBridgeHandler.java:125) ~[?:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
	at java.lang.Thread.run(Thread.java:833) ~[?:?]
Caused by: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
	at sun.security.ssl.Alert.createSSLException(Alert.java:131) ~[?:?]
	at sun.security.ssl.Alert.createSSLException(Alert.java:117) ~[?:?]
	at sun.security.ssl.TransportContext.fatal(TransportContext.java:365) ~[?:?]
	at sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:293) ~[?:?]
	at sun.security.ssl.TransportContext.dispatch(TransportContext.java:204) ~[?:?]
	at sun.security.ssl.SSLTransport.decode(SSLTransport.java:172) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.decode(SSLEngineImpl.java:736) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.readRecord(SSLEngineImpl.java:691) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:506) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:482) ~[?:?]
	at javax.net.ssl.SSLEngine.unwrap(SSLEngine.java:679) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection.unwrap(SslConnection.java:429) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$DecryptedEndPoint.fill(SslConnection.java:718) ~[?:?]
	at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:168) ~[?:?]
	at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:80) ~[?:?]
	at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:131) ~[?:?]
	at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:172) ~[?:?]
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) ~[?:?]
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$DecryptedEndPoint.onFillable(SslConnection.java:555) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:410) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$2.succeeded(SslConnection.java:164) ~[?:?]
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) ~[?:?]
	at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131) ~[?:?]
	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409) ~[?:?]
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883) ~[?:?]
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034) ~[?:?]

OK.

Update the binding with 4.1.0 version I left in my repo. Then, send me again the log generated aftger trying to enable the bridge. Some more information will come up to help me undertand better the situation.

Regards

OH not see “org.openhab.binding.lgthinq-4.1.0-SNAPSHOT.jar”

Look
 you have to first remove the old version, and after add the 4.1.0 verson in addons directory. OH will deploy the new version.

My actions:

  1. Removed the bridge
  2. Deleted the binding file
  3. Copied the new binding file to the folder
  4. OH does not see the new binding file

Or was it necessary to leave the bridge and just replace the file?

If do not delete the bridge and replace the file.
Log:

2023-09-23 07:23:52.680 [WARN ] [org.apache.felix.fileinstall        ] - Error while starting bundle: file:/usr/share/openhab/addons/org.openhab.binding.lgthinq-4.1.0-SNAPSHOT.jar
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.lgthinq [329]
  Unresolved requirement: Import-Package: javax.measure; version="[2.2.0,3.0.0)"

	at org.eclipse.osgi.container.Module.start(Module.java:463) ~[org.eclipse.osgi-3.18.0.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:445) ~[org.eclipse.osgi-3.18.0.jar:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) ~[?:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) ~[?:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) ~[?:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) ~[?:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) ~[?:?]

Same problem here. I tried also to remove the bridge and restart OH.

Looks like you guys are using the binding with incompatible version of OH. Since the binding is a WIP, I work with the SNAPSHOT trunk compatible with the lastest release of OH4.


That correspond to openHAB 4.1.0.M1
Please, verify if you guys are playing with the same milestone and if not, upgrade it. If you need some instruction in how to do it, let me know.

I use stable version openHAB 4.0.3, lg thing work only snapshot?

You’re right @nemer. I tried to use 4.1 snapshot on 4.0.3. I downloaded and installed the latest 4.0 version of the binding and I can see that you added the dishwasher thing. I tried it (both with scan and manualli adding thing) but it seems it’s not working


Updated to Milestone version 4.1.0.M1

UID: lgthinq:bridge:e5cb3870f6
label: LG ThinQ GatewayBridge
thingTypeUID: lgthinq:bridge
configuration:
  manualLanguage: RU
  country: --
  password: *****
  poolingIntervalSec: 86400
  language: --
  manualCountry: RU
  username: *****

Log

2023-09-23 16:10:16.590 [ERROR] [ng.lgthinq.internal.api.TokenManager] - Error logging with gateway: LGThinqGateway{empBaseUri='https://ru.emp.lgsmartplatform.com', loginBaseUri='https://ru.m.lgaccount.com/spx', apiRootV1='https://ruic.lgthinq.com:46030/api', apiRootV2='https://ruic-service.lgthinq.com:46030/v1', authBase='https://ru.m.lgaccount.com', language='RU', country='RU', username='', password='', alternativeEmpServer='', accountVersion=0}
2023-09-23 16:10:17.680 [ERROR] [nding.lgthinq.internal.api.RestUtils] - ExecutionException occurred during POST execution: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
java.util.concurrent.ExecutionException: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
	at org.eclipse.jetty.client.util.FutureResponseListener.getResult(FutureResponseListener.java:118) ~[?:?]
	at org.eclipse.jetty.client.util.FutureResponseListener.get(FutureResponseListener.java:101) ~[?:?]
	at org.eclipse.jetty.client.HttpRequest.send(HttpRequest.java:732) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.RestUtils.postCall(RestUtils.java:170) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.RestUtils.postCall(RestUtils.java:145) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.OauthLgEmpAuthenticator.loginUser(OauthLgEmpAuthenticator.java:219) ~[?:?]
	at org.openhab.binding.lgthinq.internal.api.TokenManager.oauthFirstRegistration(TokenManager.java:108) ~[?:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQBridgeHandler$PollingRunnable.run(LGThinQBridgeHandler.java:125) ~[?:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
	at java.lang.Thread.run(Thread.java:833) ~[?:?]
Caused by: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
	at sun.security.ssl.Alert.createSSLException(Alert.java:131) ~[?:?]
	at sun.security.ssl.Alert.createSSLException(Alert.java:117) ~[?:?]
	at sun.security.ssl.TransportContext.fatal(TransportContext.java:365) ~[?:?]
	at sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:293) ~[?:?]
	at sun.security.ssl.TransportContext.dispatch(TransportContext.java:204) ~[?:?]
	at sun.security.ssl.SSLTransport.decode(SSLTransport.java:172) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.decode(SSLEngineImpl.java:736) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.readRecord(SSLEngineImpl.java:691) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:506) ~[?:?]
	at sun.security.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:482) ~[?:?]
	at javax.net.ssl.SSLEngine.unwrap(SSLEngine.java:679) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection.unwrap(SslConnection.java:429) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$DecryptedEndPoint.fill(SslConnection.java:718) ~[?:?]
	at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:168) ~[?:?]
	at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:80) ~[?:?]
	at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:131) ~[?:?]
	at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:172) ~[?:?]
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) ~[?:?]
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$DecryptedEndPoint.onFillable(SslConnection.java:555) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection.onFillable(SslConnection.java:410) ~[?:?]
	at org.eclipse.jetty.io.ssl.SslConnection$2.succeeded(SslConnection.java:164) ~[?:?]
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) ~[?:?]
	at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:338) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:315) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:173) ~[?:?]
	at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:131) ~[?:?]
	at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:409) ~[?:?]
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883) ~[?:?]
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034) ~[?:?]
	... 1 more
2023-09-23 16:10:17.699 [ERROR] [ng.lgthinq.internal.api.TokenManager] - Error logging with gateway: LGThinqGateway{empBaseUri='https://ru.emp.lgsmartplatform.com', loginBaseUri='https://ru.m.lgaccount.com/spx', apiRootV1='https://ruic.lgthinq.com:46030/api', apiRootV2='https://ruic-service.lgthinq.com:46030/v1', authBase='https://ru.m.lgaccount.com', language='RU', country='RU', username='', password='', alternativeEmpServer='', accountVersion=0}

You can sabe move forward to 4.1.0 M1.
Can you please check the version of java you are using e n the OH server?
Just run java -version

openjdk version "17.0.8.1" 2023-08-24 LTS
OpenJDK Runtime Environment Zulu17.44+53-CA (build 17.0.8.1+1-LTS)
OpenJDK 64-Bit Server VM Zulu17.44+53-CA (build 17.0.8.1+1-LTS, mixed mode, sharing)

I left in my repo a class to test your connection against the Russian LG server. Please, copy this file to your OH server then run the command:

java -cp . HttpClientTest https://ru.emp.lgsmartplatform.com

Let me know if you have the same error

Link: https://github.com/nemerdaud/openhab-thinq-stuff/blob/main/HttpClientTest.class

Results
https://ru.emp.lgsmartplatform.com : 200

Hi, I have a LG Therma V Monoblok HM 163M U33 air/water heat pump. I am using LG ThinQ app. but I am not able to see energy consumption on the graph :man_shrugging:. Is it possible that my heat pump does not support this option if yes, is there any way i can add something additional to it? Thank you!

We don’t give support to LG ThinQ App. You can ask to LG’s support to see if your device has the energy consumption feature and how to see it in the App.

Hi Nemer!

I have some problem with the ver1 AC in my home. May be the LG API changed?

2024-03-12 18:39:24.129 [ERROR] [ices.LGThinQAbstractApiClientService] - Error reading resource from URI: https://eic.lgthinq.com:46030/api/webContents/modelJSON?modelName=modelJSON_401&countryCode=KR&contentsId=d27c0210-7149-11d3-80b1-a06faae546f9&authKey=thinq
java.net.SocketException: Unexpected end of file from server
	at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:954) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:761) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:951) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:761) ~[?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1688) ~[?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1589) ~[?:?]
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:224) ~[?:?]
	at java.net.URL.openStream(URL.java:1161) ~[?:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.loadDeviceCapability(LGThinQAbstractApiClientService.java:118) [bundleFile:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.getCapability(LGThinQAbstractApiClientService.java:268) [bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.getCapabilities(LGThinQAbstractDeviceHandler.java:271) [bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.updateThingStateFromLG(LGThinQAbstractDeviceHandler.java:465) [bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler$UpdateThingStateFromLG.run(LGThinQAbstractDeviceHandler.java:458) [bundleFile:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) [?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
	at java.lang.Thread.run(Thread.java:840) [?:?]

And then:

2024-03-12 18:39:24.129 [ERROR] [handler.LGThinQAirConditionerHandler] - Error updating thing Nappali/d27c0210-7149-11d3-80b1-a06faae546f9 from LG API. Thing goes OFFLINE until next retry: Error parsing capability registry
org.openhab.binding.lgthinq.internal.errors.LGThinqApiException: Error parsing capability registry
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.getCapability(LGThinQAbstractApiClientService.java:274) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.getCapabilities(LGThinQAbstractDeviceHandler.java:271) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.updateThingStateFromLG(LGThinQAbstractDeviceHandler.java:465) [bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler$UpdateThingStateFromLG.run(LGThinQAbstractDeviceHandler.java:458) [bundleFile:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) [?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
	at java.lang.Thread.run(Thread.java:840) [?:?]
Caused by: org.openhab.binding.lgthinq.internal.errors.LGThinqApiException: Error reading IO interface
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.loadDeviceCapability(LGThinQAbstractApiClientService.java:124) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.getCapability(LGThinQAbstractApiClientService.java:268) ~[bundleFile:?]
	... 9 more
Caused by: java.net.SocketException: Unexpected end of file from server
	at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:954) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:761) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTPHeader(HttpClient.java:951) ~[?:?]
	at sun.net.www.http.HttpClient.parseHTTP(HttpClient.java:761) ~[?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1688) ~[?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1589) ~[?:?]
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:224) ~[?:?]
	at java.net.URL.openStream(URL.java:1161) ~[?:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.loadDeviceCapability(LGThinQAbstractApiClientService.java:118) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.getCapability(LGThinQAbstractApiClientService.java:268) ~[bundleFile:?]
	... 9 more

Something about WorkId not present:

2024-03-12 19:42:25.832 [ERROR] [handler.LGThinQAirConditionerHandler] - Error updating thing GarĂĄzs/d27bb3f0-7149-11d3-80af-a06faae627a8 from LG API. Thing goes OFFLINE until next retry: Error starting device monitor in LG API for the device:d27bb3f0-7149-11d3-80af-a06faae627a8
org.openhab.binding.lgthinq.internal.errors.LGThinqApiException: Error starting device monitor in LG API for the device:d27bb3f0-7149-11d3-80af-a06faae627a8
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.getSnapshotDeviceAdapter(LGThinQAbstractDeviceHandler.java:667) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.updateThingStateFromLG(LGThinQAbstractDeviceHandler.java:465) [bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler$UpdateThingStateFromLG.run(LGThinQAbstractDeviceHandler.java:458) [bundleFile:?]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) [?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
	at java.lang.Thread.run(Thread.java:840) [?:?]
Caused by: java.lang.NullPointerException: Unexpected StartMonitor json result. Node 'workId' not present
	at java.util.Objects.requireNonNull(Objects.java:235) ~[?:?]
	at org.openhab.binding.lgthinq.lgservices.LGThinQAbstractApiClientService.startMonitor(LGThinQAbstractApiClientService.java:433) ~[bundleFile:?]
	at org.openhab.binding.lgthinq.internal.handler.LGThinQAbstractDeviceHandler.getSnapshotDeviceAdapter(LGThinQAbstractDeviceHandler.java:656) ~[bundleFile:?]
	... 8 more

My ver2 devices are working as expected. All devices are correct in Thinq App.

I don’t think the API v1 has been changed because if so, it’s break previous version of the LG Thinq App and the mining of the API versioning itself. If they changes the API, then the changes come in a new version, not in some current released one.
I have V1 & V2 devices and for me, there are no problems. But, LG have regional API’s serving the world and bugs/instabilities happens regionally.
Other point is the API V1 don’t work properly when you have more then one source (LG Thinq APP & This Bingind) consulting the devices status at the same time and may cause unexpected behavior in the binding because the binding doesn’t handle this case of racing.
Then, I suggest you to:

  1. Stop (hardly) the LG App
  2. wait 10 minutes
  3. Stop the AC Thing and the Bridge in the sequence
  4. Restart the Bridge and the AC Thing.

See if the problem persist or is fixed.

Just to Clarify the error, this Exception occurs when the server open the connection and stop in the sequence without sending any payload. This is most likely a bug in the server or network traffic problems (firewall, router, etc).

1 Like