flakeradar


Nameflakeradar JSON
Version 2.2.0 PyPI version JSON
download
home_pageNone
SummaryAI-Powered Test Flakiness Detection & Root Cause Analysis - Enterprise-grade analytics for test reliability
upload_time2025-07-22 06:07:21
maintainerNone
docs_urlNone
authorNone
requires_python>=3.9
licenseNone
keywords testing flaky-tests ci-cd test-analytics ai team-collaboration cross-environment enterprise quality-assurance
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <div align="center">

# 🔍 FlakeRadar

### **AI-Powered Test Flakiness Detection & Team Collaboration**

<p>
  <img src="https://img.shields.io/badge/python-3.9+-blue.svg" alt="Python 3.9+">
  <img src="https://img.shields.io/badge/License-MIT-yellow.svg" alt="MIT License">
  <img src="https://img.shields.io/badge/Enterprise-Ready-green.svg" alt="Enterprise Ready">
</p>

Transform raw test results into actionable insights with **statistical confidence scoring**, **AI-powered root cause analysis**, and **team collaboration features**.

</div>

---

## 🚀 **Quick Start**

```bash
# Install and analyze
pip install flakeradar
flakeradar --project "MyApp" --results "test-results/*.xml"
open flakeradar_report.html
```

**Python API:**
```python
from flakeradar import FlakeRadar

with FlakeRadar(project="MyApp") as radar:
    radar.add_results("test-results/*.xml")
    analysis = radar.analyze(confidence_threshold=0.7, enable_ai=True)
    radar.generate_html_report("report.html")
```

---

## 🎯 **Key Features**

### **🔍 Smart Analysis**
- **Statistical Confidence Scoring** - Wilson intervals eliminate false positives
- **AI Root Cause Clustering** - Groups failures by actual causes
- **Time-to-Fix Tracking** - Identifies chronic flaky tests

### **👥 Team Collaboration** 
- **Central Dashboard** - Shared analytics across environments
- **Multi-Environment Tracking** - Dev → Staging → Production insights
- **CI/CD Integration** - Jenkins, GitHub Actions, REST API

### **📊 Enterprise Ready**
- **Production-Tested Accuracy** - Fixed confidence calculations
- **Secure Token Authentication** - Team collaboration with proper security
- **Scalable Architecture** - Supports teams of any size

---

## 🔧 **Team Setup**

### **1. Start Team Dashboard**
```bash
python -m flakeradar.dev_server
# Dashboard: http://localhost:8000/dashboard/your-team-id
```

### **2. Create Team Token**
```bash
curl -X POST http://localhost:8000/api/v1/team/tokens \
  -d '{"team_name": "YourTeam", "environment": "production"}'
```

### **3. Jenkins Integration**
```groovy
environment {
    FLAKERADAR_TEAM_TOKEN = credentials('flakeradar-team-token')
}
post {
    always {
        sh '''
            pip install flakeradar
            flakeradar --project "${JOB_NAME}" \
                      --results "test-results/*.xml" \
                      --team-token "${FLAKERADAR_TEAM_TOKEN}" \
                      --environment "${ENV}"
        '''
    }
}
```

### **4. GitHub Actions**
```yaml
- name: FlakeRadar Analysis
  env:
    FLAKERADAR_TEAM_TOKEN: ${{ secrets.FLAKERADAR_TEAM_TOKEN }}
  run: |
    pip install flakeradar
    flakeradar --project "${{ github.repository }}" \
              --results "test-results/*.xml" \
              --team-token "$FLAKERADAR_TEAM_TOKEN" \
              --environment "ci"
```

---

## 📖 **CLI Reference**

```bash
flakeradar [OPTIONS]

# Core Parameters
--project TEXT              Project name (required)
--results TEXT              Test files pattern (required, e.g., "*.xml")

# Team Collaboration
--team-token TEXT           Team token (flake_tk_...)
--dashboard-url TEXT        Dashboard URL
--environment TEXT          Environment (dev/staging/prod)

# Analysis Options  
--confidence-threshold FLOAT  Statistical threshold (0.0-1.0, default: 0.7)
--enable-ai / --no-ai        AI analysis (auto-detects API key)
--output TEXT               Report filename (default: flakeradar_report.html)
```

---

## 🔧 **Troubleshooting**

### **Common Issues**

**❌ "Invalid token" error**
```bash
# Verify token format
echo $FLAKERADAR_TEAM_TOKEN  # Should start with "flake_tk_"

# Test token
curl -X POST "$DASHBOARD_URL/api/v1/team/validate" \
  -H "Authorization: Bearer $FLAKERADAR_TEAM_TOKEN"
```

**❌ Dashboard shows no data**
```bash
# Check Jenkins console output for submission errors
# Verify environment variables are set correctly
```

**❌ Analysis too slow**
```bash
# Optimize for large test suites
flakeradar --limit-runs 20 --max-ai-analysis 5 --confidence-threshold 0.8
```

---

## 📊 **Sample Output**

```bash
🚨 Flaky Test Analysis Results:
  📊 Total Tests: 245 | Flaky: 12 | High Confidence: 8
  
🔴 High Priority Flaky Tests:
  DatabaseTest#connectionPool (82% confidence, 14 days flaky)
  AuthTest#tokenRefresh (76% confidence, 7 days flaky)

🔍 Root Cause Analysis:
  🗄️ Database connectivity: 8 tests affected
  ⏱️ Timing issues: 4 tests affected
  
🤖 AI Insights: 12 tests analyzed
✅ Report generated: flakeradar_report.html
```

---

## 🏢 **Enterprise Features**

- **Mathematical Rigor** - Wilson Score confidence intervals
- **Production Accuracy** - Fixed edge cases for 0%/100% failure rates  
- **Team Analytics** - Cross-environment insights and contributor tracking
- **Security** - Token-based authentication with rotation support
- **Integration** - Jenkins, GitHub Actions, REST API, Python API
- **Scalability** - Supports individual developers to enterprise teams

---

## 📚 **Links**

