Do you want to tap into the treasure trove of PyPI download statistics without breaking a sweat? Introducing pypinfo, a streamlined command-line interface that simplifies the process of accessing metrics via Google BigQuery. Get ready to dive deeper into the world of Python packages and unlock insights like never before!
Table of Contents
Usage
Using pypinfo is as easy as pie! Here’s a simple way to think about it: consider pypinfo as your friendly librarian who assists you in fetching specific books from an expansive library (PyPI) filled with various topics (projects, versions, countries, and much more).
To fetch data, just follow the command format:
pypinfo [OPTIONS] [PROJECT] [FIELDS]... COMMAND [ARGS]...
Your options include various filters like project, version, instantiation methods, and date ranges. Here are some handy examples:
pypinfo requests
pypinfo --days 365 project
Each command you run will return detailed statistics about PyPI packages, including download counts, version metrics, and even geographical data about users.
Installation
The world of pypinfo awaits you! To get started, follow these easy installation steps:
- Visit BigQuery and sign up if you haven’t already.
- Create a new project using the Google Cloud Console to track PyPI data.
- Enable the BigQuery API through the API Library.
- Create credentials in BigQuery to authorize your pypinfo access.
- Run the following command in your terminal to install pypinfo:
- Authenticate with your credentials by running:
python -m pip install pypinfo
pypinfo --auth pathtoyour_credentials.json
Troubleshooting
If you encounter issues, here are some troubleshooting tips:
- If you see NoneType errors during queries, it could be due to timeout settings. Try increasing the timeout by using the
-toption. - Ensure that your credentials are correctly set by verifying your JSON file path.
- Can’t find the data you need? Check that you’ve entered the project or field correctly.
For more insights, updates, or to collaborate on AI development projects, stay connected with fxis.ai.
Credits
A big shoutout to:
- Donald Stufft for maintaining PyPI.
- Google for providing BigQuery capacity.
- Paul Kehrer for his insightful blog post on data-driven decisions.
At fxis.ai, we believe that such advancements are crucial for the future of AI, as they enable more comprehensive and effective solutions. Our team is continually exploring new methodologies to push the envelope in artificial intelligence, ensuring that our clients benefit from the latest technological innovations.

