cancel
Showing results for 
Search instead for 
Did you mean: 

Error with JavaScript invoker after edge update 150.0.4078.48

tommar
Level 3

Hello, we are currently getting an Error with one of are Edge browser process's when it tries to invoke JavaScript. We are getting the error: 

ERROR: Internal : Failed to perform step 2 in Navigate Stage 'Inject and run cookie javascript' on page 'Login' - JavaScript invoker returned the following error message: Attempted to Invoke JavaScript without Web Driver

 The Web Driver, and Edge version appear to be the same version (150).

tommar_0-1783507188065.pngtommar_3-1783509179780.png

 

 

The navigation stage throwing the error itself is made up of 2 parts. 

The first action is a insert JavaScript function which sets up the script we run, the second stage is a invoke JavaScript function which executes the function set in stage 1 (the script is stored in the data item [JS-MODSESSION]). They both run against the root of the website.

tommar_1-1783508303215.pngtommar_2-1783508311695.png

The Script it uses is the following (for context this script is used to grab the current session token, so we can use the website's API to carry some tasks where the website interface itself is unsuitable for spying):

function createAndPopulateMODSESSIONTextBox() {
// 1. Get the MODSESSION value
const modSessionValue = document.cookie;

// 2. Create the text box element
const modSessionTextBox = document.createElement('input');

// 3. Set attributes for the text box
modSessionTextBox.type = 'text';
modSessionTextBox.id = 'MODSESSION'; // Assign an ID for easy reference
modSessionTextBox.readOnly = true; // Make it read-only if you just want to display the value
modSessionTextBox.value = modSessionValue; // Set the retrieved value

const label = document.createElement('label');
label.htmlFor = 'MODSESSION';
label.textContent = 'MODSESSION: ';
document.body.appendChild(label);
document.body.appendChild(modSessionTextBox);
}

Any help would be appreciated. 

 

 

 

0 REPLIES 0