Skip to content

LCORE-2978: Added Release Jiras - #2095

Merged
tisnik merged 1 commit into
lightspeed-core:mainfrom
jrobertboos:lcore-2978
Jul 8, 2026
Merged

tisnik merged 1 commit into
lightspeed-core:mainfrom
jrobertboos:lcore-2978

Conversation

@jrobertboos

@jrobertboos jrobertboos commented Jul 8, 2026 •

Copy link
Copy Markdown
Contributor

Description

Add a reusable release checklist template (dev-tools/release-jiras.md) and extend file-jiras.sh with --var KEY=VALUE placeholder substitution so the same template can be used for every release by supplying version numbers at invocation time. Also introduces the <!-- no-epic --> directive to skip auto-Epic generation, allowing tickets to be filed directly under a parent feature ticket — appropriate for release checklists that don't need an Epic wrapper.

Type of change

  • Refactor
  • New feature
  • Bug fix
  • CVE fix
  • Optimization
  • Documentation Update
  • Configuration Update
  • Bump-up service version
  • Bump-up dependent library
  • Bump-up library or tool used for development (does not change the final image)
  • CI configuration change
  • Konflux configuration change
  • Unit tests improvement
  • Integration tests improvement
  • End to end tests improvement
  • Benchmarks improvement

Tools used to create PR

Identify any AI code assistants used in this PR (for transparency and review context)

  • Assisted-by: Cursor
  • Generated by: N/A

Related Tickets & Documents

  • Related Issue LCORE-2978

Checklist before requesting a review

  • I have performed a self-review of my code.
  • PR has passed all pre-merge test jobs.
  • If it is a core feature, I have added thorough tests.

Testing

  • Ran file-jiras.sh --parse-only on release-jiras.md with --var substitutions to verify placeholder replacement, <!-- no-epic --> parsing, and correct ticket file output
  • Performed a manual filing dry run to confirm tickets are created under the parent feature ticket without an Epic wrapper
  • Verified unreplaced placeholder warnings are emitted when --var arguments are omitted

Summary by CodeRabbit

  • New Features

    • Added support for reusable placeholders when generating JIRA tickets, making release and spike templates easier to customize.
    • Added a standardized release-JIRA template document with prebuilt ticket outlines for common release tasks.
  • Bug Fixes

    • Improved ticket extraction so only user-authored content is included in generated descriptions.
    • Made parsing more flexible for entries marked as not needing an epic, avoiding unnecessary validation errors.

@coderabbitai

coderabbitai Bot commented Jul 8, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

This PR modifies dev-tools/file-jiras.sh to add a --var KEY=VALUE CLI option for placeholder substitution and a <!-- no-epic --> directive that suppresses epic generation, adjusting lint checks and description extraction accordingly. It also adds a new dev-tools/release-jiras.md documentation file with release JIRA task templates.

Changes

file-jiras.sh Enhancements

Layer / File(s) Summary
CLI --var option and placeholder substitution
dev-tools/file-jiras.sh
Adds a repeatable --var KEY=VALUE option, updates help text, and preprocesses the spike doc in embedded Python to replace {KEY} tokens, warning on unreplaced placeholders.
no-epic parse mode and lint/extraction updates
dev-tools/file-jiras.sh
Adds parse modes (empty, no_epic) triggered by a <!-- no-epic --> directive, merges resulting tickets into incidental JIRAs, skips the zero-JIRA lint error in no_epic mode, and strips additional metadata comment types from description bodies.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Release JIRA Templates

Layer / File(s) Summary
Release JIRA task templates
dev-tools/release-jiras.md
New documentation defining version placeholders and JIRA task templates covering release branching, version bump, openapi regeneration, tagging, release notes, Quay.io image publishing, Konflux promotion to registry.redhat.io, and versions doc updates for lightspeed-stack and rag-content.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Suggested reviewers: tisnik

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is concise and accurately reflects the main change: adding release JIRA support.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
✨ Simplify code
  • Create PR with simplified code

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@dev-tools/file-jiras.sh`:
- Around line 13-20: The usage/help text for file-jiras.sh currently describes
only the Epic-based flow, but it also supports a direct filing path when the
document includes no-epic. Update the script’s top-level flow description and
any help/usage output referenced by the main flow comments so they clearly
distinguish the default Epic-first behavior from the no-epic case; point readers
to the existing ticket-parsing and filing flow in file-jiras.sh so release
templates are discoverable.
- Around line 72-78: Validate --var entries in file-jiras.sh against the
supported placeholder syntax before appending to PLACEHOLDER_VARS: the current
argument parsing in the --var case accepts any KEY=VALUE, but only uppercase
brace-style placeholders are actually substituted later. Update the --var
handling so it rejects unsupported keys like empty names or lowercase keys up
front, and align the same validation in the related parsing block referenced by
the duplicate location. Keep the checks near the existing --var case and reuse
the same placeholder rules used by the warning/substitution logic.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 1ab774af-766c-472e-ad50-0d3e11a5f213

📥 Commits

Reviewing files that changed from the base of the PR and between 52f2d12 and 3df04a7.

📒 Files selected for processing (2)
  • dev-tools/file-jiras.sh
  • dev-tools/release-jiras.md
📜 Review details
⏰ Context from checks skipped due to timeout. (15)
  • GitHub Check: check_dependencies
  • GitHub Check: integration_tests (3.13)
  • GitHub Check: integration_tests (3.12)
  • GitHub Check: Pylinter
  • GitHub Check: build-pr
  • GitHub Check: unit_tests (3.12)
  • GitHub Check: unit_tests (3.13)
  • GitHub Check: Konflux kflux-prd-rh02 / lightspeed-stack-0-7-on-pull-request
  • GitHub Check: E2E Tests for Lightspeed Evaluation job
  • GitHub Check: E2E: library mode / ci / group 3
  • GitHub Check: E2E: server mode / ci / group 2
  • GitHub Check: E2E: library mode / ci / group 2
  • GitHub Check: E2E: server mode / ci / group 3
  • GitHub Check: E2E: library mode / ci / group 1
  • GitHub Check: E2E: server mode / ci / group 1
🔇 Additional comments (2)
dev-tools/release-jiras.md (1)

1-211: LGTM!

dev-tools/file-jiras.sh (1)

34-42: LGTM!

Also applies to: 47-59, 179-179, 189-197, 316-323, 337-340, 349-352, 405-407, 458-460, 773-773

Comment thread dev-tools/file-jiras.sh
Comment on lines 13 to +20
# The script:
# 1. Parses JIRA sections from the spike doc (### LCORE-???? headings)
# 2. Auto-generates an Epic stub (ticket #0)
# 3. Reads <!-- type: Task/Story/Epic --> metadata from each ticket
# 4. Opens an interactive menu: view, edit, drop, file
# 5. Files Epic first, then children under it
# 6. Links spike ticket to Epic with "Informs" relationship
# 1. Replaces {KEY} placeholders with --var values (if any)
# 2. Parses JIRA sections from the doc (### LCORE-???? headings)
# 3. Auto-generates an Epic stub (ticket #0)
# 4. Reads <!-- type: Task/Story/Epic --> metadata from each ticket
# 5. Opens an interactive menu: view, edit, drop, file
# 6. Files Epic first, then children under it
# 7. Links spike ticket to Epic with "Informs" relationship

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Document the no-epic flow in usage/help.

The top-level flow still says the script always auto-generates/files an Epic and links the feature ticket to it, but <!-- no-epic --> files tickets directly under the feature ticket. Add a short help/doc note so release templates are discoverable and the flow description is conditional.

Also applies to: 43-46

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@dev-tools/file-jiras.sh` around lines 13 - 20, The usage/help text for
file-jiras.sh currently describes only the Epic-based flow, but it also supports
a direct filing path when the document includes no-epic. Update the script’s
top-level flow description and any help/usage output referenced by the main flow
comments so they clearly distinguish the default Epic-first behavior from the
no-epic case; point readers to the existing ticket-parsing and filing flow in
file-jiras.sh so release templates are discoverable.

Comment thread dev-tools/file-jiras.sh
Comment on lines +72 to +78
--var)
[ $# -ge 2 ] || { echo "Error: --var requires KEY=VALUE"; exit 1; }
case "$2" in
*=*) PLACEHOLDER_VARS+=("$2") ;;
*) echo "Error: --var value must be KEY=VALUE (got '$2')"; exit 1 ;;
esac
shift 2 ;;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Validate --var keys against the supported placeholder syntax.

--var =foo or --var x=1 currently passes argument parsing, but the warning regex only treats {UPPER_SNAKE} as placeholders. Reject unsupported keys up front to avoid confusing no-op substitutions.

Proposed fix
         --var)
             [ $# -ge 2 ] || { echo "Error: --var requires KEY=VALUE"; exit 1; }
             case "$2" in
-                *=*) PLACEHOLDER_VARS+=("$2") ;;
+                *=*)
+                    key="${2%%=*}"
+                    case "$key" in
+                        ''|*[!A-Z0-9_]*|[0-9_]*)
+                            echo "Error: --var key must match [A-Z][A-Z0-9_]* (got '$key')"
+                            exit 1
+                            ;;
+                    esac
+                    PLACEHOLDER_VARS+=("$2")
+                    ;;
                 *) echo "Error: --var value must be KEY=VALUE (got '$2')"; exit 1 ;;
             esac
             shift 2 ;;

Also applies to: 189-196

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@dev-tools/file-jiras.sh` around lines 72 - 78, Validate --var entries in
file-jiras.sh against the supported placeholder syntax before appending to
PLACEHOLDER_VARS: the current argument parsing in the --var case accepts any
KEY=VALUE, but only uppercase brace-style placeholders are actually substituted
later. Update the --var handling so it rejects unsupported keys like empty names
or lowercase keys up front, and align the same validation in the related parsing
block referenced by the duplicate location. Keep the checks near the existing
--var case and reuse the same placeholder rules used by the warning/substitution
logic.

@tisnik tisnik left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@tisnik
tisnik merged commit 6323e67 into lightspeed-core:main Jul 8, 2026
26 of 29 checks passed
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