- **[GitHub Repository](https://github.com/hahaharsh/flakeradar)** - Source code and issues
- **[Documentation](https://github.com/hahaharsh/flakeradar/wiki)** - Detailed guides
- **[Support](https://github.com/hahaharsh/flakeradar/issues)** - Questions and bug reports

---

<div align="center">

**Ready to eliminate flaky tests?**

[🚀 Get Started](https://github.com/hahaharsh/flakeradar) | [📖 Documentation](https://github.com/hahaharsh/flakeradar/wiki) | [💬 Support](https://github.com/hahaharsh/flakeradar/issues)

*Built by engineers who understand the pain of flaky tests*

</div>

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "flakeradar",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": null,
    "keywords": "testing, flaky-tests, ci-cd, test-analytics, ai, team-collaboration, cross-environment, enterprise, quality-assurance",
    "author": null,
    "author_email": "Harsh <geemax.harsh@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/58/ae/6caeb54c12502d2e7c32032ef1fe22bcb0f840cea07c75bf926a122adae7/flakeradar-2.2.0.tar.gz",
    "platform": null,
    "description": "<div align=\"center\">\n\n# \ud83d\udd0d FlakeRadar\n\n### **AI-Powered Test Flakiness Detection & Team Collaboration**\n\n<p>\n  <img src=\"https://img.shields.io/badge/python-3.9+-blue.svg\" alt=\"Python 3.9+\">\n  <img src=\"https://img.shields.io/badge/License-MIT-yellow.svg\" alt=\"MIT License\">\n  <img src=\"https://img.shields.io/badge/Enterprise-Ready-green.svg\" alt=\"Enterprise Ready\">\n</p>\n\nTransform raw test results into actionable insights with **statistical confidence scoring**, **AI-powered root cause analysis**, and **team collaboration features**.\n\n</div>\n\n---\n\n## \ud83d\ude80 **Quick Start**\n\n```bash\n# Install and analyze\npip install flakeradar\nflakeradar --project \"MyApp\" --results \"test-results/*.xml\"\nopen flakeradar_report.html\n```\n\n**Python API:**\n```python\nfrom flakeradar import FlakeRadar\n\nwith FlakeRadar(project=\"MyApp\") as radar:\n    radar.add_results(\"test-results/*.xml\")\n    analysis = radar.analyze(confidence_threshold=0.7, enable_ai=True)\n    radar.generate_html_report(\"report.html\")\n```\n\n---\n\n## \ud83c\udfaf **Key Features**\n\n### **\ud83d\udd0d Smart Analysis**\n- **Statistical Confidence Scoring** - Wilson intervals eliminate false positives\n- **AI Root Cause Clustering** - Groups failures by actual causes\n- **Time-to-Fix Tracking** - Identifies chronic flaky tests\n\n### **\ud83d\udc65 Team Collaboration** \n- **Central Dashboard** - Shared analytics across environments\n- **Multi-Environment Tracking** - Dev \u2192 Staging \u2192 Production insights\n- **CI/CD Integration** - Jenkins, GitHub Actions, REST API\n\n### **\ud83d\udcca Enterprise Ready**\n- **Production-Tested Accuracy** - Fixed confidence calculations\n- **Secure Token Authentication** - Team collaboration with proper security\n- **Scalable Architecture** - Supports teams of any size\n\n---\n\n## \ud83d\udd27 **Team Setup**\n\n### **1. Start Team Dashboard**\n```bash\npython -m flakeradar.dev_server\n# Dashboard: http://localhost:8000/dashboard/your-team-id\n```\n\n### **2. Create Team Token**\n```bash\ncurl -X POST http://localhost:8000/api/v1/team/tokens \\\n  -d '{\"team_name\": \"YourTeam\", \"environment\": \"production\"}'\n```\n\n### **3. Jenkins Integration**\n```groovy\nenvironment {\n    FLAKERADAR_TEAM_TOKEN = credentials('flakeradar-team-token')\n}\npost {\n    always {\n        sh '''\n            pip install flakeradar\n            flakeradar --project \"${JOB_NAME}\" \\\n                      --results \"test-results/*.xml\" \\\n                      --team-token \"${FLAKERADAR_TEAM_TOKEN}\" \\\n                      --environment \"${ENV}\"\n        '''\n    }\n}\n```\n\n### **4. GitHub Actions**\n```yaml\n- name: FlakeRadar Analysis\n  env:\n    FLAKERADAR_TEAM_TOKEN: ${{ secrets.FLAKERADAR_TEAM_TOKEN }}\n  run: |\n    pip install flakeradar\n    flakeradar --project \"${{ github.repository }}\" \\\n              --results \"test-results/*.xml\" \\\n              --team-token \"$FLAKERADAR_TEAM_TOKEN\" \\\n              --environment \"ci\"\n```\n\n---\n\n## \ud83d\udcd6 **CLI Reference**\n\n```bash\nflakeradar [OPTIONS]\n\n# Core Parameters\n--project TEXT              Project name (required)\n--results TEXT              Test files pattern (required, e.g., \"*.xml\")\n\n# Team Collaboration\n--team-token TEXT           Team token (flake_tk_...)\n--dashboard-url TEXT        Dashboard URL\n--environment TEXT          Environment (dev/staging/prod)\n\n# Analysis Options  \n--confidence-threshold FLOAT  Statistical threshold (0.0-1.0, default: 0.7)\n--enable-ai / --no-ai        AI analysis (auto-detects API key)\n--output TEXT               Report filename (default: flakeradar_report.html)\n```\n\n---\n\n## \ud83d\udd27 **Troubleshooting**\n\n### **Common Issues**\n\n**\u274c \"Invalid token\" error**\n```bash\n# Verify token format\necho $FLAKERADAR_TEAM_TOKEN  # Should start with \"flake_tk_\"\n\n# Test token\ncurl -X POST \"$DASHBOARD_URL/api/v1/team/validate\" \\\n  -H \"Authorization: Bearer $FLAKERADAR_TEAM_TOKEN\"\n```\n\n**\u274c Dashboard shows no data**\n```bash\n# Check Jenkins console output for submission errors\n# Verify environment variables are set correctly\n```\n\n**\u274c Analysis too slow**\n```bash\n# Optimize for large test suites\nflakeradar --limit-runs 20 --max-ai-analysis 5 --confidence-threshold 0.8\n```\n\n---\n\n## \ud83d\udcca **Sample Output**\n\n```bash\n\ud83d\udea8 Flaky Test Analysis Results:\n  \ud83d\udcca Total Tests: 245 | Flaky: 12 | High Confidence: 8\n  \n\ud83d\udd34 High Priority Flaky Tests:\n  DatabaseTest#connectionPool (82% confidence, 14 days flaky)\n  AuthTest#tokenRefresh (76% confidence, 7 days flaky)\n\n\ud83d\udd0d Root Cause Analysis:\n  \ud83d\uddc4\ufe0f Database connectivity: 8 tests affected\n  \u23f1\ufe0f Timing issues: 4 tests affected\n  \n\ud83e\udd16 AI Insights: 12 tests analyzed\n\u2705 Report generated: flakeradar_report.html\n```\n\n---\n\n## \ud83c\udfe2 **Enterprise Features**\n\n- **Mathematical Rigor** - Wilson Score confidence intervals\n- **Production Accuracy** - Fixed edge cases for 0%/100% failure rates  \n- **Team Analytics** - Cross-environment insights and contributor tracking\n- **Security** - Token-based authentication with rotation support\n- **Integration** - Jenkins, GitHub Actions, REST API, Python API\n- **Scalability** - Supports individual developers to enterprise teams\n\n---\n\n## \ud83d\udcda **Links**\n\n- **[GitHub Repository](https://github.com/hahaharsh/flakeradar)** - Source code and issues\n- **[Documentation](https://github.com/hahaharsh/flakeradar/wiki)** - Detailed guides\n- **[Support](https://github.com/hahaharsh/flakeradar/issues)** - Questions and bug reports\n\n---\n\n<div align=\"center\">\n\n**Ready to eliminate flaky tests?**\n\n[\ud83d\ude80 Get Started](https://github.com/hahaharsh/flakeradar) | [\ud83d\udcd6 Documentation](https://github.com/hahaharsh/flakeradar/wiki) | [\ud83d\udcac Support](https://github.com/hahaharsh/flakeradar/issues)\n\n*Built by engineers who understand the pain of flaky tests*\n\n</div>\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "AI-Powered Test Flakiness Detection & Root Cause Analysis - Enterprise-grade analytics for test reliability",
    "version": "2.2.0",
    "project_urls": {
        "Documentation": "https://github.com/hahaharsh7/flakeradar#readme",
        "Homepage": "https://github.com/hahaharsh7/flakeradar",
        "Issues": "https://github.com/hahaharsh7/flakeradar/issues",
        "Repository": "https://github.com/hahaharsh7/flakeradar"
    },
    "split_keywords": [
        "testing",
        " flaky-tests",
        " ci-cd",
        " test-analytics",
        " ai",
        " team-collaboration",
        " cross-environment",
        " enterprise",
        " quality-assurance"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "d367b7bf89011b5beb1a16fe356d428b71e322538f5a73dc7466e5226f4ac486",
                "md5": "4793a77438bf4439c2c2bdffd2b22172",
                "sha256": "6dd591cec888f1a1fb0ebeb2dbeea18abbe348c695beac4e6804e8c577132a25"
            },
            "downloads": -1,
            "filename": "flakeradar-2.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4793a77438bf4439c2c2bdffd2b22172",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 52096,
            "upload_time": "2025-07-22T06:07:19",
            "upload_time_iso_8601": "2025-07-22T06:07:19.786810Z",
            "url": "https://files.pythonhosted.org/packages/d3/67/b7bf89011b5beb1a16fe356d428b71e322538f5a73dc7466e5226f4ac486/flakeradar-2.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "58ae6caeb54c12502d2e7c32032ef1fe22bcb0f840cea07c75bf926a122adae7",
                "md5": "f8cb8459f1b3ec17e6754a65239feb18",
                "sha256": "7f05d074ca151f303bdcabf41a9fd323bfd9f33a6b50233b5fd0e08188edd3e5"
            },
            "downloads": -1,
            "filename": "flakeradar-2.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "f8cb8459f1b3ec17e6754a65239feb18",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 46307,
            "upload_time": "2025-07-22T06:07:21",
            "upload_time_iso_8601": "2025-07-22T06:07:21.400769Z",
            "url": "https://files.pythonhosted.org/packages/58/ae/6caeb54c12502d2e7c32032ef1fe22bcb0f840cea07c75bf926a122adae7/flakeradar-2.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-07-22 06:07:21",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "hahaharsh7",
    "github_project": "flakeradar#readme",
    "github_not_found": true,
    "lcname": "flakeradar"
}
        
Elapsed time: 1.62311s