Merge pull request #161 from ItaloGustavoS/patch-1

Adding the ability for the Selenium driver to scrape the user's profile link and add it to the report.
This commit is contained in:
Rip&Tear
2024-09-13 21:59:42 +08:00
committed by GitHub
2 changed files with 3 additions and 1 deletions

View File

@@ -31,6 +31,7 @@ class Client:
result["name"] = person.find_element(By.CSS_SELECTOR, "span.entity-result__title-line").text
result["position"] = person.find_element(By.CSS_SELECTOR, "div.entity-result__primary-subtitle").text
result["location"] = person.find_element(By.CSS_SELECTOR, "div.entity-result__secondary-subtitle").text
result["profile_link"] = person.find_element(By.CSS_SELECTOR, "a.app-aware-link").get_attribute("href")
except Exception as e:
print(e)
continue

View File

@@ -22,7 +22,8 @@ class LinkedInTool(BaseTool):
"-------------",
p['name'],
p['position'],
p['location']
p['location'],
p["profile_link"],
]) for p in people]
result = "\n\n".join(result)