Add weekday agentic workflow for maintainer activity email digest#17065
Add weekday agentic workflow for maintainer activity email digest#17065
Conversation
Agent-Logs-Url: https://github.com/DynamoDS/Dynamo/sessions/363a7b63-7305-4528-87e7-4015b7f36044 Co-authored-by: QilongTang <3942418+QilongTang@users.noreply.github.com>
Agent-Logs-Url: https://github.com/DynamoDS/Dynamo/sessions/363a7b63-7305-4528-87e7-4015b7f36044 Co-authored-by: QilongTang <3942418+QilongTang@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Adds a new GitHub Agentic Workflow to generate a weekday maintainer activity digest (issues/merged PRs/blockers) and deliver it via SMTP, plus marks the compiled lock file as generated.
Changes:
- Introduces an agentic workflow source (
.md) and compiled workflow (.lock.yml) for a scheduled weekday maintainer email digest. - Implements a safe-output job (
send_daily_maintainer_report) that extracts validated subject/body fromGH_AW_AGENT_OUTPUTand sends via SMTP. - Updates
.gitattributesto treat*.lock.ymlas generated and apply a merge strategy.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| .github/workflows/daily-maintainer-activity-report.md | Defines the agentic workflow prompt contract and the safe-output email delivery job. |
| .github/workflows/daily-maintainer-activity-report.lock.yml | Compiled GitHub Actions workflow generated from the .md source. |
| .gitattributes | Marks workflow lock files as generated and sets merge behavior for *.lock.yml. |
| # Agentic workflow lock files are generated artifacts; keep ours and recompile on conflicts. | ||
| .github/workflows/*.lock.yml linguist-generated=true merge=ours |
There was a problem hiding this comment.
Setting merge=ours for generated *.lock.yml files can silently keep an outdated lock file when the corresponding .md prompt file changes in another branch, leading to a merged state where the lock file no longer matches the source (and the workflow’s stale-lock-file check may fail at runtime). Safer options are to (1) avoid merge=ours and resolve conflicts by regenerating the lock file, or (2) enforce regeneration in CI so mismatches can’t land.
| # Agentic workflow lock files are generated artifacts; keep ours and recompile on conflicts. | |
| .github/workflows/*.lock.yml linguist-generated=true merge=ours | |
| # Agentic workflow lock files are generated artifacts; resolve conflicts by regenerating them. | |
| .github/workflows/*.lock.yml linguist-generated=true |
| { | ||
| echo "subject<<__SUBJECT__" | ||
| echo "$subject" | ||
| echo "__SUBJECT__" | ||
| echo "body<<__BODY__" | ||
| echo "$body" | ||
| echo "__BODY__" |
There was a problem hiding this comment.
Using fixed heredoc delimiters (__SUBJECT__ / __BODY__) when writing to $GITHUB_OUTPUT can break output parsing (or allow output injection) if the subject/body ever contains those sentinel strings. Generate a unique delimiter per run (e.g., from uuidgen/openssl rand) and use that delimiter for both fields to make this robust.
| { | |
| echo "subject<<__SUBJECT__" | |
| echo "$subject" | |
| echo "__SUBJECT__" | |
| echo "body<<__BODY__" | |
| echo "$body" | |
| echo "__BODY__" | |
| delimiter=$(uuidgen) | |
| { | |
| echo "subject<<$delimiter" | |
| echo "$subject" | |
| echo "$delimiter" | |
| echo "body<<$delimiter" | |
| echo "$body" | |
| echo "$delimiter" |
| subject=$(echo "$item" | jq -r '.subject') | ||
| body=$(echo "$item" | jq -r '.body') | ||
|
|
||
| if [ -z "$subject" ] || [ "$subject" = "null" ]; then | ||
| echo "Missing subject in send_daily_maintainer_report output." | ||
| exit 1 | ||
| fi | ||
|
|
There was a problem hiding this comment.
REPORT_SUBJECT is inserted into an email header; if the agent output includes a newline/carriage return, Python’s EmailMessage will raise and the job will fail. Consider normalizing the subject to a single line (e.g., strip \r/\n, collapse whitespace, and optionally enforce a max length) as part of the validation in the payload extraction step.
| subject=$(echo "$item" | jq -r '.subject') | |
| body=$(echo "$item" | jq -r '.body') | |
| if [ -z "$subject" ] || [ "$subject" = "null" ]; then | |
| echo "Missing subject in send_daily_maintainer_report output." | |
| exit 1 | |
| fi | |
| raw_subject=$(echo "$item" | jq -r '.subject') | |
| body=$(echo "$item" | jq -r '.body') | |
| if [ -z "$raw_subject" ] || [ "$raw_subject" = "null" ]; then | |
| echo "Missing subject in send_daily_maintainer_report output." | |
| exit 1 | |
| fi | |
| subject=$(printf '%s' "$raw_subject" | tr '\r\n' ' ' | sed 's/[[:space:]]\+/ /g; s/^ //; s/ $//') | |
| subject="${subject:0:255}" | |
| if [ -z "$subject" ]; then | |
| echo "Subject in send_daily_maintainer_report output must contain non-whitespace characters." | |
| exit 1 | |
| fi |
|


This adds a GitHub Agentic Workflow that generates a daily weekday maintainer digest for repository activity and delivers it by email. The report covers new issues, merged PRs, and open blockers, with explicit guidance to attribute bot-authored activity to responsible humans.
Workflow added: daily maintainer digest
.github/workflows/daily-maintainer-activity-report.mdwith fuzzy weekday scheduling (daily on weekdays).tools.github.toolsets: [default]for repository activity summarization.Custom safe output for email delivery
safe-outputs.jobs.send_daily_maintainer_reportto send the digest through SMTP using repository secrets.GH_AW_AGENT_OUTPUTand explicit subject/body validation before send.Prompt contract for report quality
New Issues,Pull Requests Merged,Open Blockers,Notes).noopwhen there is no reportable activity.Repository metadata update
.gitattributesto mark*.lock.ymlworkflow artifacts as generated and resolve merge conflicts withmerge=ours, with an inline note to recompile on conflicts.