Skip to content

Renew Session Script Not Working #256

Description

@amadejvidic

Describe the bug
I have a problem renewing my developer session. First, let's start with what works:

  • Selecting the "Extend Session Time" via the remote on the TV app "Developer Mode"
  • Clicking the "Renew session" button under the Info tab in the webOS Dev Manager on MacOS/Windows

In both instances, the "Dev Mode Session" timer on the TV resets automatically, without closing the app, rebooting TV, etc.

What doesn't work

What happens
The call above gives the following response: {"result":"success","errorCode":"200","errorMsg":"GNL"}

The request can be verified and looks like it did something:
GET https://developer.lge.com/secure/CheckDevModeSession.dev?sessionToken=xxxxxxxxx
RESPONSE: {"result":"success","errorCode":"200","errorMsg":"999:58:40"}

The problem
The timer on the TV does not get updated/refreshed and keeps counting down like nothing happened. No, rebooting the TV does not help.
I'm certain that the "Renew session" button does something different than just sending this GET request to the developer.lge.com. I was trying to inspect the source code but I couldn't find what actually happens since I'm not too familiar with JS and its libraries.

I found this code and came to dead end:

async renewDevMode(): Promise<void> {
    const device = this.device;
    if (!device) return;
    await this.deviceManager.extendDevMode(device);
    await this.loadDevModeInfo(device);
}

async extendDevMode(device: Device): Promise<any> {
    return await this.luna.call(device, 'luna://com.webos.applicationManager/launch', {
        id: 'com.palmdts.devmode',
        subscribe: false,
        params: {extend: true}
    }, true);
}

Please help me understand what this button does so we can find the solution for my automation script.

Additional context

  • OS: MacOS, Windows, Linux (for the HTTP requests I used Chrome, Postman, and Curl with the same outcome)
  • LG OLED65C21LA
  • WebOS: 8.3.0
  • OTA ID: HE_DTV_W22O_AFABATPU
  • SoC: o22
  • NOT Rooted
  • WebOS dev manager: Version 1.99.3 (20240522.151732)
  • Source of the token is cat /var/luna/preferences/devmode_enabled

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions