VickiLanger / LGBTQ-of-the-day-bot

Twitter bot tweeting fun goofy lgbtq things and queer history of the day
https://twitter.com/LGBTQotd
GNU General Public License v3.0
80 stars 173 forks source link

Suggest to loosen the dependency on tweepy #317

Open Agnes-U opened 1 year ago

Agnes-U commented 1 year ago

Dear developers,

Your project LGBTQ-of-the-day-bot requires "tweepy==3.9.0" in its dependency. After analyzing the source code, we found that the following versions of tweepy can also be suitable without affecting your project, i.e., tweepy 3.10.0. Therefore, we suggest to loosen the dependency on tweepy from "tweepy==3.9.0" to "tweepy>=3.9.0,<=3.10.0" to avoid any possible conflict for importing more packages or for downstream projects that may use ddos_script.

May I pull a request to further loosen the dependency on tweepy?

By the way, could you please tell us whether such dependency analysis may be potentially helpful for maintaining dependencies easier during your development?



Details:

Your project (commit id: 6767b41cd3d17f64bbe4af6367f3ae2a7fb9125c) directly uses 3 APIs from package tweepy.

tweepy.api.API.__init__, tweepy.auth.OAuthHandler.__init__, tweepy.auth.OAuthHandler.set_access_token

Beginning fromwhich, 1 functions are then indirectly called, including 0 tweepy's internal APIs and 1 outsider APIs as follows:

[/VickiLanger/LGBTQ-of-the-day-bot]
+--tweepy.api.API.__init__
|      +--tweepy.parsers.ModelParser.__init__
+--tweepy.auth.OAuthHandler.__init__
|      +--requests_oauthlib.OAuth1Session
+--tweepy.auth.OAuthHandler.set_access_token

Since all these functions have not been changed between any version for package "tweepy" from [3.10.0] and 3.9.0. Therefore, we believe it is safe to loosen the corresponding dependency.

VickiLanger commented 1 year ago

Good idea. Thank you for sharing. Currently, this bot is hosted on Heroku free tier that ends the end of this month. I have not migrated it. I'm not sure it's worth the effort to update. Currently, I'm also concerned about the state of Twitter. I'm thinking if, this time next year, it's still up and usable, then I will update tweepy and migrate to another host. If not, I will repurpose this bot for another platform