Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while running .sendKeysToElement() protocol action: keys.split is not a function #4280

Closed
reallymello opened this issue Oct 23, 2024 · 5 comments · Fixed by #4293
Closed

Comments

@reallymello
Copy link
Contributor

Description of the bug/issue

When I send a large text string (~4,101 characters) using setValue or sendKeys to a textArea element I expect the text to be entered into the control, but instead I receive error

Error while running .sendKeysToElement() protocol action: keys.split is not a function
 TimeoutError
 An error occurred while running .sendKeys() command on <Element [name=@noteTextInput]>: keys.split is not a function
  {"error":{},"status":-1,"value":null}

Steps to reproduce

When running locally in Windows I don't see the error in my console, but I see it when observing both the normal and verbose logs in BrowserStack running the test on a linux agent.

This occurs when I run the lines of code in the sample test below

Sample test

await desktopFileNotesPage
      .waitForElementVisible('@categoryInput', 60000)
      .setValue('@categoryInput', ['Investigation', browser.Keys.TAB])
      .setValue('@subCategoryInput', ['Documentation', browser.Keys.TAB])
      .setValue('@accessInput', ['Company', browser.Keys.TAB])
      .updateValue('@noteSubjectInput', [
        'Second Original file note',
        browser.Keys.TAB,
      ])
      .pause(200); // Slide out animation delay;

    await desktopFileNotesPage.expect
      .element('@noteTextInput')
      .to.be.visible.before(30000);

    await desktopFileNotesPage
      .sendKeys('@noteTextInput', [
        'On August 7th there was a accident reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accidentOn August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident',
        browser.Keys.TAB,
      ])
      .setValue(
        '@claimantLineInput',
        'Darcy Jacobs / Loss of Use, Darcy Jacobs / Collision'
      )
      .clickAndWait('@notifyPerformerLinkButton')
      .expect.element('@notifyPerformerList')
      .to.be.visible.before(30000);

Command to run

npx nightwatch text.ts

Verbose Output

Can send the entire log to a private address, but here is the area around the error

