Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error in installing pygooglenews #45

Open
gjain7 opened this issue Jan 12, 2024 · 8 comments
Open

error in installing pygooglenews #45

gjain7 opened this issue Jan 12, 2024 · 8 comments

Comments

@gjain7
Copy link

gjain7 commented Jan 12, 2024

I have tried installing the library but it is failing to install itself. I used collab to run it and windows 11

!pip install pygooglenews --upgrade

Collecting pygooglenews
Using cached pygooglenews-0.1.2-py3-none-any.whl (10 kB)
Requirement already satisfied: beautifulsoup4<5.0.0,>=4.9.1 in /usr/local/lib/python3.10/dist-packages (from pygooglenews) (4.11.2)
Collecting dateparser<0.8.0,>=0.7.6 (from pygooglenews)
Using cached dateparser-0.7.6-py2.py3-none-any.whl (362 kB)
Collecting feedparser<6.0.0,>=5.2.1 (from pygooglenews)
Using cached feedparser-5.2.1.zip (1.2 MB)
error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
Preparing metadata (setup.py) ... error
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

@climate-tech
Copy link

same

@patekOnlyPrograms
Copy link

Yep i am having that issue as well using anaconda

@BlueberryTech123
Copy link

So I have found a sort of workaround to this issue:

  1. Create a new file called pygooglenews.py
  2. Copy the code from https://github.com/kotartemiy/pygooglenews/blob/master/pygooglenews/__init__.py into the newly created file
  3. Manually install the packages:
    pip install feedparser
    pip install dateparser
  4. import pygooglenews like you would normally

jus gonna copy and paste this "solution"

@patekOnlyPrograms
Copy link

So I have found a sort of workaround to this issue:

  1. Create a new file called pygooglenews.py
  2. Copy the code from https://github.com/kotartemiy/pygooglenews/blob/master/pygooglenews/__init__.py into the newly created file
  3. Manually install the packages:
    pip install feedparser
    pip install dateparser
  4. import pygooglenews like you would normally

jus gonna copy and paste this "solution"

will verify if this works on my computer

@rohan1827
Copy link

So I have found a sort of workaround to this issue:

  1. Create a new file called pygooglenews.py
  2. Copy the code from https://github.com/kotartemiy/pygooglenews/blob/master/pygooglenews/__init__.py into the newly created file
  3. Manually install the packages:
    pip install feedparser
    pip install dateparser
  4. import pygooglenews like you would normally

jus gonna copy and paste this "solution"

will verify if this works on my computer

not working for me!

@BlueberryTech123
Copy link

not working for me!

Could I see your file hierarchy or any error(s) you got?

@rohan1827
Copy link

not working for me!

Could I see your file hierarchy or any error(s) you got?

got it resolved, apparently feedparser is using a deprecated method 'base64.decodestring()' i had to replace the method with 'base64.decodebytes' in the package and it worked then.

@vedanthv
Copy link

vedanthv commented May 3, 2024

@rohan1827 where should the method be replaced?

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

No branches or pull requests

6 participants