fix: add sqlite3 to setup.sh required dependencies#4935
fix: add sqlite3 to setup.sh required dependencies#4935alex-solovyev merged 2 commits intomarcusquinn:mainfrom
Conversation
sqlite3 is used by 700+ callsites across the framework (memory system, worktree registry, supervisor, observability) but was never installed during setup. On Linux systems without sqlite3 pre-installed, these features fail silently. Adds sqlite3 to check_requirements() with correct package name mapping: sqlite3 for Debian/Ubuntu/brew, sqlite for Fedora/Arch/Alpine.
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses a critical dependency issue by integrating Highlights
Changelog
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
WalkthroughAdds a runtime dependency check for sqlite3 inside Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
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 |
There was a problem hiding this comment.
Code Review
This pull request correctly adds sqlite3 as a required dependency, handling different package names across various distributions. The change is solid. I've added one suggestion to improve efficiency by avoiding a redundant function call in the script.
| local pkg_mgr | ||
| pkg_mgr=$(detect_package_manager) |
There was a problem hiding this comment.
This call to detect_package_manager is redundant, as the same function is called again on line 459 if any dependencies are missing. To improve efficiency, you could call detect_package_manager once at the beginning of the check_requirements function and store the result in a variable for reuse.
References
- Avoid redundant pre-checks or function calls that perform checks, especially when a helper function handles the logic internally. This prevents logic duplication and improves efficiency.
|
External contributor PR — labelled |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@setup-modules/core.sh`:
- Around line 444-453: The package mapping in the sqlite detection block wrongly
maps brew to "sqlite3"; update the case in the block that uses
detect_package_manager (the pkg_mgr variable and the case "$pkg_mgr" branch) so
that apt maps to "sqlite3" while brew maps to "sqlite" (e.g., use separate
cases: "apt") missing_packages+=("sqlite3") ;; and "brew")
missing_packages+=("sqlite") ;;), leaving the fallback (*) as "sqlite" for
Fedora/Arch/Alpine.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 7cb93215-a7d6-40d5-a513-ccbd3a5122ca
📒 Files selected for processing (1)
setup-modules/core.sh
Homebrew's formula is 'sqlite' (sqlite3 is an alias). While the alias works, using the canonical name is more robust. Separate apt case from the wildcard fallback which now correctly handles brew, dnf, pacman, and apk. Addresses CodeRabbit review feedback on PR marcusquinn#4935.
|
Pushed fix commit (13f05ab) addressing CodeRabbit's review feedback:
CI should re-run on the new commit. Once green, this is ready for maintainer merge. |
Summary
sqlite3tocheck_requirements()insetup-modules/core.shso it is installed duringsetup.shsqlite3for Debian/Ubuntu/brew,sqlitefor Fedora/Arch/AlpineChanges
setup-modules/core.sh: Added sqlite3 check tocheck_requirements()with distro-aware package name resolutionSummary by CodeRabbit