Conversation
- Add documentation note explaining that in Woodpecker 3.x, build.status is always "success", which affects message templates - Recommend using the when.status condition to separate success and failure notifications, with example YAML provided - Clarify that this issue results from upstream Woodpecker CI changes and is not fixable in the plugin Signed-off-by: appleboy <appleboy.tw@gmail.com>
|
Caution Review failedThe pull request is closed. WalkthroughA new documentation section was added to address the behavior of the Changes
Assessment against linked issues
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Summary of Changes
Hello @appleboy, 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 updates the project's documentation to address a significant change in Woodpecker CI version 3.x, where the build.status variable consistently reports 'success'. The primary goal is to inform users about this behavior and provide a clear, actionable workaround using when.status conditions to ensure accurate success and failure notifications, while also noting that this is an upstream limitation.
Highlights
- Documentation Update: A new section titled 'Note for Woodpecker 3.x Users' has been added to the
DOCS.mdfile. - Woodpecker 3.x Build Status Clarification: The documentation now explains that in Woodpecker 3.x, the
build.statusvariable is alwayssuccess, which impacts message templates for notifications. - Recommended Notification Workaround: A workaround is provided, recommending the use of the
when.statuscondition to separate success and failure notifications, complete with example YAML configurations for Discord. - Upstream Limitation Acknowledged: The documentation clarifies that this change in behavior is due to upstream Woodpecker CI and cannot be fixed within the plugin itself.
Using Gemini Code Assist
The 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 in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
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 .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist is currently in preview and 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 to provide feedback.
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
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Code Review
This pull request updates the documentation to inform users about a behavioral change in Woodpecker 3.x where build.status is always success. The added section clearly explains the issue and provides a practical workaround using when.status conditions, which is very helpful. I've made one suggestion to improve the formatting and clarity of the explanation. Overall, this is a valuable documentation update.
There was a problem hiding this comment.
Actionable comments posted: 0
🔭 Outside diff range comments (1)
DOCS.md (1)
136-140: Clarifybuild.statusbehavior across versions & avoid conflicting informationThe Template Reference table (lines 136-140) still says that
build.statuscan be eithersuccessorfailure, while the new Woodpecker 3.x note (lines 200-227) states it is alwayssuccess. Readers of the 3.x section will immediately notice the contradiction.Suggest:
@@ -build.status -: build status type enumeration, either `success` or `failure` +build.status +: build status of the build step. + • Drone / Woodpecker < 3.x → `success` or `failure` + • Woodpecker ≥ 3.x → always `success` (see note below)This small amendment keeps the reference section self-consistent and prevents confusion.
Also applies to: 200-227
🧹 Nitpick comments (2)
DOCS.md (2)
203-204: Minor wording nit – tighten the sentenceCurrent sentence is slightly wordy:
…which means message templates cannot correctly distinguish between success and failure.
Consider:
-Starting from Woodpecker 3.x, the `build.status` variable is always set to `success`, which means message templates cannot correctly distinguish between success and failure. +Starting from Woodpecker 3.x, `build.status` is always `success`, so message templates can no longer distinguish between successful and failed builds.Makes the statement crisper without altering the intent.
205-225: Add a cross-reference to upstream issue for traceabilityIncluding a direct link to the upstream Woodpecker discussion/commit that introduced the behaviour helps users verify the claim and track progress.
@@ -```yaml +# See: https://github.com/woodpecker-ci/woodpecker/issues/<id> +```yaml(Replace
<id>with the actual issue/PR number if available.)
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
fix #64
Summary by CodeRabbit
build.statusvariable and its impact on message templates.when.status.