2024-10-23T21:33:32.6269044Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/clear  
2024-10-23T21:33:32.6269805Z {}
2024-10-23T21:33:32.6270887Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/clear (68ms)
2024-10-23T21:33:32.6271688Z    { value: null }
2024-10-23T21:33:32.6272776Z    Request GET http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/property/value  
2024-10-23T21:33:32.6273321Z 
2024-10-23T21:33:32.6274447Z    Response 200 GET http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/property/value (14ms)
2024-10-23T21:33:32.6275263Z    { value: '' }
2024-10-23T21:33:32.6276344Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/clear  
2024-10-23T21:33:32.6277236Z {}
2024-10-23T21:33:32.6278332Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/clear (39ms)
2024-10-23T21:33:32.6279133Z    { value: null }
2024-10-23T21:33:32.6280224Z    Request GET http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/property/value  
2024-10-23T21:33:32.6280771Z 
2024-10-23T21:33:32.6282258Z    Response 200 GET http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/property/value (13ms)
2024-10-23T21:33:32.6283097Z    { value: '' }
2024-10-23T21:33:32.6284203Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/value  
2024-10-23T21:33:32.6284964Z    {
2024-10-23T21:33:32.6285632Z      text: 'Second Original file note',
2024-10-23T21:33:32.6286179Z      value: [
2024-10-23T21:33:32.6286824Z        'S', 'e', 'c', 'o', 'n', 'd',
2024-10-23T21:33:32.6287466Z        ' ', 'O', 'r', 'i', 'g', 'i',
2024-10-23T21:33:32.6288095Z        'n', 'a', 'l', ' ', 'f', 'i',
2024-10-23T21:33:32.6288701Z        'l', 'e', ' ', 'n', 'o', 't',
2024-10-23T21:33:32.6289298Z        'e', ''
2024-10-23T21:33:32.6289791Z      ]
2024-10-23T21:33:32.6290280Z   }
2024-10-23T21:33:32.6291356Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1159/value (70ms)
2024-10-23T21:33:32.6292299Z    { value: null }
2024-10-23T21:33:32.6293241Z  → Completed command: updateValue ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}, {0, 1}) (225ms)
2024-10-23T21:33:32.6293921Z  
2024-10-23T21:33:32.6294507Z  → Running command: pause (200)
2024-10-23T21:33:32.6599131Z  → Completed command: pause (200) (201ms)
2024-10-23T21:33:32.6600165Z  
2024-10-23T21:33:32.6601265Z  → Running command: expect.element ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...})
2024-10-23T21:33:32.6602592Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements  
2024-10-23T21:33:32.6603584Z    { using: 'css selector', value: '[id$="radEdNote_contentDiv"]' }
2024-10-23T21:33:32.6792124Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements (19ms)
2024-10-23T21:33:32.6793081Z    {
2024-10-23T21:33:32.6793536Z      value: [
2024-10-23T21:33:32.6793966Z        {
2024-10-23T21:33:32.6794718Z          'element-6066-11e4-a52e-4f735466cecf': 'f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1187'
2024-10-23T21:33:32.6795331Z        }
2024-10-23T21:33:32.6795892Z      ]
2024-10-23T21:33:32.6796308Z   }
2024-10-23T21:33:32.6797181Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/execute/sync  
2024-10-23T21:33:32.6797839Z    {
2024-10-23T21:33:32.6798491Z      script: '/* isDisplayed */return (function(){return (function(){var g=this||self;\n' +
2024-10-23T21:33:32.6799612Z        'function aa(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Ob... (16987 characters)',
2024-10-23T21:33:32.6800231Z      args: [
2024-10-23T21:33:32.6800655Z        {
2024-10-23T21:33:32.6801399Z          'element-6066-11e4-a52e-4f735466cecf': 'f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1187',
2024-10-23T21:33:32.6802232Z          ELEMENT: 'f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1187'
2024-10-23T21:33:32.6802752Z        }
2024-10-23T21:33:32.6803159Z      ]
2024-10-23T21:33:32.6803564Z   }
2024-10-23T21:33:32.6976550Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/execute/sync (18ms)
2024-10-23T21:33:32.6977466Z    { value: *** }
2024-10-23T21:33:32.6978144Z   ✔ Expected element @noteTextInput <[id$="radEdNote_contentDiv"]> to be visible in 30000ms (38ms)
2024-10-23T21:33:32.6978992Z  → Completed command: expect.element ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}) (38ms)
2024-10-23T21:33:32.7001028Z  
2024-10-23T21:33:32.7002206Z  → Running command: sendKeys ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}, {0, 1})
2024-10-23T21:33:32.7003348Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements  
2024-10-23T21:33:32.7004210Z    { using: 'css selector', value: '[id$="radEdNote_contentDiv"]' }
2024-10-23T21:33:32.7158103Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements (15ms)
2024-10-23T21:33:32.7159367Z    {
2024-10-23T21:33:32.7159890Z      value: [
2024-10-23T21:33:32.7160559Z        {
2024-10-23T21:33:32.7161614Z          'element-6066-11e4-a52e-4f735466cecf': 'f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1187'
2024-10-23T21:33:32.7162276Z        }
2024-10-23T21:33:32.7162855Z      ]
2024-10-23T21:33:32.7163342Z   }
2024-10-23T21:33:32.7164073Z     Error   Error while running .sendKeysToElement() protocol action: keys.split is not a function
2024-10-23T21:33:32.7164424Z 
2024-10-23T21:33:37.7367083Z   TimeoutError
2024-10-23T21:33:37.7368520Z    An error occurred while running .sendKeys() command on <Element [name=@noteTextInput]>: keys.split is not a function
2024-10-23T21:33:37.7369525Z     {"error":{},"status":-1,"value":null}
2024-10-23T21:33:37.7369801Z 
2024-10-23T21:33:37.7370175Z     Error location:
2024-10-23T21:33:37.7370717Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:331
2024-10-23T21:33:37.7371554Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:33:37.7371994Z      329 | 
2024-10-23T21:33:37.7372379Z      330 |     await desktopFileNotesPage
2024-10-23T21:33:37.7372913Z      331 |       .sendKeys('@noteTextInput', [ 
2024-10-23T21:33:37.7381305Z      332 |         'On August 7th there was a accident reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accidentOn August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident',
2024-10-23T21:33:37.7387055Z      333 |         browser.Keys.TAB,
2024-10-23T21:33:37.7387638Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:33:37.7387933Z 
2024-10-23T21:33:37.7388662Z  → Completed command: sendKeys ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}, {0, 1}) (5034ms)
2024-10-23T21:33:37.7389251Z  
2024-10-23T21:33:37.7390064Z  → Running command: setValue ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}, 'Darcy Jacobs / Loss of Use, Darcy Jacobs / Collision')
2024-10-23T21:33:37.7391290Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements  
2024-10-23T21:33:37.7392073Z    { using: 'css selector', value: '[id$="cboClaimantLine_Input"]' }
2024-10-23T21:33:37.7701213Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/elements (32ms)
2024-10-23T21:33:37.7702270Z    {
2024-10-23T21:33:37.7702584Z      value: [
2024-10-23T21:33:37.7703212Z        {
2024-10-23T21:33:37.7703958Z          'element-6066-11e4-a52e-4f735466cecf': 'f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1147'
2024-10-23T21:33:37.7704778Z        }
2024-10-23T21:33:37.7705134Z      ]
2024-10-23T21:33:37.7705465Z   }
2024-10-23T21:33:37.7706418Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.F6C0082E907F010377A15828351D46D3.d.17D73B66C737A2EC431C5855A5A18EC6.e.1147/clear  
2024-10-23T21:33:37.7707095Z {}


