Iceloof / GoogleNews

Script for GoogleNews
https://pypi.org/project/GoogleNews/
MIT License
316 stars 88 forks source link

many changes ... version 1.5.0? #38

Closed MCilento93 closed 3 years ago

MCilento93 commented 3 years ago

Hello Iceloof, as promised I took time for improve a little bit your project.

I summarize the changes for this pull request below:

  1. rewrited (update) get_news() method. It was not working anymore. Now it includes in the results the field datetime and the description of the article. This feature required me to use python.dateutil package, but it works greatly. I removed the use of timezones because it could give troubles when sorting the papers (sometime parser detects timezones, other times not). The new get_news() method results more flexible, stable, rich and useful than the other, especially because from the html of google one can access the datetime.
  2. included lexial_date_parser() method for parse with robustness the date and datetime filed from the results.
  3. changed the .result(sort=True) feature to be used with both the results from google.com and news.google.com
  4. made more Pythonic the methods in the classes
  5. included a new test files for testing the new results lists

Let me know what do you think about the changes: this package is truly useful for a project of mine, hope to can use it with these updates.

Sincerely,

MCilento93 commented 3 years ago

Thank you I wronged the name of the Def lexial_date_parser(date_to_check)It is actually lexical_date_parser(date_to_check)Can you change in the code? Regards ---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 14/11/20 22:20 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38) Merged #38 into master.

—You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

MCilento93 commented 3 years ago

Furthermore, From setup.py now I see version 1.5.1, actually the versions if 1.5.0---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 14/11/20 22:20 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38) Merged #38 into master.

—You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

HurinHu commented 3 years ago

I modified the error you mentioned above after I published v1.5.0, the v1.5.1 is not published, so this is modification will be updated in next release.

Furthermore, From setup.py now I see version 1.5.1, actually the versions if 1.5.0---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 14/11/20 22:20 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38) Merged #38 into master. —You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

MCilento93 commented 3 years ago

Got itThe publication on pypi.org is not automatic? Regards ---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 15/11/20 11:25 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38)

I modified the error you mentioned above after I published v1.5.0, the v1.5.1 is not published, so this is modification will be updated in next release.

Furthermore, From setup.py now I see version 1.5.1, actually the versions if 1.5.0---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 14/11/20 22:20 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38) Merged #38 into master. —You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

—You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

HurinHu commented 3 years ago

It is automatically uploaded through GitHub Action when a new release creates on GitHub

Got itThe publication on pypi.org is not automatic? Regards ---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 15/11/20 11:25 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38)

I modified the error you mentioned above after I published v1.5.0, the v1.5.1 is not published, so this is modification will be updated in next release.

Furthermore, From setup.py now I see version 1.5.1, actually the versions if 1.5.0---M -------- Messaggio originale --------Da: Hurin Hu notifications@github.com Data: 14/11/20 22:20 (GMT+01:00) A: Iceloof/GoogleNews GoogleNews@noreply.github.com Cc: Mario Cilento mario.cilento.93@gmail.com, Author author@noreply.github.com Oggetto: Re: [Iceloof/GoogleNews] many changes ... version 1.5.0? (#38) Merged #38 into master. —You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.

—You are receiving this because you authored the thread.Reply to this email directly, view it on GitHub, or unsubscribe.