fix(scripts): accept installed ca-certificates without update-ca-certificates on PATH#372
Conversation
…ificates on PATH Linux prerequisite check required update-ca-certificates in PATH even when the ca-certificates package is installed (e.g. Devuan), causing false failures. Match libncurses-dev-style dpkg verification and keep command fallback. Fixes rocketride-org#370 Made-with: Cursor
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
The only issue with this check would be if any of the components would actually try to execute |
Summary
Fix false-negative Linux prerequisite detection for
ca-certificateswhen the package is installed butupdate-ca-certificatesis not on the user PATH (reported on Devuan and similar). Aligns with existingdpkg-based checks in the same script.Bug
./builder build/./scripts/compiler-unix.shfails withca-certificates: update-ca-certificates not availableeven when theca-certificatespackage is installed.Steps to Reproduce
ca-certificatesis installed perdpkgbutupdate-ca-certificatesis not available on the invoking user PATH (see issue In certain Debian derivatives and some other Linuxes the ca-certificates check may always fail #370)../scripts/compiler-unix.shor./builder build.ca-certificates.Root Cause
ca-certificateswas validated only indirectly by requiring theupdate-ca-certificatescommand to be on PATH, unlike other packages that usedpkg -l ... ^iiin this same function.Fix
ca-certificatescase: pass ifdpkg -l ca-certificatesshows^iiorupdate-ca-certificatesexists on PATH.ca-certificates→update-ca-certificatescommand mapping.Why This Works
The script already uses
dpkg -lwith^iifor*-devand special-cases likelibncurses-dev. Treatingca-certificatesthe same way matches established intent: verify the installed package, not only a helper binary location.Testing / Validation
bash -n scripts/compiler-unix.sh(pass)./builder test --verboseblocked locally: CMake 4.3.0 rejected by macOS prerequisite check (environment issue, not caused by this diff). CI / another machine with supported CMake should run the full pipeline.Type
Checklist
dpkgchecks in the same file (libncurses-dev,*-dev).bash -n+ manual review of branch logic)./builder testpass status — blocked on this host (CMake version gate); no regression expected (Linux-only code path; macOS usescheck_mac_dependencies)Related Issues
Fixes #370