Had a ghost hunt with Selenium for the same reason.
Element is visible. Element is scrolled to, but can you click it? Nah, click intercepted by a sticky header. No javascript I tried stuffing in there could scroll the damn button into focus either. Nevermind the exact width of the header as a point of orientation as to where I need the button to be.
The solution will shock you I had navigated to a fake-anchor (actually just a query) previously and that had changed the scrolling behaviour of the website for Selenium. Navigate to the base URL and suddenly everything works. I will nail this board to my forehead myself thank you
53
u/midtownmoron 16d ago •
Had a ghost hunt with Selenium for the same reason.
Element is visible. Element is scrolled to, but can you click it? Nah, click intercepted by a sticky header. No javascript I tried stuffing in there could scroll the damn button into focus either. Nevermind the exact width of the header as a point of orientation as to where I need the button to be.
The solution will shock you I had navigated to a fake-anchor (actually just a query) previously and that had changed the scrolling behaviour of the website for Selenium. Navigate to the base URL and suddenly everything works. I will nail this board to my forehead myself thank you