jsiegenthaler / homebridge-eosstb

A homebridge plugin for the EOS set-top box as used by Sunrise, Telenet, Ziggo, Virgin Media and maybe more in various countries on the Horizon Go (HGO) platform
https://github.com/jsiegenthaler/homebridge-eosstb
32 stars 4 forks source link

Telenet box fully operational after changing code in index.js #120

Closed MartiMan79 closed 4 weeks ago

MartiMan79 commented 1 month ago

Describe The Bug:

Expected behavior:

Issue:

const countryBaseUrlArray = {
    //https://spark-prod-be.gnp.cloud.telenet.tv/be/en/config-service/conf/web/backoffice.json
    //'be-fr':  'https://prod.spark.telenet.tv',
    //'be-nl':  'https://prod.spark.telenet.tv',    
    'be':       'https://spark-prod-be.gnp.cloud.telenet.tv', // verified 14.01.2024
                // https://spark-prod-ch.gnp.cloud.sunrisetv.ch/ch/en/config-service/conf/web/backoffice.json

Solution:

const countryBaseUrlArray = {

    //https://spark-prod-be.gnp.cloud.telenet.tv/be/en/config-service/conf/web/backoffice.json

    'be-fr':    'https://spark-prod-be.gnp.cloud.telenet.tv',

    'be-nl':    'https://spark-prod-be.gnp.cloud.telenet.tv',   

I ended up with a, for me, fully functioning plugin, On-Off and channel switching fully working.

jsiegenthaler commented 1 month ago

Thanks, I'll put this into a beta now and publish it. I cannot test myself, but if you could that would be great

jsiegenthaler commented 4 weeks ago

@MartiMan79 I have published v2.3.2-beta.1 with your changes in it (and a bunch of dependency updates). Please try it and report back.

jsiegenthaler commented 4 weeks ago

Similar to the issue reported in https://github.com/jsiegenthaler/homebridge-eosstb/issues/117

MartiMan79 commented 4 weeks ago

Similar to the issue reported in #117

Indeed, I thought that issue made you create the ‘be’ entry that was not functioning. Therefore I created this one.

MartiMan79 commented 4 weeks ago

My joy was short lived. Have no idea what happened overnight...

[15/06/2024, 12:50:39] [EOSSTB] API event: shutdown
[15/06/2024, 12:50:39] [EOSSTB] Shutting down mqttClient...
[15/06/2024, 12:50:39] [EOSSTB] Goodbye
[15/06/2024, 12:50:44] [EOSSTB] Child bridge process ended
[15/06/2024, 12:50:44] [EOSSTB] Process Ended. Code: 143, Signal: null
[15/06/2024, 12:50:51] [EOSSTB] Restarting Process...
[15/06/2024, 12:50:52] [EOSSTB] Launched child bridge with PID 1720315
[15/06/2024, 12:50:53] [EOSSTB] Loaded homebridge-eosstb v2.3.1 child bridge successfully
[15/06/2024, 12:50:53] [EOSSTB] homebridge-eosstb v2.3.1, node v20.14.0, homebridge v1.8.2
[15/06/2024, 12:50:53] [EOSSTB] API event: didFinishLaunching
[15/06/2024, 12:50:53] [EOSSTB] WARNING: Session watchdog disabled
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): Started watchdog instance 1
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): Session and mqtt not connected, sessionWatchdog(1) will try to connect now...
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): Status: sessionWatchdogRunning=true
[15/06/2024, 12:50:53] [EOSSTB] Session DISCONNECTED. Starting session connection process
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): Attempting to create session
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): ++++ step 1: calling config service
[15/06/2024, 12:50:53] [EOSSTB] Retrieving config for countryCode be-nl
[15/06/2024, 12:50:53] [EOSSTB] getConfig: GET undefined/be/en/config-service/conf/web/backoffice.json
[15/06/2024, 12:50:53] [EOSSTB] getConfig error: AxiosError [AggregateError]: 
[15/06/2024, 12:50:53] [EOSSTB] Failed to get config - ECONNREFUSED: 
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): ++++++ End of promise chain
[15/06/2024, 12:50:53] [EOSSTB] sessionWatchdog(1): Exiting sessionWatchdog

Back to square 1

jsiegenthaler commented 4 weeks ago

Don't panic. that's caused by this: getConfig: GET undefined/be/en/config-service/conf/web/backoffice.json I'll look at my code

jsiegenthaler commented 4 weeks ago

Definitely a bug, I can reproduce the issue. I'll fix it now

jsiegenthaler commented 4 weeks ago

@MartiMan79 Fixed in 2.3.2-beta.2, published just now. Please try and report back

MartiMan79 commented 4 weeks ago

Don't panic. that's caused by this: getConfig: GET undefined/be/en/config-service/conf/web/backoffice.json I'll look at my code

But this was when I reverted to the 2.3.1 version... Well, it works again with your new beta!

Although it's functional in the Homebridge accessories page, only the child bridge gets published in the Home app, the TV itself isn't... I created a new child bridge after deleting the bridge in the home app, restarted Homebridge multiple times but no change. I assume that's a Homebridge issue and not the plugin?

jsiegenthaler commented 4 weeks ago

Child Bridge config is a Homebridge thing, nothing to do with the plugin. You may need to delete previous versions of the TV accessory: Homebridge > Settings > Reset > Unpair Bridges / Cameras / TVs / External Accessories Delete any previous paired Tv_set_top_boxes from the plugin and try again

MartiMan79 commented 4 weeks ago

Sadly I exactly did all of that. Had issues like this before, will dig deeper and maybe start fresh. Your plugin is the only reason that I have Homebridge running so really happy to see it working!

S7-1200 <-> ioBroker <-> Yahka user here😉

jsiegenthaler commented 4 weeks ago

Does the plugin properly start, authenticate, and show that it is connected to MQTT? If so, then the plugin is working fine. It will be a HomeKit or Homebridge issue

jsiegenthaler commented 4 weeks ago

It often helps to force close the Home app and reopen it, then wait a few minutes before adding a new accessory to allow the Home app to see the accessory in the network

MartiMan79 commented 4 weeks ago

Believe me, I tried everything, deleting HB cache, using iPad instead of iPhone, deleted the entries in the HB accessories folder,... No difference.

It was fully working from the Homebridge accessories page. I had to use "Reset Homebridge Accessory" in settings and bind "everything" (only your plugin lol) in the Home app again.

Now everything works again! Thanks!

jsiegenthaler commented 4 weeks ago

Good to hear that it works. I'll close the issue and then update everything to a non-beta version tonight

MartiMan79 commented 4 weeks ago

Good to hear that it works. I'll close the issue and then update everything to a non-beta version tonight

Take your time, I’m already happy😉

jsiegenthaler commented 4 weeks ago

Fixed in v2.3.2