Skip to content

Conversation

@BaptisteGi
Copy link
Contributor

@BaptisteGi BaptisteGi commented Nov 6, 2025

Summary by CodeRabbit

  • Chores
    • Adds automated posting of release announcements to Discord whenever a release is published.
    • Release messages include consistent formatting, a "Changelog" footer, reduced heading verbosity, and a set embed color.
    • Workflow uses a configured Discord webhook and includes examples for optional message fields (username, avatar, content).

@github-actions github-actions bot added the group/ci Issue related to the CI pipeline label Nov 6, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 6, 2025

Walkthrough

A GitHub Actions workflow file was added at .github/workflows/github-releases-to-discord.yml. The workflow triggers on release events with types: [published]. It defines a job github-releases-to-discord that runs on ubuntu-latest and has two steps: checkout the repository using actions/checkout@v4, then run SethCohen/github-releases-to-discord@b96a33520f8ad5e6dcdecee6f1212bdf88b16550 to post release info to Discord. The action receives webhook_url from secrets.DISCORD_WEBHOOK_URL, color: "2105893", footer_title: "Changelog", and reduce_headings: true; example username, avatar_url, and content inputs are commented.

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding a GitHub Actions workflow to send release notes to Discord via webhook.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch bgi-discord-release-channel

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6cfcef3 and 619940c.

📒 Files selected for processing (1)
  • .github/workflows/github-releases-to-discord.yml (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • .github/workflows/github-releases-to-discord.yml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Cloudflare Pages

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 14fcce2 and 13a872f.

📒 Files selected for processing (1)
  • .github/workflows/github-releases-to-discord.yml (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
.github/workflows/**/*.{yml,yaml}

📄 CodeRabbit inference engine (.github/instructions/tooling.instructions.md)

Prefer GitHub Actions for automated validation when users commit to the repository

Files:

  • .github/workflows/github-releases-to-discord.yml
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: opsmill/infrahub PR: 0
File: .github/instructions/tooling.instructions.md:0-0
Timestamp: 2025-08-21T11:05:34.803Z
Learning: Applies to .github/workflows/**/*.{yml,yaml} : Prefer GitHub Actions for automated validation when users commit to the repository
🪛 GitHub Actions: CI
.github/workflows/github-releases-to-discord.yml

[warning] 5-5: Document missing document start '---'.


[warning] 5-5: Truthiness check suggests value should be one of [false, true].


[error] 1-1: Process completed with exit code 2.

🪛 GitHub Check: yaml-lint
.github/workflows/github-releases-to-discord.yml

[warning] 5-5:
5:1 [truthy] truthy value should be one of [false, true]


[warning] 5-5:
5:1 [document-start] missing document start "---"

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Cloudflare Pages
🔇 Additional comments (2)
.github/workflows/github-releases-to-discord.yml (2)

15-16: Ensure the DISCORD_WEBHOOK_URL secret is properly configured.

The workflow references secrets.DISCORD_WEBHOOK_URL. Verify that this secret has been added to the repository settings, otherwise the workflow will fail at runtime.


16-17: No action needed—the color format is correct.

The code at line 17 correctly passes "2105893" as a decimal integer. The SethCohen/github-releases-to-discord action expects the color input as a decimal integer (not a hex string), and the default value is 2105893. The absence of a # prefix is correct and required.

BaptisteGi and others added 2 commits November 7, 2025 15:33
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 13a872f and 5a54c40.

📒 Files selected for processing (1)
  • .github/workflows/github-releases-to-discord.yml (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
.github/workflows/**/*.{yml,yaml}

📄 CodeRabbit inference engine (.github/instructions/tooling.instructions.md)

Prefer GitHub Actions for automated validation when users commit to the repository

Files:

  • .github/workflows/github-releases-to-discord.yml
🧠 Learnings (1)
📓 Common learnings
Learnt from: CR
Repo: opsmill/infrahub PR: 0
File: .github/instructions/tooling.instructions.md:0-0
Timestamp: 2025-08-21T11:05:34.803Z
Learning: Applies to .github/workflows/**/*.{yml,yaml} : Prefer GitHub Actions for automated validation when users commit to the repository
🪛 GitHub Actions: CI
.github/workflows/github-releases-to-discord.yml

[warning] 4-4: truthy value should be one of [false, true] (validation warning) from workflow step.


[error] 5-5: Process completed with exit code 2. GitHub Actions workflow step failed.

🪛 GitHub Check: yaml-lint
.github/workflows/github-releases-to-discord.yml

[warning] 4-4:
4:1 [truthy] truthy value should be one of [false, true]

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Cloudflare Pages
🔇 Additional comments (2)
.github/workflows/github-releases-to-discord.yml (2)

2-4: Verify that switching to manual trigger is intentional.

The workflow trigger has been changed from automatic (release: types: [published]) to manual (workflow_dispatch). The original configuration would post release notes automatically when a release is published, whereas the current configuration requires manual triggering. Confirm this behavior change is intentional for your release process.


13-13: Action versioning is appropriately pinned.

The use of an exact commit hash for the SethCohen action mitigates supply-chain risks and prevents unexpected action updates. Well done.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5a54c40 and 922d5cd.

📒 Files selected for processing (1)
  • .github/workflows/github-releases-to-discord.yml (1 hunks)
🧰 Additional context used
🪛 GitHub Actions: CI
.github/workflows/github-releases-to-discord.yml

[error] 12-15: The runner of actions/checkout@v3 is too old to run on GitHub Actions. update the action's version to fix this issue

🪛 GitHub Check: yaml-lint
.github/workflows/github-releases-to-discord.yml

[warning] 3-3:
3:1 [truthy] truthy value should be one of [false, true]

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Cloudflare Pages
🔇 Additional comments (3)
.github/workflows/github-releases-to-discord.yml (3)

3-5: YAML trigger configuration is correct.

The workflow trigger is now properly formatted with correct YAML block syntax. The trigger will execute when releases are published to the repository.


14-14: Exact action versioning is good security practice.

Using the full SHA commit reference (@b96a33520f8ad5e6dcdecee6f1212bdf88b16550) on the third-party action prevents hijacking and ensures reproducibility. This aligns with the earlier suggestion to use exact ref versioning.


16-16: DISCORD_WEBHOOK_URL secret must be configured in repository settings.

The workflow references ${{ secrets.DISCORD_WEBHOOK_URL }} on line 16. Verify this secret exists in your repository's Settings > Secrets and variables > Actions—the workflow will fail at runtime if it's missing.

To verify, run:

gh secret list --app actions

This requires gh CLI authentication with appropriate repository permissions.

@BaptisteGi BaptisteGi merged commit b8284cc into stable Nov 18, 2025
34 checks passed
@BaptisteGi BaptisteGi deleted the bgi-discord-release-channel branch November 18, 2025 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

group/ci Issue related to the CI pipeline

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants