fix(discovery): tighten safe-install trust predicates#541
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI (base), Organization UI (inherited) Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (1)
📜 Recent review details⏰ Context from checks skipped due to timeout of 900000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
🧰 Additional context used📓 Path-based instructions (2)apps/web/src/**/*.{ts,tsx}📄 CodeRabbit inference engine (Custom checks)
Files:
apps/web/src/**/*📄 CodeRabbit inference engine (AGENTS.md)
Files:
🔇 Additional comments (3)
📝 WalkthroughSummary by CodeRabbit
WalkthroughThis PR consolidates install-trust signal evaluation by treating verified packages ( ChangesInstall trust signal consolidation
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 error, 2 inconclusive)
✅ Passed checks (5 passed)
✨ Finishing Touches✨ Simplify code
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint skipped: no ESLint configuration detected in root package.json. To enable, add Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Motivation
trustSignals.sourceStatus === "available"plus the absence ofdownloadUrlas a safe signal, allowing arbitraryinstallCommandorconfigSnippetto be surfaced under a misleading trust label.Description
downloadTrust === "first-party"orpackageVerified === trueinhasSafeInstallSignalinapps/web/src/lib/growth-surface-rules.ts.apps/web/src/lib/seo-clusters.tsso cluster inclusion matches the trusted-package semantics.apps/web/src/app/page.tsxto accurately describe the rail as "first-party package or verified package" installs.tests/discovery-surfaces.test.tsto remove the prior expectation that source-backed copyable/config entries qualify as safe-install.Testing
pnpm exec vitest run tests/discovery-surfaces.test.ts, and all tests passed (1 file, 5 testspassed).git diff --checkto validate no whitespace/diff issues and it reported clean.Codex Task