pypi-query-mcp/tests
Ryan Malloy 9924df34ec feat: Add comprehensive PyPI Analytics & Insights Tools
This commit implements a complete analytics suite for PyPI packages with four major tools:

🔍 **Package Analytics** (`get_pypi_package_analytics`)
- Comprehensive download analytics with trend analysis
- Platform and Python version breakdown
- Version adoption patterns and quality metrics
- Geographic distribution and growth indicators

🔒 **Security Alerts** (`get_pypi_security_alerts`)
- Integration with OSV (Open Source Vulnerabilities) database
- Dependency vulnerability scanning
- Security posture analysis and risk assessment
- Severity filtering and remediation recommendations

📈 **Package Rankings** (`get_pypi_package_rankings`)
- Search visibility and discoverability analysis
- Competitor ranking comparison
- SEO optimization suggestions
- Keyword and metadata analysis

🏆 **Competition Analysis** (`analyze_pypi_competition`)
- Market positioning and share analysis
- Feature comparison with competitors
- Adoption trends and growth patterns
- Strategic recommendations for improvement

**Key Features:**
- 50+ helper functions for detailed analysis
- Comprehensive error handling and validation
- Async/await patterns for optimal performance
- Integration with multiple data sources (PyPI, OSV, GitHub)
- Configurable analysis depth and options
- Production-ready code with extensive logging

**Implementation Details:**
- New module: `pypi_query_mcp/tools/analytics.py` (2000+ lines)
- Updated exports in `tools/__init__.py`
- Added 4 new MCP server endpoints in `server.py`
- Comprehensive test suite with 80+ test cases
- Full type hints and detailed docstrings

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-16 09:19:14 -06:00
..
__init__.py feat: Complete PyPI Query MCP Server Implementation (#3) 2025-05-27 11:14:49 +08:00
conftest.py feat: implement comprehensive configuration management system with multi-mirror support 2025-05-27 17:41:42 +08:00
test_analytics.py feat: Add comprehensive PyPI Analytics & Insights Tools 2025-08-16 09:19:14 -06:00
test_basic.py feat: implement comprehensive configuration management system with multi-mirror support 2025-05-27 17:41:42 +08:00
test_config.py feat: implement comprehensive configuration management system with multi-mirror support 2025-05-27 17:41:42 +08:00
test_dependency_resolver.py fix: update dependency resolver tests to match new implementation 2025-08-15 22:34:12 -06:00
test_download_stats.py chore: upgrade all Python packages and fix linting issues 2025-08-15 20:23:14 -06:00
test_metadata.py feat: implement PyPI metadata management tools 2025-08-16 09:00:32 -06:00
test_package_downloader.py fix: resolve all lint issues and fix failing tests 2025-05-29 18:47:15 +08:00
test_prompt_templates.py fix: resolve all lint issues and fix failing tests 2025-05-29 18:47:15 +08:00
test_publishing.py Implement PyPI Account & Publishing Tools 2025-08-16 08:52:03 -06:00
test_search.py feat: add comprehensive PyPI search functionality with advanced filtering 2025-08-16 07:45:40 -06:00
test_version_sorting.py chore: upgrade all Python packages and fix linting issues 2025-08-15 20:23:14 -06:00