petermr/dictionary

`pygetpapersdev` cannot find/install selenium

petermr opened this issue · 4 comments

ran git checkout main
git pull

directory

(base) pm286macbook:dictionary pm286$ ls
LICENSE			logs			pythoncode
README.md		openVirus202009		schema
__pycache__		openVirus202011		test
cevopen			openVirus20210120	update.ipynb
editor			pygetpapersdev
(base) pm286macbook:dictionary pm286$ cd pygetpapersdev/
(base) pm286macbook:pygetpapersdev pm286$ ls
europepmc.py		readme.md		testpapers.py
oldgetpapers.js		requirements.txt

(base) pm286macbook:pygetpapersdev pm286$ python testpapers.py 
Traceback (most recent call last):
  File "testpapers.py", line 270, in <module>
    c = a.webscrapepmc(myquery, mynumberofpapers)
  File "testpapers.py", line 26, in webscrapepmc
    from selenium import webdriver
ModuleNotFoundError: No module named 'selenium'
(base) pm286macbook:pygetpapersdev pm286$ pip install selenium
Collecting selenium
  Downloading selenium-3.141.0-py2.py3-none-any.whl (904 kB)
     |████████████████████████████████| 904 kB 3.3 MB/s 
Requirement already satisfied: urllib3 in /opt/anaconda3/lib/python3.8/site-packages (from selenium) (1.25.10)
Installing collected packages: selenium
Successfully installed selenium-3.141.0

(base) pm286macbook:pygetpapersdev pm286$ python testpapers.py 
Traceback (most recent call last):
  File "testpapers.py", line 270, in <module>
    c = a.webscrapepmc(myquery, mynumberofpapers)
  File "testpapers.py", line 39, in webscrapepmc
    import chromedriver_autoinstaller
ModuleNotFoundError: No module named 'chromedriver_autoinstaller'
(base) pm286macbook:pygetpapersdev pm286$ 
```

pip install -r requirements.txt

  • Ayush updated pygetpapers.py

Now downloads materials but fails with :

*/Updating the pickle*/
*/Making the Request to get full text xml*/
*/Done*/
*/Wrote the xml paper 71*/
*/Updating the pickle*/
*/Making the Request to get full text xml*/
*/Done*/
*/Wrote the xml paper 72*/
*/Updating the pickle*/
Traceback (most recent call last):
  File "testpapers.py", line 276, in <module>
    a.scrapingpaperdownload('ai', 200)
  File "testpapers.py", line 270, in scrapingpaperdownload
    c = self.webscrapepmc(query, size)
  File "testpapers.py", line 36, in webscrapepmc
    import chromedriver_autoinstaller
ModuleNotFoundError: No module named 'chromedriver_autoinstaller'
(base) pm286macbook:pygetpapersdev pm286$ 

I ran the software on PyCharm and I run on Windows 10.
It failed running:

C:\Users\shweata\anaconda3\python.exe C:/Users/shweata/dictionary/pygetpapersdev/testpapers.py
*/Building the Query*/
*/Making the Request to get all hits*/
*/Got the Content*/
Traceback (most recent call last):
  File "C:/Users/shweata/dictionary/pygetpapersdev/testpapers.py", line 275, in <module>
    a.apipaperdownload('ai', 200)
  File "C:/Users/shweata/dictionary/pygetpapersdev/testpapers.py", line 265, in apipaperdownload
    self.makecsv(c)
  File "C:/Users/shweata/dictionary/pygetpapersdev/testpapers.py", line 133, in makecsv
    import pandas_read_xml as pdx
ModuleNotFoundError: No module named 'pandas_read_xml'

Process finished with exit code 1

I ran the software on the jupyter notebook and Download the paper about specific keyword which mentioned into query