web.fileBrowse stopped working in CLI as as working in IDE

after " npm install oxygen-cli -g"
I’m running a test that uses fileBrowse .

in CLI = error: [oxygen] 2019-09-24T15:26:57.999Z WARN webdriver: Request failed due to element not interactable
(Session info: chrome=77.0.3865.90)

in IDE = PASS

Thanks to the respondents .

We’ve just released oxygen-cli update (v0.48.4) which has a workaround for this issue.
Please update with npm install oxygen-cli -g.

The reason you were getting the above error, is because input element is disabled. And due to internal changes in oxygen-cli, using fileBrowse with disabled elements is not possible anymore.

As a workaround you can use makeVisible comammand before fileBrowse to make the element interactable:

web.makeVisible('/html/body/form[1]/input[1]');
web.fileBrowse('/html/body/form[1]/input[1]', 'C:\\image.jpg');

The reason it works in IDE, is because IDE is still using old version of oxygen-cli. New IDE version will be released in the following days, and will also require using the makeVisible workaround.

1 Like

thank you very much :grinning: @romovs .

If you can please answer me about this problem cli-data-bases ?

1 Like