....


2024-10-23T21:34:05.9403367Z    Request POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.33F676B2EE36E3903BC0F535B937AD61.d.98AC67A1137DA80EBD81956C808B1F1C.e.2041/click  
2024-10-23T21:34:05.9404338Z {}
2024-10-23T21:34:06.3522529Z    Response 200 POST http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968/element/f.33F676B2EE36E3903BC0F535B937AD61.d.98AC67A1137DA80EBD81956C808B1F1C.e.2041/click (411ms)
2024-10-23T21:34:06.3524056Z    { value: null }
2024-10-23T21:34:06.3525467Z  → Completed command: click ({name, __index, __selector, locateStrategy, pseudoSelector, parent, resolvedElement, abortOnFailure, suppressNotFoundErrors, timeout...}) (427ms)
2024-10-23T21:34:06.3526203Z  → Completed [afterEach].
2024-10-23T21:34:06.3526454Z 
2024-10-23T21:34:06.3526856Z   FAILED: 1 assertions failed, 1 errors and  63 passed (2m 0s / 120023ms)
2024-10-23T21:34:06.3527409Z  → Running [after]:
2024-10-23T21:34:06.3557680Z  
2024-10-23T21:34:06.3558569Z  → Running command: end ()
2024-10-23T21:34:06.3585723Z  
2024-10-23T21:34:06.3586696Z  → Running command: session ('delete', [Function])
2024-10-23T21:34:06.3587662Z    Request DELETE http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968  
2024-10-23T21:34:06.3588073Z 
2024-10-23T21:34:06.7612999Z    Response 200 DELETE http://browserstack-turboscale-grid-service.nightwatch-grid-rnd-dct.svc.cluster.local:4444/wd/hub/session/0a2743de-104c-4b45-b5aa-57fc007a1968 (401ms)
2024-10-23T21:34:06.7614010Z    { value: null }
2024-10-23T21:34:06.7614571Z  → Completed command: end () (405ms)
2024-10-23T21:34:06.7615247Z  → Completed command: session ('delete', [Function]) (403ms)
2024-10-23T21:34:06.7615839Z  → Completed [after].
2024-10-23T21:34:06.7628724Z    Request GET https://api.browserstack.com:4444/automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json  
2024-10-23T21:34:07.3772143Z   Error
2024-10-23T21:34:07.3776245Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:07.3778711Z AggregateError
2024-10-23T21:34:07.3779188Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:07.3779702Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:07.3780229Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:07.4747533Z    Request GET https://api.browserstack.com:4444/automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json  (retry 1) 
2024-10-23T21:34:07.9838276Z   Error
2024-10-23T21:34:07.9841623Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:07.9842303Z AggregateError
2024-10-23T21:34:07.9842749Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:07.9843257Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:07.9843781Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:08.0860421Z    Request GET https://api.browserstack.com:4444/automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json  (retry 2) 
2024-10-23T21:34:08.6196379Z   Error
2024-10-23T21:34:08.6198753Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:08.6199593Z AggregateError
2024-10-23T21:34:08.6200082Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:08.6200602Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:08.6201133Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:08.6201594Z   AggregateError
2024-10-23T21:34:08.6201961Z    
2024-10-23T21:34:08.6549857Z 
2024-10-23T21:34:08.6552016Z ───────────────────────────────────────────────────────────────────────────────────────────────────
2024-10-23T21:34:08.6552521Z 
2024-10-23T21:34:08.6553503Z   ️TEST FAILURE (2m 34s): 
2024-10-23T21:34:08.6554379Z    - 1 error during execution; 
2024-10-23T21:34:08.6555182Z    - 1 assertions failed; 68 passed
2024-10-23T21:34:08.6555962Z 
2024-10-23T21:34:08.6556854Z    ✖ 1) Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B
2024-10-23T21:34:08.6557401Z 
2024-10-23T21:34:08.6557954Z    – Verify FT713_File_Note_Foldering (2m 0s)
2024-10-23T21:34:08.6558218Z 
2024-10-23T21:34:08.6558672Z    → ✖ NightwatchAssertError
2024-10-23T21:34:08.6559353Z    Expected element @saveButton <[id$="btnSave"]> to not be present - expected "not present" but got: "present" (5228ms)
2024-10-23T21:34:08.6559708Z 
2024-10-23T21:34:08.6560026Z     Error location:
2024-10-23T21:34:08.6560566Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:398
2024-10-23T21:34:08.6561280Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:08.6561919Z      396 |       .waitForInProgressOverlay(30000, 'Set file upload 2')
2024-10-23T21:34:08.6562501Z      397 |       .clickAndWait('@saveButton')
2024-10-23T21:34:08.6563097Z      398 |       .expect.element('@saveButton').to.not.be.present; 
2024-10-23T21:34:08.6563524Z      399 | 
2024-10-23T21:34:08.6563935Z      400 |     await browser.frameParent().frame(0);
2024-10-23T21:34:08.6564546Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:08.6564824Z 
2024-10-23T21:34:08.6564958Z 
2024-10-23T21:34:08.6565370Z   - OTHER ERRORS:
2024-10-23T21:34:08.6565744Z   Error
2024-10-23T21:34:08.6566102Z     TimeoutError
2024-10-23T21:34:08.6566603Z    An error occurred while running .sendKeys() command on <Element [name=@noteTextInput]>: keys.split is not a function
2024-10-23T21:34:08.6567219Z     {"error":{},"status":-1,"value":null}
2024-10-23T21:34:08.6567519Z 
2024-10-23T21:34:08.6567861Z     Error location:
2024-10-23T21:34:08.6568385Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:331
2024-10-23T21:34:08.6569292Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:08.6569724Z      329 | 
2024-10-23T21:34:08.6570119Z      330 |     await desktopFileNotesPage
2024-10-23T21:34:08.6570664Z      331 |       .sendKeys('@noteTextInput', [ 
2024-10-23T21:34:08.6579155Z      332 |         'On August 7th there was a accident reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accidentOn August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident',
2024-10-23T21:34:08.6584451Z      333 |         browser.Keys.TAB,
2024-10-23T21:34:08.6585009Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:08.6585245Z 
2024-10-23T21:34:08.6585440Z 
2024-10-23T21:34:08.6626199Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197
2024-10-23T21:34:08.6626869Z Reporting statuses to BrowserStack
2024-10-23T21:34:08.9489341Z Updated BrowserStack statuses for tests
2024-10-23T21:34:09.0055792Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=250
2024-10-23T21:34:09.4115113Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=500
2024-10-23T21:34:09.7108904Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=750
2024-10-23T21:34:10.4004095Z   🚂 Test result successfully posted to TestRail
2024-10-23T21:34:10.4005288Z Finished reporting.
2024-10-23T21:34:11.7673520Z Tailing or re-tailing logs...
2024-10-23T21:34:11.9774960Z   Error
2024-10-23T21:34:11.9776485Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:11.9777191Z AggregateError
2024-10-23T21:34:11.9777752Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:11.9778370Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:11.9779193Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:11.9781246Z    Request GET https://api.browserstack.com:4444/automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json  (retry 1) 
2024-10-23T21:34:11.9782434Z   Error
2024-10-23T21:34:11.9783802Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:11.9784827Z AggregateError
2024-10-23T21:34:11.9785680Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:11.9786641Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:11.9787602Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:11.9789079Z    Request GET https://api.browserstack.com:4444/automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json  (retry 2) 
2024-10-23T21:34:11.9790150Z   Error
2024-10-23T21:34:11.9791373Z       GET https://api.browserstack.com:4444 /automate/sessions/0a2743de-104c-4b45-b5aa-57fc007a1968.json - ETIMEDOUT
2024-10-23T21:34:11.9792407Z AggregateError
2024-10-23T21:34:11.9793165Z     at internalConnectMultiple (node:net:1122:18)
2024-10-23T21:34:11.9793987Z     at internalConnectMultiple (node:net:1190:5)
2024-10-23T21:34:11.9795214Z     at Timeout.internalConnectMultipleTimeout (node:net:1716:5)
2024-10-23T21:34:11.9796020Z   AggregateError
2024-10-23T21:34:11.9796695Z    
2024-10-23T21:34:11.9797078Z 
2024-10-23T21:34:11.9798151Z ───────────────────────────────────────────────────────────────────────────────────────────────────
2024-10-23T21:34:11.9798641Z 
2024-10-23T21:34:11.9799389Z   ️TEST FAILURE (2m 34s): 
2024-10-23T21:34:11.9800218Z    - 1 error during execution; 
2024-10-23T21:34:11.9801047Z    - 1 assertions failed; 68 passed
2024-10-23T21:34:11.9801514Z 
2024-10-23T21:34:11.9873434Z    ✖ 1) Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B
2024-10-23T21:34:11.9874484Z 
2024-10-23T21:34:11.9875821Z    – Verify FT713_File_Note_Foldering (2m 0s)
2024-10-23T21:34:11.9876205Z 
2024-10-23T21:34:11.9876853Z    → ✖ NightwatchAssertError
2024-10-23T21:34:11.9877755Z    Expected element @saveButton <[id$="btnSave"]> to not be present - expected "not present" but got: "present" (5228ms)
2024-10-23T21:34:11.9878246Z 
2024-10-23T21:34:11.9878611Z     Error location:
2024-10-23T21:34:11.9879095Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:398
2024-10-23T21:34:11.9879733Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:11.9880285Z      396 |       .waitForInProgressOverlay(30000, 'Set file upload 2')
2024-10-23T21:34:11.9880776Z      397 |       .clickAndWait('@saveButton')
2024-10-23T21:34:11.9881286Z      398 |       .expect.element('@saveButton').to.not.be.present; 
2024-10-23T21:34:11.9881665Z      399 | 
2024-10-23T21:34:11.9882032Z      400 |     await browser.frameParent().frame(0);
2024-10-23T21:34:11.9882573Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:11.9882818Z 
2024-10-23T21:34:11.9882989Z 
2024-10-23T21:34:11.9883593Z   - OTHER ERRORS:
2024-10-23T21:34:11.9883924Z   Error
2024-10-23T21:34:11.9884242Z     TimeoutError
2024-10-23T21:34:11.9884683Z    An error occurred while running .sendKeys() command on <Element [name=@noteTextInput]>: keys.split is not a function
2024-10-23T21:34:11.9885227Z     {"error":{},"status":-1,"value":null}
2024-10-23T21:34:11.9885438Z 
2024-10-23T21:34:11.9885751Z     Error location:
2024-10-23T21:34:11.9886211Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:331
2024-10-23T21:34:11.9886824Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:11.9887196Z      329 | 
2024-10-23T21:34:11.9887549Z      330 |     await desktopFileNotesPage
2024-10-23T21:34:11.9888015Z      331 |       .sendKeys('@noteTextInput', [ 
2024-10-23T21:34:11.9895135Z      332 |         'On August 7th there was a accident reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accidentOn August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident',
2024-10-23T21:34:11.9899910Z      333 |         browser.Keys.TAB,
2024-10-23T21:34:11.9900446Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:34:11.9900663Z 
2024-10-23T21:34:11.9900791Z 
2024-10-23T21:34:11.9901117Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197
2024-10-23T21:34:11.9901530Z Reporting statuses to BrowserStack
2024-10-23T21:34:11.9901909Z Updated BrowserStack statuses for tests
2024-10-23T21:34:11.9902329Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=250
2024-10-23T21:34:11.9902815Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=500
2024-10-23T21:34:11.9903295Z https://redactedco.testrail.io/index.php?/api/v2/get_tests/4197&limit=250&offset=750
2024-10-23T21:34:11.9903833Z   🚂 Test result successfully posted to TestRail
2024-10-23T21:34:11.9904217Z Finished reporting.
2024-10-23T21:34:12.1920917Z Final Pod Status:  Failed
2024-10-23T21:34:12.3096943Z ##[section]Finishing: Tail Job Logs

Nightwatch Configuration

No response

Nightwatch.js Version

3.7

Node Version

20

Browser

Chrome

Operating System

Linux

Additional Information

No response

@garg3133
Copy link
Member

@reallymello Is this issue happening after you set the file detector?

"Error while running .sendKeysToElement() protocol action:" tells that this issue is coming from Selenium and on checking the selenium-webdriver package, there's only one place keys.split occurs (in the sendKeys implementation here).

So, this seems to be a bug on Selenium's side where because you are using a file detector, everything you send through sendKeys() is considered to be a file first. Now, normally the text sent through sendKeys() is not too big so a ENOENT error is thrown while trying to read the file, which the file detector handles explicitly here. But, in case the text is too long, a different error ENAMETOOLONG is thrown which the file detector does not handle, finally leading to the .split function being used on an Array instead of a string (when the file detector throws an error, keys remain an Array as before and does not change to a string here).

Also, this is not reproducible locally because a file detector only comes into effect when tests are being run on a remote selenium hub (BrowserStack here).

So, this issue would need to be raised in Selenium.

@reallymello
Copy link
Contributor Author

Your explanation makes sense, but what is strange and makes me question still is that the error in Nightwatch references the sendKeys command on a text entry field and not when setting the filepath on the file attachment input where presumably the file detector would have been used.

2024-10-23T21:33:37.7367083Z   TimeoutError
2024-10-23T21:33:37.7368520Z    An error occurred while running .sendKeys() command on <Element [name=@noteTextInput]>: keys.split is not a function
2024-10-23T21:33:37.7369525Z     {"error":{},"status":-1,"value":null}
2024-10-23T21:33:37.7369801Z 
2024-10-23T21:33:37.7370175Z     Error location:
2024-10-23T21:33:37.7370717Z     /nightwatch/nightwatch/tests/Automation/Functional/RegressionScripts/Features/FT713_FileNoteFoldering_B.ts:331
2024-10-23T21:33:37.7371554Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:33:37.7371994Z      329 | 
2024-10-23T21:33:37.7372379Z      330 |     await desktopFileNotesPage
2024-10-23T21:33:37.7372913Z      331 |       .sendKeys('@noteTextInput', [ 
2024-10-23T21:33:37.7381305Z      332 |         'On August 7th there was a accident reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accidentOn August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident On August 7th there was a accident  reported in the Route 22 near the intersection of Milltown road. Claimant Jane Grey was the driver of Honda accord. She lost control and hit Edward Hunter who was driving a Toyota camry. Edward Hunter was hurt badly. Witness called 911. Deputy Sheriff Tony came to the scene. He found the back of the Toyota camry was damaged. Ambulance was called and Edward was hurried to the hospital. There was shattered glass all over the road. Traffic was diverted to due to the accident',
2024-10-23T21:33:37.7387055Z      333 |         browser.Keys.TAB,
2024-10-23T21:33:37.7387638Z     ––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––
2024-10-23T21:33:37.7387933Z 

@garg3133
Copy link
Member

Actually, Selenium does not care if the sendKeys() command is used with a text field or a file upload field. If a file detector is found, .sendKeys() will always check first if any file by the same name as the text passed to .sendKeys() exists on the system or not, and if it does then it will first upload that file to the remote machine and then send the keys to the input, otherwise, it will just send the keys without uploading anything.

It is then on the browser to check whether the input is a file input or a normal text input. And in case the input is a file input, it will check the remote system (local to the browser) for a file with the same name (which the .sendKeys() command would have already uploaded if it existed) and carry on with the operation, otherwise, the browser won't check for any such file on the remote system and just submit the text.

@garg3133
Copy link
Member

The fix in Selenium is merged now and will be available in its next release: SeleniumHQ/selenium#14663

@garg3133
Copy link
Member

This should be fixed now in Nightwatch v3.9.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants