Skip to content

Conversation

anilabhadatta
Copy link

Requires some company_scraper testing with temporary Linkedin accounts.
command : scrapeli --company=delltechnologies -o output.json

@KarahanS
Copy link

KarahanS commented Aug 31, 2021

Some parts of the code are language-dependent, meaning it won't work for languages other than English (such as regular expressions etc.). But it works as expected for English. click_on_tab() function doesn't seem to be working for hidden tabs in the expander. Function can be simplified easily to tackle with that issue:

    def click_on_tab(self, tab_name):
        main_url = "https://www.linkedin.com/company/{}/".format(self.company)
        try:
            self.driver.get(main_url + tab_name)
        except:
            print("Tab cannot be found.")
            return

You have to add self.company = company to the constructor method of CompanyScraper object.

@anilabhadatta
Copy link
Author

def click_on_tab(self, tab_name):
        main_url = "https://www.linkedin.com/company/{}/".format(self.company)
        try:
            self.driver.get(main_url + tab_name)
        except:
            print("Tab cannot be found.")
            return

Thanks a lot, i overlooked this issue, Added your code .

@anilabhadatta
Copy link
Author

Some parts of the code are language-dependent, meaning it won't work for languages other than English (such as regular expressions etc.). But it works as expected for English. click_on_tab() function doesn't seem to be working for hidden tabs in the expander. Function can be simplified easily to tackle with that issue:

    def click_on_tab(self, tab_name):
        main_url = "https://www.linkedin.com/company/{}/".format(self.company)
        try:
            self.driver.get(main_url + tab_name)
        except:
            print("Tab cannot be found.")
            return

You have to add self.company = company to the constructor method of CompanyScraper object.

Added the code and verified with different language as well.
Also fixed the json output where cyrillic characters were showing in \u escape characters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants