Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 35 additions & 22 deletions hyperfleet-jira/commands/team-weekly-update.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
description: "Weekly team update - a list of closed issues(Story,Task,Bug) in the last 7 days with a nested display : activity type -> Epic -> Story/Task/Bug in one team"
description: "Weekly team update - a list of closed issues(Story,Task,Bug) in the last 7 days with a nested display in one team"
allowed-tools: Bash
argument-hint: "[project-key] [team-key]"
---
Expand Down Expand Up @@ -39,7 +39,7 @@ Summary of team progress over the past week, focusing on closed issues classifie
For each activity type below, follow this three-step process to fetch issues and their parent Epic information:

**Step 1**: Get list of closed issue keys
**Step 2**: For each issue, fetch full details including epic link (customfield_12311140) and summary
**Step 2**: For each issue, fetch full details including parent epic (fields.parent) and summary
**Step 3**: Group issues by their parent Epic and fetch Epic details

### Activity Types to Process:
Expand All @@ -58,7 +58,7 @@ ACTIVITY_TYPES=(

# For each activity type, fetch closed issues:
for activity_type in "${ACTIVITY_TYPES[@]}"; do
jira issue list -q 'project = ${1:-HYPERFLEET} and type in (Story,Task,Bug) and status changed to "closed" during (-7d,now()) and cf[12320040] = "'"$activity_type"'" ${2:+and Team = $2}' --columns KEY --plain --no-headers 2>/dev/null
jira issue list -q 'project = ${1:-HYPERFLEET} and type in (Story,Task,Bug) and resolution = Done and status changed to closed during (-7d, now()) and customfield_10464 = "'"$activity_type"'" ${2:+and Team = $2}' --columns KEY --plain --no-headers 2>/dev/null
# Process each issue as described in "For Each Issue Retrieved" section below
done
```
Expand All @@ -67,55 +67,68 @@ Also check for issues without an activity type:

```bash
# Issues without activity type
jira issue list -q 'project = ${1:-HYPERFLEET} and type in (Story,Task,Bug) and status changed to "closed" during (-7d,now()) and cf[12320040] is EMPTY ${2:+and Team = $2}' --columns KEY --plain --no-headers 2>/dev/null
jira issue list -q 'project = ${1:-HYPERFLEET} and type in (Story,Task,Bug) and resolution = Done and status changed to closed during (-7d, now()) and customfield_10464 is EMPTY ${2:+and Team = $2}' --columns KEY --plain --no-headers 2>/dev/null
```

### For Each Issue Retrieved:

Get full issue details including epic link:
Get full issue details including parent epic:
```bash
jira issue view <ISSUE_KEY> --raw 2>/dev/null | jq -r '{key: .key, summary: .fields.summary, epicKey: .fields.customfield_12311140, status: .fields.status.name}'
jira issue view <ISSUE_KEY> --raw 2>/dev/null | jq -r '{key: .key, summary: .fields.summary, epicKey: .fields.parent.key, epicSummary: .fields.parent.fields.summary, epicStatus: .fields.parent.fields.status.name, status: .fields.status.name, type: .fields.issuetype.name}'
```

Note: If parent is null, the issue has no parent epic.

### For Each Unique Epic Key:

Get epic details:
1. Get epic details:
```bash
jira issue view <EPIC_KEY> --raw 2>/dev/null | jq -r '{key: .key, summary: .fields.summary, status: .fields.status.name, type: .fields.issuetype.name}'
```

2. Get all children of the epic and their status and calculate the complete_ratio of the Epic:
```bash
jira issue list -q "parent = <EPIC_KEY>" --raw 2>/dev/null | jq -r '.[] | {key: .key, status: .fields.status.name}'
```

## Output Format
complete_ratio = count(the number of Closed children issues) / count(the number of children issues) * 100

**Weekly [Team: team-key] Update - [Start Date] to [End Date]**
## Output Format

### Summary Stats
- Total number of closed issues
CRITICAL: You MUST create a THREE-LEVEL NESTED STRUCTURE. Do NOT skip any level:

### Issues Grouped by Activity Type, then by Parent Epic
---

For each activity type, group issues by their parent Epic and display in this nested structure:
**Weekly Team Update - [Start Date] to [End Date]**
**Team: [team-key]**

**Activity Type Name** (count)
### Summary Stats
- Total Done issues: [count]
---

**Epic: [EPIC-KEY] - [Epic Summary]** (Status: [Epic Status])
**[Activity Type Name]**
Comment thread
yufchang marked this conversation as resolved.
**Epic: [EPIC-KEY] - [Epic Summary]** (Status: [Epic Status], [Closed]/[Total], [%]%)
- [ISSUE-KEY]: [Issue Summary]
- [ISSUE-KEY]: [Issue Summary]


**Epic: [EPIC-KEY2] - [Epic Summary]** (Status: [Epic Status])
**Epic: [EPIC-KEY2] - [Epic Summary]** (Status: [Epic Status], [Closed]/[Total], [%]%)
- [ISSUE-KEY]: [Issue Summary]

**No Parent Epic**
- [ISSUE-KEY]: [Issue Summary]
- [ISSUE-KEY]: [[TYPE]] [Issue Summary]
- [ISSUE-KEY]: [[TYPE]] [Issue Summary]

---

Example:

**Quality / Stability / Reliability** (21 issues)
**Quality / Stability / Reliability**

**Epic: HYPERFLEET-402 - E2E Test Automation Framework for CLM Components - MVP** (Status: Closed)
**Epic: HYPERFLEET-402 - E2E Test Automation Framework for CLM Components - MVP** (Status: Closed, 9/10, 90%)
- HYPERFLEET-680: Migrate from kubectl CLI to Kubernetes client-go Library for E2E Testing
- HYPERFLEET-532: E2E Test Case Automation Run Strategy and Resource Management

**No Parent Epic**
- HYPERFLEET-682: Adapter1 and Adapter2 not reporting correct conditions and status
- HYPERFLEET-672: Adapter Helm chart: RabbitMQ exchange_type missing from broker config
- HYPERFLEET-682: [Bug] Adapter1 and Adapter2 not reporting correct conditions and status
- HYPERFLEET-672: [Story] Adapter Helm chart: RabbitMQ exchange_type missing from broker config
Comment on lines +133 to +134
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 | 🟠 Major

Example output conflicts with the declared [[TYPE]] format

Line 119-120 defines No Parent Epic entries as [[TYPE]] [Issue Summary], but Line 133-134 show [Bug] / [Story]. Keep the example aligned with the template, or the command contract is ambiguous.

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

In `@hyperfleet-jira/commands/team-weekly-update.md` around lines 133 - 134, The
example output conflicts with the declared template token `[[TYPE]] [Issue
Summary]`: update the example entries (currently showing `[Bug]` and `[Story]`)
to use the template token format (e.g., replace `- HYPERFLEET-682: [Bug]
Adapter1...` and `- HYPERFLEET-672: [Story]...` with `- HYPERFLEET-682: [[TYPE]]
Adapter1 and Adapter2 not reporting correct conditions and status` and `-
HYPERFLEET-672: [[TYPE]] Adapter Helm chart: RabbitMQ exchange_type missing from
broker config`) so the sample output matches the declared `[[TYPE]] [Issue
Summary]` contract.