I think that this question by @jirayu.s is valid. It deserves an answer.
However, still I do not see the reason why @jirayu.s got the error “stale element reference”.
To find out the reason of stale element reference, I need to see more detail how the Application Under Test is implemented. So I need to be able to have the AUT in action on my PC.
So, perhaps, you may like to re-phrase this sentence.
This may be true with the objects generated by the Spy tool or whatever that abomination is named.
But the same can happen with xpath.
just saying …
It has been proven, in various topics, this tool creates more problems than it solves
I know CSS Object too why you are keen on replying to me?
if you really here to provide a solution provide it to the person who created the Post. instead, you are pointing to me.
the reason for the stale element is simple there are more ways to overcome it
stale element often arises for the following reasons
If the object is a dynamic one that keeps on changing
If you use the same element twice you can overcome this by using POM in selenium here in Katalon just copy the object rename it and use it this will fix it
if the web element is no longer attached to the DOM
as you mentioned you can achieve the results by using either of them
because you are providing fake impression to the user that xpath is the one and the only solution
which is wrong from a technical perspective
aside of that, your atitude is ‘my way and that’s all’ and whatever is not according to your own rules, you report as an offense.
which is not fair for comunity.
so, as a member of this comunity, i take your attitude as a personal offense.
(but i don’t report it)
I just gave the answer from my point of view.
I’m not here to bully someone. or argue others’ answer
I shared my solution and he provoked me with his reply and showed attitude and now you doing the same.
as a member of this community, I’m here to help and get help with my tests.
unlike you taking it as a personal offense.
now we are starting to talk.
first thing i will expect from your side, public apology to @Russ_Thomas
once i saw this and his post is re-instantiated like it was, russ will delete his new post and from there the discussion will happen at technical level.
once i will see the above fulfilled i will apologize to you publicly for the other chase (yes, i did that on purpose)
with the hope we can continue help this comunity in a professional maner, without the tendency to shadow some other valuable members.
on this last sentence, yeah, i may be the idiot, so if it is like this, as i mentioned, i will apologize for it.
but not yet…
Did not know all this was going down while I was away.
Now, since CSS locators/selectors and Xpath are way outta my league, I am not going to comment on which person got it right and wrong, technically-speaking.
Since this is a discussion forum, you are all free to suggest your method(s) of working, and the OPs (in this case @jirayu.s) are free to follow whichever method(s) that work best for them, and then we can call it a day.
Granted, some comments might have come off as a tiny bit strong, and thus, the receiving party might have misinterpreted what was being said and everything just snowballed from there. I am not going to ask anyone to apologize to anyone here (though I do suggest whoever involved to talk to each other via PMs, and work things out there - in a professional and friendly way please).
Since it is the weekend (in my timezone at least), let’s all take a breather, grab a beer (or a blunt ), and walk away from all this “tension” for a while.
And @jirayu.s, please let me know if any of the comments in this thread was able to answer your question, and then I will proceed to close it. Thanks.
now, it is my time to apologize @bharathi.a for chasing.
hope you understand why i did that.
details:
we are here in a comunity with members from different cultures, level of expertise and so on
due to that, it is very easy a certain topic to be interpreted as ofensive or not.
meeeh…get used to that.
i think i am the champion on this comunity in such (my posts being wrong taken)
so kinldly let us learn something from this.
the common language we have is on technical level.
thank you!
Don’t hold your breath. The statement I made was polite, starting with the word PLEASE.
Your manners on the other hand were less than exemplary. Not a single word of politeness. You sniped around in the dark and blocked my posts. THAT’s a childish attitude unbefitting adult discourse, especially in a public arena.
Don’t take technical arrogance as a personal attack. IT IS NOT PERSONAL unless YOU take it as personal.
You had a choice and you chose to take offense. Then you had another choice and you chose to enter into a long diatribe about something else entirely, nothing to do with the implied question “why”. Then you had another choice and you chose to block my posts.
I’m not responsible for your choices, even if your feelings were hurt.
@albert.vu first of all, I’m much appreciate for all comments and advices from all members that are trying to support issue. Like Albert.Vu said, it’s weekend break. Let’s grab beer and relax.
I’m trying to figure out how to resolve my issue with all comments and advice. I could feel heartful support from community members. Sorry for my poor English that may cause misleading.
Can you at least use the Inspect in browser and show us the html code, in both cases?
If there is some sensitive data, you can censor it but keep the html structure intact.
See this topic for guidance on how to use Developer Tools: