Conversation
Summary of ChangesHello @gaojunran, 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 bug where readiness commands might not execute correctly due to an implicit or incorrect current working directory. By explicitly setting the working directory for these commands to the daemon's directory, it ensures reliable execution of readiness checks. Highlights
Changelog
Activity
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
|
There was a problem hiding this comment.
Code Review
The pull request addresses an issue where the ready_cmd was not being executed in the correct working directory, leading to potential failures in readiness checks. The changes correctly capture the daemon's working directory and apply it to the ready_cmd execution. This is a good fix for the reported bug.
| let ready_http = opts.ready_http.clone(); | ||
| let ready_port = opts.ready_port; | ||
| let ready_cmd = opts.ready_cmd.clone(); | ||
| let daemon_dir = opts.dir.clone(); |
There was a problem hiding this comment.
Pull request overview
This PR fixes readiness-check command execution by ensuring ready_cmd is spawned with the daemon’s configured working directory (opts.dir), aligning command readiness checks with how the daemon process itself is launched.
Changes:
- Capture the daemon working directory from
RunOptions. - Set
current_dirwhen spawning theready_cmdreadiness check command.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| let mut command = Shell::default_for_platform().command(cmd); | ||
| command | ||
| .current_dir(&daemon_dir) | ||
| .stdout(std::process::Stdio::null()) | ||
| .stderr(std::process::Stdio::null()); | ||
| let result: std::io::Result<std::process::ExitStatus> = command.status().await; |
There was a problem hiding this comment.
The new behavior of running ready_cmd with the daemon’s working directory isn’t covered by existing tests. There is already an e2e test for ready_cmd, but it uses an absolute path so it wouldn’t catch regressions where the readiness command runs from the supervisor’s CWD. Please add/adjust an e2e test to use a relative path (e.g., have the daemon create ./ready in its configured dir and set ready_cmd = "test -f ./ready").
## 🤖 New release * `pitchfork-cli`: 1.5.0 -> 1.6.0 <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [1.6.0](v1.5.0...v1.6.0) - 2026-02-21 ### Added - *(web)* add PITCHFORK_WEB_PATH support for reverse proxy path prefixes ([#244](#244)) - add daemon lifecycle hooks and retry count env vars ([#245](#245)) ### Fixed - pass cwd to ready_cmd spawning ([#243](#243)) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Low Risk** > Release-only version/documentation updates; no functional code changes are included in this diff. > > **Overview** > Prepares the `pitchfork-cli` **v1.6.0** release by bumping the crate/version metadata from `1.5.0` to `1.6.0` (including `Cargo.toml`, `Cargo.lock`, and generated CLI docs/spec files). > > Updates `CHANGELOG.md` with the new `1.6.0` entry summarizing the release’s added features and the `ready_cmd` working-directory fix. > > <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit e00649e. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup> <!-- /CURSOR_SUMMARY --> --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
fixes #240.