Files
hack/tools/scripts/llm-key-hunter/results/_cache/content/ballcard_zjuhex.json
T

1 line
11 KiB
JSON

{"repo": "ballcard/zjuhex", "files": {".github/workflows/ci-cd.yml": {"08ca7fe43261ce30e2a84ea2034f8bd7cdcee337": {"t": 1785747039.642731, "n": 5136, "h": "454c0297fe5f9ec0", "c": "name: CI/CD Pipeline\n\non:\n push:\n branches: [main, feature/ci-cd-auto-deploy]\n pull_request:\n branches: [main]\n workflow_dispatch:\n schedule:\n - cron: '0 0 * * 0' # Weekly Sunday midnight\n\nenv:\n NODE_VERSION: '22'\n PYTHON_VERSION: '3.10'\n\njobs:\n # Job 1: Lint and Type Check\n frontend-lint:\n name: Frontend Lint & Type Check\n runs-on: ubuntu-latest\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Type check\n run: npm run lint\n\n # Job 2: Build Frontend\n frontend-build:\n name: Frontend Build\n runs-on: ubuntu-latest\n needs: frontend-lint\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Build\n run: npm run build\n\n - name: Upload build artifacts\n uses: actions/upload-artifact@v4\n with:\n name: frontend-dist\n path: src/frontend_new/dist\n retention-days: 7\n\n # Job 3: Python Backend Tests\n backend-test:\n name: Backend Tests\n runs-on: ubuntu-latest\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Python\n uses: actions/setup-python@v5\n with:\n python-version: ${{ env.PYTHON_VERSION }}\n cache: 'pip'\n cache-dependency-path: requirements.txt\n\n - name: Install dependencies\n run: |\n python -m pip install --upgrade pip\n pip install -r requirements.txt\n pip install pytest pytest-cov\n\n - name: Run tests\n env:\n DEEPSEEK_API_KEY: ${{ secrets.DEEPSEEK_API_KEY }}\n run: |\n pytest tests/ -v --tb=short --ignore=tests/test_e2e.py --ignore=tests/test_integration_async.py -x || true\n\n # Job 4: Deploy to Pages (Frontend Only)\n deploy-frontend:\n name: Deploy Frontend to GitHub Pages\n runs-on: ubuntu-latest\n needs: frontend-build\n if: github.ref == 'refs/heads/main'\n permissions:\n contents: read\n pages: write\n id-token: write\n\n environment:\n name: github-pages\n url: ${{ steps.deployment.outputs.page_url }}\n\n outputs:\n page_url: ${{ steps.deployment.outputs.page_url }}\n\n steps:\n - name: Download artifacts\n uses: actions/download-artifact@v4\n with:\n name: frontend-dist\n\n - name: Setup Pages\n uses: actions/configure-pages@v5\n\n - name: Upload to Pages\n uses: actions/upload-pages-artifact@v3\n with:\n path: .\n\n - name: Deploy to GitHub Pages\n id: deployment\n uses: actions/deploy-pages@v4\n\n # Job 5: Auto Test after Deploy\n post-deploy-test:\n name: Post-Deploy Smoke Test\n runs-on: ubuntu-latest\n needs: deploy-frontend\n timeout-minutes: 5\n\n steps:\n - name: Wait for deployment\n run: sleep 30\n\n - name: Smoke test deployed site\n run: |\n DEPLOYED_URL=\"${{ needs.deploy-frontend.outputs.page_url }}\"\n echo \"Testing: $DEPLOYED_URL\"\n\n # Simple HTTP check via curl\n HTTP_CODE=$(curl -s -o /dev/null -w \"%{http_code}\" \"$DEPLOYED_URL\" || echo \"000\")\n\n if [ \"$HTTP_CODE\" = \"200\" ] || [ \"$HTTP_CODE\" = \"301\" ] || [ \"$HTTP_CODE\" = \"302\" ]; then\n echo \"✅ Site is accessible (HTTP $HTTP_CODE)\"\n exit 0\n else\n echo \"❌ Site returned HTTP $HTTP_CODE\"\n exit 1\n fi\n\n # Job 6: E2E Test (Optional - runs on schedule or manual trigger)\n e2e-test:\n name: End-to-End Tests\n runs-on: ubuntu-latest\n needs: frontend-build\n if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Install Playwright browsers\n run: npx playwright install --with-deps chromium\n\n - name: Start dev server\n run: |\n npm run dev &\n npx wait-on http://localhost:3000 --timeout 60000\n\n - name: Run E2E tests\n run: npx playwright test\n env:\n CI: 'true'\n\n - name: Upload test results\n if: failure()\n uses: actions/upload-artifact@v4\n with:\n name: playwright-results\n path: src/frontend_new/test-results/\n"}, "c79540f9622a7d3eb9d2762dffcf46026680138c": {"t": 1785769956.6711771, "n": 5136, "h": "454c0297fe5f9ec0", "c": "name: CI/CD Pipeline\n\non:\n push:\n branches: [main, feature/ci-cd-auto-deploy]\n pull_request:\n branches: [main]\n workflow_dispatch:\n schedule:\n - cron: '0 0 * * 0' # Weekly Sunday midnight\n\nenv:\n NODE_VERSION: '22'\n PYTHON_VERSION: '3.10'\n\njobs:\n # Job 1: Lint and Type Check\n frontend-lint:\n name: Frontend Lint & Type Check\n runs-on: ubuntu-latest\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Type check\n run: npm run lint\n\n # Job 2: Build Frontend\n frontend-build:\n name: Frontend Build\n runs-on: ubuntu-latest\n needs: frontend-lint\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Build\n run: npm run build\n\n - name: Upload build artifacts\n uses: actions/upload-artifact@v4\n with:\n name: frontend-dist\n path: src/frontend_new/dist\n retention-days: 7\n\n # Job 3: Python Backend Tests\n backend-test:\n name: Backend Tests\n runs-on: ubuntu-latest\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Python\n uses: actions/setup-python@v5\n with:\n python-version: ${{ env.PYTHON_VERSION }}\n cache: 'pip'\n cache-dependency-path: requirements.txt\n\n - name: Install dependencies\n run: |\n python -m pip install --upgrade pip\n pip install -r requirements.txt\n pip install pytest pytest-cov\n\n - name: Run tests\n env:\n DEEPSEEK_API_KEY: ${{ secrets.DEEPSEEK_API_KEY }}\n run: |\n pytest tests/ -v --tb=short --ignore=tests/test_e2e.py --ignore=tests/test_integration_async.py -x || true\n\n # Job 4: Deploy to Pages (Frontend Only)\n deploy-frontend:\n name: Deploy Frontend to GitHub Pages\n runs-on: ubuntu-latest\n needs: frontend-build\n if: github.ref == 'refs/heads/main'\n permissions:\n contents: read\n pages: write\n id-token: write\n\n environment:\n name: github-pages\n url: ${{ steps.deployment.outputs.page_url }}\n\n outputs:\n page_url: ${{ steps.deployment.outputs.page_url }}\n\n steps:\n - name: Download artifacts\n uses: actions/download-artifact@v4\n with:\n name: frontend-dist\n\n - name: Setup Pages\n uses: actions/configure-pages@v5\n\n - name: Upload to Pages\n uses: actions/upload-pages-artifact@v3\n with:\n path: .\n\n - name: Deploy to GitHub Pages\n id: deployment\n uses: actions/deploy-pages@v4\n\n # Job 5: Auto Test after Deploy\n post-deploy-test:\n name: Post-Deploy Smoke Test\n runs-on: ubuntu-latest\n needs: deploy-frontend\n timeout-minutes: 5\n\n steps:\n - name: Wait for deployment\n run: sleep 30\n\n - name: Smoke test deployed site\n run: |\n DEPLOYED_URL=\"${{ needs.deploy-frontend.outputs.page_url }}\"\n echo \"Testing: $DEPLOYED_URL\"\n\n # Simple HTTP check via curl\n HTTP_CODE=$(curl -s -o /dev/null -w \"%{http_code}\" \"$DEPLOYED_URL\" || echo \"000\")\n\n if [ \"$HTTP_CODE\" = \"200\" ] || [ \"$HTTP_CODE\" = \"301\" ] || [ \"$HTTP_CODE\" = \"302\" ]; then\n echo \"✅ Site is accessible (HTTP $HTTP_CODE)\"\n exit 0\n else\n echo \"❌ Site returned HTTP $HTTP_CODE\"\n exit 1\n fi\n\n # Job 6: E2E Test (Optional - runs on schedule or manual trigger)\n e2e-test:\n name: End-to-End Tests\n runs-on: ubuntu-latest\n needs: frontend-build\n if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'\n defaults:\n run:\n working-directory: src/frontend_new\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node.js\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n cache: 'npm'\n cache-dependency-path: src/frontend_new/package-lock.json\n\n - name: Install dependencies\n run: npm ci\n\n - name: Install Playwright browsers\n run: npx playwright install --with-deps chromium\n\n - name: Start dev server\n run: |\n npm run dev &\n npx wait-on http://localhost:3000 --timeout 60000\n\n - name: Run E2E tests\n run: npx playwright test\n env:\n CI: 'true'\n\n - name: Upload test results\n if: failure()\n uses: actions/upload-artifact@v4\n with:\n name: playwright-results\n path: src/frontend_new/test-results/\n"}}}}