How to handle

  Рет қаралды 61,474

Naveen AutomationLabs

Naveen AutomationLabs

3 жыл бұрын

#ShadowDom #NaveenAutomationLabs
In this video, I have explained How to handle #ShadowDom elements in Selenium
What is ShadowDom & ShadowRoot in DOM
How to query ShadowDom elements using querySelector
How to create shadow Dom element using JavaScript and execute it using JavaScript Executor in Selenium
GIT REPO FOR THIS EXAMPLE:
github.com/naveenanimation20/...
~~~Subscribe to this channel, and press bell icon to get some interesting videos on Selenium and Automation:
kzbin.info%20Au...
Follow me on my Facebook Page:
/ naveenqtpexpert
Let's join our Automation community for some amazing knowledge sharing and group discussion on Telegram:
t.me/joinchat/COJqZUPB02r5sB7...
Paid courses (Recorded) videos:
naveenautomationlabs.com/reco...
For Java & Selenium - naveenautomationlabs.com/selen...
For API (Manual + Automation) - naveenautomationlabs.com/manua...

Пікірлер: 110
@shankumondal2881
@shankumondal2881 3 жыл бұрын
From no other available internet resources we can get a so clear explanation ever. Thank you Naveen. 👍
@a_l_o_k_1991
@a_l_o_k_1991 Жыл бұрын
That's the right way how to explain concepts...Thanks for this video
@saurabhk2327
@saurabhk2327 3 жыл бұрын
Most awaited topic... Thanks Naveen 👌
@arpitarjaria2784
@arpitarjaria2784 2 жыл бұрын
Amazing explanation of shadow dom. Thanks Naveen
@KuldeepKumar-wu7xx
@KuldeepKumar-wu7xx 3 жыл бұрын
Thanks for sharing Naveen, its very helpful..!!
@afrinfakir7313
@afrinfakir7313 3 жыл бұрын
This is so amazing... Thank you so much Sir
@kavishautomationfactory170
@kavishautomationfactory170 3 жыл бұрын
Thanks Naveen. This is new concept for me. Learned new things today
@vikalpandey937
@vikalpandey937 3 жыл бұрын
Thanks for your quick response 👍 👏 👌 😀
@najiriyas7394
@najiriyas7394 5 ай бұрын
Very good explanation about shadow dom.. Thank you so much 😊
@girishchandramoharana2
@girishchandramoharana2 3 жыл бұрын
Thanks a lot Naveen.....👍👍👍
@MegaSivaganesh
@MegaSivaganesh 3 жыл бұрын
Thanks for covering this topic
@adurianvesh7225
@adurianvesh7225 2 жыл бұрын
Thanks, Naveen. This is a new concept for me. Learned new things.
@pandudamera7211
@pandudamera7211 3 жыл бұрын
Thank you so much made that video brother
@tarang692
@tarang692 Жыл бұрын
Thank You Sir ji...very informative...I was lost and your videos helped me understand.
@rahultripathi2005
@rahultripathi2005 2 жыл бұрын
Beautifully explained in details..
@sunrisesoft7952
@sunrisesoft7952 3 жыл бұрын
Great!!!! thank you so much!
@rssaiganesh
@rssaiganesh Жыл бұрын
Thank you very much for this video. Helped me a lot
@velun4047
@velun4047 2 жыл бұрын
Very helpful for accept all cookies banner.. Thanks Naveen...
@vikalpandey937
@vikalpandey937 3 жыл бұрын
Thank you so much naveen
@sunrisesoft7952
@sunrisesoft7952 3 жыл бұрын
Hello @Naveen I'm facing an issue about the stale element under shadow root, do you have any idea/suggestion? thank you in advance!
@MrDottyrock
@MrDottyrock 2 жыл бұрын
After 12 hrs of debugging SF, I learnt what shadow doms are and got my CI tests working.
@naveenautomationlabs
@naveenautomationlabs 2 жыл бұрын
Awesome!!
@arunbarma1002
@arunbarma1002 5 ай бұрын
Excellent 👌
@SarangHoley
@SarangHoley 3 жыл бұрын
Awaited topic got covered, Thanks Naveen For this 😊👍
@naveenautomationlabs
@naveenautomationlabs 3 жыл бұрын
Most welcome 😊
@waniya-huzzu
@waniya-huzzu 2 жыл бұрын
@@naveenautomationlabs findelements how to handle ?
@snehakakade4504
@snehakakade4504 Жыл бұрын
Hi Naveen .In application we used Angular and web component with Shadow DOM. Can you please suggest which tool is good for this UI automation
@samitbh87
@samitbh87 3 жыл бұрын
Learned a new and much awaited topic !! Thanks Naveen :)
@naveenautomationlabs
@naveenautomationlabs 3 жыл бұрын
Glad to hear that
@asifsaleem7086
@asifsaleem7086 3 жыл бұрын
Javascript error : cannot read property 'shadowroot' of null ............... i facing this all the time plzzz help
@devashishrawat6555
@devashishrawat6555 3 жыл бұрын
I am getting the same error. Please help me with the solution if you found it.
@luikanungo5859
@luikanungo5859 4 күн бұрын
Thank you Naveen!! This helps me a lot 🙏🏻could run my application successfully 😇
@paulr7765
@paulr7765 2 жыл бұрын
Dude I love you. You saved me
@nagarathnadesai
@nagarathnadesai 10 ай бұрын
Hello, I have a drop-down value in shadow root that I need to select. Tried with JS path like you suggested, but the value keeps changing, as it is dynamic. Any way that I can search the value through text? Please let me know. Thank you in advance. Below is my output from console : document.querySelector(‘eds-select’).shadowRoot.querySelector(‘div > ng-select > ng-dropdown-panel > div > div > div > span’) Span contains the text that I am trying to select
@vivekn9856
@vivekn9856 2 жыл бұрын
That's great!! Thank you, Naveen for the video. Please demonstrate how to scroll inside shadowroot element
@mandeeparora5652
@mandeeparora5652 3 жыл бұрын
Thanks for this topic... Really helpful
@naveenautomationlabs
@naveenautomationlabs 3 жыл бұрын
Glad it was helpful!
@suprabathj7843
@suprabathj7843 3 жыл бұрын
Good one👍
@swapnilgujar6398
@swapnilgujar6398 8 ай бұрын
Thanks Naveen for this video. It helped me a lot
@ppk24
@ppk24 3 жыл бұрын
Request you to please explain how to locating elements in shadow DOM using selenium *python*. Thank you Naveen..!!
@ishannavgire6575
@ishannavgire6575 3 жыл бұрын
Hi Naveen, Thank you for covering this topic. Accessing elements inside a shadow DOM works fine for Chrome browser, but it fails for firefox with error “circular object reference”. Did you come across this error by any chance? If yes, how did you resolve it?
@DinuVijayan
@DinuVijayan 3 жыл бұрын
Thanks Naveen for this wonderful video. But a question, while using document.querySelector should we traverse through each node or can we use something relative like relative XPath?
@RoyerAdames
@RoyerAdames 3 жыл бұрын
Thank you that helps
@vasudhakalyane3294
@vasudhakalyane3294 2 жыл бұрын
Thank you so much
@SingaporeChinnodu
@SingaporeChinnodu 3 жыл бұрын
HI Naveen, Telegram link provided in description is not working. Could u tell the group name.
@nisarAhmed_Syed
@nisarAhmed_Syed 2 жыл бұрын
Hi there, I have a test that, I have to select an icon (web element) which will be displayed only when I mouse hover to it , then I have to inspect it.can someone help me out how to do it...before mouse hover to it, it shows another data, by mouse hovering to it I get a icon, which I should click and carry out other process
@gokulnathps8246
@gokulnathps8246 Жыл бұрын
Great
@lattikajagannathan1137
@lattikajagannathan1137 3 жыл бұрын
Shadow-root ( user-agent) is open shadow-root or closed. Can we automate shadow-root (user-agent) elements??
@NehaKumari-hn4uk
@NehaKumari-hn4uk Жыл бұрын
If anyone reading this comment please reply I am automating rahulshetty ecommerce website when I don't use page object model its work perfectly but when I try to automate using page object design pattern the same program doesn't work
@shilpamadabhavi7718
@shilpamadabhavi7718 3 жыл бұрын
Hi Naveen i tried this shadow dom in my application its working for textbox when tried it on select item its working could you please give me some idea on this
@poonamsharma7026
@poonamsharma7026 3 жыл бұрын
Hi Naveen, can we automate shadow-root(user-agent)?
@user-bm8ou1xr6o
@user-bm8ou1xr6o 9 ай бұрын
Hey Naveen, how to apply webdriver wait or any other wait for that instance for shadowDOM elements? PLEASE HELP. My webpage is not loaded and the script is already performing click function
@gilsonsouza8159
@gilsonsouza8159 3 жыл бұрын
Hi Naveen, How are you? I have a question, lets say that inside the shadow-root there is a also. it is a text box where I have to paste a text message. I am facing problems to get there. do you have any idea on how to do it? Also I am trying to handle a dropdown, which I now how to do it with normal xpath elements using JAVA API, but how to do it using JS path? Please help me :) Have a good day Naveen, thank you so much for your videos, it has been helping me a lot
@developerscentre
@developerscentre 2 жыл бұрын
Thank you for the video! How to use waits for dynamically loading elements present under Shadow DOM?
@swapnilkawade
@swapnilkawade 2 жыл бұрын
Naveen Sir. I'm trying tp automate Service Now developer Instance. However when I login and come to Start Building page, the Shadow root does not handle. I tried with same method - putting in console and checking out but getting error: javascript error: Cannot read properties of null (reading 'shadowRoot') Kindly suggest....
@swatishreesahoo2670
@swatishreesahoo2670 Жыл бұрын
Hi Naveen, I followed the steps mentioned to write the path for shado dom element. but getting "org.openqa.selenium.JavascriptException: javascript error: Cannot read properties of null (reading 'shadowRoot')" error
@jimmatrix7244
@jimmatrix7244 2 ай бұрын
Is youtube ad video an example of shadow DOM? If yes, what element is it referencing?
@rsudarsan6690
@rsudarsan6690 2 жыл бұрын
hi Sir, is it possible to create one video like this using python and selenium webdriver and another one with Python Robot Keyword framework as well
@kirankumar-ek5mr
@kirankumar-ek5mr 3 жыл бұрын
Hi Naveen how to open real web cam.. fake camera not working for me.. it just masks with green color in camera.. will you please help me out.. tried all kind of stuffs..
@varadatiwari1343
@varadatiwari1343 Жыл бұрын
Thanks Naveen. It's a very informative video. I followed this and it worked perfectly for me in chrome but the same code doesn't seem to work for Safari. It would be really helpful if you can make a similar video for Safari as well.
@snehabhat4446
@snehabhat4446 Жыл бұрын
Hi Naveen, Could you please teach how to insert shadow DOM elements in list. This is required for my work. Please help. I am using JSPath to identify the shadow DOM elements.
@piyushkotiyal9964
@piyushkotiyal9964 2 жыл бұрын
how can we use waits without driver as we using JSE,pl help naveen
@tulasiramsunkara
@tulasiramsunkara 3 жыл бұрын
Excellent Naveen.... I would like to know what is the purpose of shadow elements...
@lakshmisuprajamaggie
@lakshmisuprajamaggie Жыл бұрын
If input is uploading a file,how can we handle inside nested shadow in python selenium
@YOGESHKUMAR-ce9cd
@YOGESHKUMAR-ce9cd 9 ай бұрын
Even though I follow the same steps in my project the "Check button" is not clicking. Kindly help me on this. what will be the issue?
@rajeshrj67
@rajeshrj67 2 жыл бұрын
Can you help me please... I need to open one downloaded file by clicking on it but that is not working...
@ravishankarharish1345
@ravishankarharish1345 Жыл бұрын
Hi naveen,this was good session.Using this iam trying to operate on drop down but its not woking. It will be good if the session is made on the drop down with out using the select tag inside a shadow root. Thank you
@useme8196
@useme8196 2 жыл бұрын
Hi Naveen, How Can we use shadow root in Implicitly/Explicitly wait.
@macharlaanilkumar6363
@macharlaanilkumar6363 Жыл бұрын
can you please help me in this, iam getting this elow error-------- raise exception_class(message, screen, stacktrace) selenium.common.exceptions.JavascriptException: Message: javascript error: Cannot read properties of null (reading 'shadowRoot')
@ronakraskar5843
@ronakraskar5843 28 күн бұрын
Thanks Naveen.... This is very helpful.... Does this work in headless mode..? It's working in UI mode but I am facing issue while executing this in headless mode in chrome...
@pavankumar-wn9to
@pavankumar-wn9to 3 жыл бұрын
Hi Naveen,. I can see shadow root element is opened but still seeing can not read property 'shadowRoot' of null...any idea on this?
@abhisrag
@abhisrag 3 ай бұрын
Same error did you find a solution ?
@rahulpatil5990
@rahulpatil5990 Жыл бұрын
How can get list of elements by document.queryselectorAll() with selenium ?
@piyushkotiyal9964
@piyushkotiyal9964 2 жыл бұрын
great sir!! cud u pl let me kno how can we use webdriverwait with jse as we are not using driver directly
@kirankumar193
@kirankumar193 3 жыл бұрын
Hello sir, How to do gettext of shadow dom element?
@amaraa42
@amaraa42 11 ай бұрын
Hi Naveen, thank you for the great video it helps a loooot. But I still have problem. I have many shadow root like this DOM. I click one element then navigate to other page. then I was going to locate element. but some reason I cannot locate any element on that new page. I tried reasign jse again or created new one still cannot locate any element from that page. What should I do? Can you advise?
@saurabhgupta3542
@saurabhgupta3542 3 жыл бұрын
I wanted to automate chrome:downloads section once, but I never knew why I was not able to interact with the element. With this video now I know the reason. Thank you for the video Naveen ❤️
@naveenautomationlabs
@naveenautomationlabs 3 жыл бұрын
You're very welcome!
@najiriyas7394
@najiriyas7394 5 ай бұрын
Hi sir.. after using the same way am getting JavascriptException in the console...
@sampurnagadipudi9925
@sampurnagadipudi9925 2 жыл бұрын
Hi Naveen, can u pls share a video on how to perform scroll if we have shadow dom
@bhushandeshpande6246
@bhushandeshpande6246 2 жыл бұрын
Great topic coverage Naveen !!! Thanks a lot... I followed the steps and created JS query in my project, it is working in console, but in test script it is failing with error "Cannot read properties of null (reading 'shadowRoot')". I'm working on selenium 3 with Java. Can you please help??
@shankarlingam4702
@shankarlingam4702 Жыл бұрын
Hi Bhushan, I am also getting the same error may i know whether the issue is fixed and if yes could pls share how it got fixed?
@therealistoptimistic
@therealistoptimistic 2 жыл бұрын
Getting error - org.openqa.selenium.JavascriptException: javascript error: Cannot read property 'click' of null
@shankarlingam4702
@shankarlingam4702 Жыл бұрын
Whether the issue is fixed?
@macharlaanilkumar6363
@macharlaanilkumar6363 Жыл бұрын
@@shankarlingam4702 is this issue fixed
@KonduVenkat1995
@KonduVenkat1995 3 жыл бұрын
Thank's naveen for this video and your're QA community support, and one more I unable to join you're telegram group . How I would join you're Telegram group
@sanjibkumar2390
@sanjibkumar2390 Жыл бұрын
It's such a helpful video thanks Naveen a lot., Team, Please tell me how use get text from a shadow.please it's urgent!!!
@yogeshkale4398
@yogeshkale4398 Жыл бұрын
How to make list of shadow root elements. Is it possible?
@cristianvargas7176
@cristianvargas7176 2 жыл бұрын
There is no better way to get the elements? I think there are too many chain calls
@bihari1422
@bihari1422 2 жыл бұрын
copy js path is life saviour :)
@rahulgada
@rahulgada Жыл бұрын
Hello Naveen...I am able to enter the value but i am not able to see them in input field on UI but when i go and see in the inspector, under value tag the value is getting stored but not displaying on UI what could be the issue, appreciate anyone's help🙏🙏🙏
@piju6036
@piju6036 8 ай бұрын
Since you already got the WebElement by casting the shadow DOM object you can use .sendKeys() method with it.
@kamalkishoresingh9532
@kamalkishoresingh9532 3 жыл бұрын
HI Naveen can we do similar in webdriverio
@tejalgulati8085
@tejalgulati8085 Ай бұрын
can you please explain, how it can be done for Webdriver IO?
@nasbasarinkm7869
@nasbasarinkm7869 2 жыл бұрын
is there any way for shadow root closed?
@KARTHIKPANCH97
@KARTHIKPANCH97 2 жыл бұрын
Hi Naveen Please share some websites where shadow DOM is Implemented
@mahapol8812
@mahapol8812 3 жыл бұрын
How to do shadow dom with python selenium?
@snehalatabehera7303
@snehalatabehera7303 10 ай бұрын
Thanks Naveen for explaining it so well. But in my DOM case, after shadow-root I have all the html tags with section only as below Shadow-root (open) Goes on... I need to select the section part 2..how can I do that?? Could you please help me with this??
@snehalatabehera7303
@snehalatabehera7303 10 ай бұрын
It worked with section.2... Please ignore the question. Thank You!
@richiestark4921
@richiestark4921 Жыл бұрын
How to come out from shadow root after driver switch inside?
@akshaygawand8
@akshaygawand8 3 ай бұрын
Sir please create a video where script is selecting shadow root drop-down options.
@MatheusPereira-nn9dj
@MatheusPereira-nn9dj Жыл бұрын
este conteudo deveria ter legendas urgentemente porque nao se tem muito sobre no youtube
@rahultiwari9376
@rahultiwari9376 2 жыл бұрын
I tried the same way but neither it is throwing error nor entering any text in the textbox
@AniketSingh-gn7gb
@AniketSingh-gn7gb 2 жыл бұрын
Hi Rahul, I am getting the same username cannot be empty. You resolved it?
@nishantshekhar7447
@nishantshekhar7447 11 ай бұрын
Need same flow but with Shadow Dome close
@naveenautomationlabs
@naveenautomationlabs 3 жыл бұрын
GIT REPO FOR THIS EXAMPLE: github.com/naveenanimation20/ShadowDOMHandle
@jaganathanellappan4244
@jaganathanellappan4244 2 жыл бұрын
Hi Naveen Script was working but ...text which passed as attributes were not displayed as text and looks like predefined text...any idea on it...
@gordonmccarthy5152
@gordonmccarthy5152 Жыл бұрын
when i use this code i got exception " org.openqa.selenium.JavascriptException: javascript error: Cannot read properties of null (reading 'shadowRoot') any solution for that
@macharlaanilkumar6363
@macharlaanilkumar6363 Жыл бұрын
same problem facing , pls explain me if you have already solved
Handle Auth Pop Up in Selenium using Chrome DevTools Protocols API
12:30
Naveen AutomationLabs
Рет қаралды 18 М.
EVOLUTION OF ICE CREAM 😱 #shorts
00:11
Savage Vlogs
Рет қаралды 7 МЛН
Пранк пошел не по плану…🥲
00:59
Саша Квашеная
Рет қаралды 6 МЛН
Little girl's dream of a giant teddy bear is about to come true #shorts
00:32
How to Interact with Shadow Elements in Selenium 4
21:13
PrinceAutomationDestination
Рет қаралды 575
How to Become Genius in XPath in Selenium  - Session -18
39:48
Naveen AutomationLabs
Рет қаралды 714 М.
Handle Hidden Drop Down Values / Auto Suggestions using DOM Trick | EventListener
7:55
Automate Complex Graphs with Selenium || Complex SVG Graph UI Elements
21:29
Naveen AutomationLabs
Рет қаралды 34 М.
How to Handle Frames in Selenium WebDriver
21:20
H Y R Tutorials
Рет қаралды 57 М.
What Is Shadow DOM? Open Vs Closed Shadow DOM
17:56
LetCode with Koushik
Рет қаралды 3,7 М.
Dynamic XPath in Selenium  using Different Approaches
28:12
Mukesh otwani
Рет қаралды 299 М.
Learn to write selectors for shadow DOM elements: SelectorsHub
9:36
low battery 🪫
0:10
dednahype
Рет қаралды 937 М.
Todos os modelos de smartphone
0:20
Spider Slack
Рет қаралды 63 МЛН
iPhone 15 Pro в реальной жизни
24:07
HUDAKOV
Рет қаралды 468 М.
Я купил первый в своей жизни VR! 🤯
1:00
Вэйми
Рет қаралды 3,3 МЛН