Python Forum
Installing Older Version Of Numpy & Pandas
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Installing Older Version Of Numpy & Pandas
#7
(Aug-28-2023, 12:12 PM)snippsat Wrote: To use this older code should fist make virtual environment and clone Repo a use older Python version,then do pip install -r requirements.txt
I did a quick test and this code dos not work anymore,have to do a rewrite of code as there are servals problems.
Code use Selenium and and goes to Google for search,Google has of course changed since 2018.
Also Selenium has changes so need some Path fix,before comes to this error.
From code:
"""
Search on Google and returns the list of PAA questions in SERP.
"""
def newSearch(browser,query):
    if lang== "en":
        browser.get("https://www.google.com?hl=en")
        searchbox = browser.find_element_by_xpath("//input[@aria-label='Search']")
    else:
        browser.get("https://www.google.com?hl=es")
        searchbox = browser.find_element_by_xpath("//input[@aria-label='Buscar']")

    searchbox.send_keys(query) 
Error:
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//input[@aria-label='Search']"}

Hi Snippat,

Apologies for the late reply. Thank you for taking the time to even try it out yourself and report back that the code has issues. Super helpful as I hadn't got that far! At least now I'm a little more competent in creating a virtual environment with different versions of packages. Very kind of you to even try the code out yourself mate.

Have a great week.
Reply


Messages In This Thread
RE: Installing Older Version Of Numpy & Pandas - by knight2000 - Aug-30-2023, 10:58 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  What are some good books for learning NumPy and Pandas? Pnerd 1 984 Feb-13-2022, 01:14 PM
Last Post: jefsummers
  coding problem from older book teddfirth 3 2,264 Mar-06-2021, 03:51 PM
Last Post: teddfirth
  Installing Numpy on Raspberry Pi koepjo 3 21,357 Apr-04-2020, 09:49 AM
Last Post: snippsat
  remove files from folder older than X days kerzol81 2 8,910 Jan-03-2020, 11:55 PM
Last Post: snippsat
  Installing Numpy multiple locations dwhe 4 3,305 Dec-21-2019, 02:02 AM
Last Post: dwhe
  Installing pip and pandas DavidTheGrockle 2 1,823 Oct-24-2019, 10:40 AM
Last Post: DavidTheGrockle
  Problem installing numpy and matplotlib achondrite 1 3,237 Jan-16-2019, 11:43 PM
Last Post: snippsat
  merging lists, dedup and keeping order, in older pythons Skaperen 3 3,292 Oct-19-2018, 01:30 AM
Last Post: ODIS
  Can I upload a new version without previously deleting ancient version sylas 6 4,495 Nov-08-2017, 03:26 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020