Skip to content

Add automated weekly patch release#170

Merged
carole-lavillonniere merged 1 commit intomainfrom
carole/drg-667
Mar 25, 2026
Merged

Add automated weekly patch release#170
carole-lavillonniere merged 1 commit intomainfrom
carole/drg-667

Conversation

@carole-lavillonniere
Copy link
Copy Markdown
Collaborator

@carole-lavillonniere carole-lavillonniere commented Mar 25, 2026

Motivation

Releases currently require a manual trigger. This automates patch releases every Thursday so we ship consistently without manual intervention.

Changes

  • Add automated-release.yml workflow: runs every Thursday at 10 AM UTC, checks for commits since the last tag, runs CI fresh, and creates a patch tag if everything is green
  • Make ci.yml callable as a reusable workflow (workflow_call) so the automated release can run CI before tagging
  • Make create-release-tag.yml callable as a reusable workflow (workflow_call) so the automated release reuses the existing tag creation logic without duplication

Tests

Not tested yet — workflow_dispatch requires the workflow to exist on the default branch, so it can only be triggered after this is merged:

gh workflow run automated-release.yml --repo localstack/lstk

Closes DRG-667

@carole-lavillonniere carole-lavillonniere marked this pull request as ready for review March 25, 2026 16:36
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 25, 2026

📝 Walkthrough

Walkthrough

Three GitHub Actions workflow files are modified: a new automated weekly release workflow is introduced that conditionally runs CI and creates release tags based on detected changes since the latest tag, while two existing workflows are updated to be reusable via workflow_call triggers.

Changes

Cohort / File(s) Summary
Automated Release Workflow
/.github/workflows/automated-release.yml
New workflow that runs weekly (Thursdays at 10:00 UTC) and on manual trigger. Includes check-changes job to detect commits since the latest v0.*.* tag, with conditional downstream ci and create-tag jobs gated on has_changes output.
Workflow Call Integration
/.github/workflows/ci.yml, /.github/workflows/create-release-tag.yml
Added workflow_call trigger to enable reusability by other workflows. create-release-tag.yml defines public inputs release_ref (default: main) and bump (required, type: string).

Sequence Diagram

sequenceDiagram
    participant Trigger as Schedule/Manual Trigger
    participant CheckChanges as check-changes Job
    participant CI as ci Job
    participant CreateTag as create-tag Job
    participant Repo as Repository

    Trigger->>CheckChanges: Run workflow
    CheckChanges->>Repo: Fetch all tags
    CheckChanges->>Repo: Get latest v0.*.* tag
    CheckChanges->>Repo: Check commits since tag
    CheckChanges-->>CI: Set has_changes output
    
    alt has_changes == true
        CI->>CI: Run CI workflow
        CI-->>CreateTag: CI complete
        CreateTag->>Repo: Create patch bump release tag
        CreateTag->>Repo: Push tag to main
    else has_changes == false
        Note over CI,CreateTag: Both jobs skipped
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately captures the main change: adding automation for weekly patch releases, which is the primary objective of this PR.
Description check ✅ Passed The description is well-related to the changeset, providing clear motivation, specific details about the three workflow files modified, and testing instructions.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch carole/drg-667

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
Copy Markdown

@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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/workflows/create-release-tag.yml:
- Around line 19-23: The workflow input "release_ref" currently has both
required: true and a default value, which is inconsistent; edit the GitHub
Actions workflow input definition for release_ref to remove either the required:
true line or the default key—preferably remove required: true so callers may
omit the input and the default "main" is used; locate the release_ref input
block in the create-release-tag.yml and update it accordingly (keep description
and type as-is).

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: 2a804693-e5ac-43e9-b0c3-85942c061ff1

📥 Commits

Reviewing files that changed from the base of the PR and between fbc5854 and 512ed86.

📒 Files selected for processing (3)
  • .github/workflows/automated-release.yml
  • .github/workflows/ci.yml
  • .github/workflows/create-release-tag.yml

Comment on lines +19 to +23
release_ref:
description: Git ref to tag
required: true
default: main
type: string
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Remove required: true or default for release_ref input.

The static analysis tool flagged this: when an input is marked as required: true, its default value is never used because callers must always provide a value. This creates a semantic inconsistency.

Since the automated-release workflow explicitly provides release_ref: main, consider removing required: true to allow future callers to optionally rely on the default:

Proposed fix
   workflow_call:
     inputs:
       release_ref:
         description: Git ref to tag
-        required: true
+        required: false
         default: main
         type: string
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
release_ref:
description: Git ref to tag
required: true
default: main
type: string
release_ref:
description: Git ref to tag
required: false
default: main
type: string
🧰 Tools
🪛 actionlint (1.7.11)

[error] 22-22: input "release_ref" of workflow_call event has the default value "main", but it is also required. if an input is marked as required, its default value will never be used

(events)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/create-release-tag.yml around lines 19 - 23, The workflow
input "release_ref" currently has both required: true and a default value, which
is inconsistent; edit the GitHub Actions workflow input definition for
release_ref to remove either the required: true line or the default
key—preferably remove required: true so callers may omit the input and the
default "main" is used; locate the release_ref input block in the
create-release-tag.yml and update it accordingly (keep description and type
as-is).

Copy link
Copy Markdown
Member

@silv-io silv-io left a comment

Choose a reason for hiding this comment

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

LGTM!

@carole-lavillonniere carole-lavillonniere merged commit 4c01efd into main Mar 25, 2026
8 checks passed
@carole-lavillonniere carole-lavillonniere deleted the carole/drg-667 branch March 25, 2026 16:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants