madingess / EasyApplyBot

Automate LinkedIn Easy Apply job applications and answer application-specific questions.
GNU General Public License v3.0
101 stars 113 forks source link

Error when "remote" filter is active #26

Closed JediRhymeTrix closed 8 months ago

JediRhymeTrix commented 1 year ago

When Remote is set to True or the Region is set to Remote, after applying to the first job on the page, the following error is thrown for every subsequent job in the list:

selenium.common.exceptions.StaleElementReferenceException: Message: stale element reference: stale element not found

The error originates from the following piece of code:

...
            if company. Lower() not in [word.lower() for word in self.company_blacklist] and \
                    poster.lower() not in [word.lower() for word in self.poster_blacklist] and \
                    contains_blacklisted_keywords is False and link not in self.seen_jobs:
                try:
                    try:
                        job_el = job_tile.find_element(By.CLASS_NAME, 'job-card-list__title') # THIS LINE THROWS THE ERROR
                        job_el.click()
...                       

The script works fine when the remote filter is not applied. This is something that has started happening in the past month or so.

Any help in resolving the issue or coming up with a workaround would be highly appreciated.

voidbydefault commented 1 year ago

It's been fixed in the repo I am maintaining (https://github.com/voidbydefault/EasyApplyBot/).

madingess commented 8 months ago

For those tracking along, @voidbydefault 's changes have been merged into this repository.

This should be working once more.

Thank you!