No description
- Shell 100%
- scan: fetch GitHub notifications, classify (feedback vs mention) - check: dry-run analysis of a specific PR - process: open Gitea issue + reply on GitHub + email notification - review: trigger oca-reviewer on a PR - watch: daemon mode with configurable polling Safety: Gitea-first (won't reply on GitHub if issue creation fails) No hardcoded secrets — all config via .config/settings.env (gitignored) |
||
|---|---|---|
| .config | ||
| scripts | ||
| .gitignore | ||
| LICENSE | ||
| oca-feedback | ||
| README.md | ||
| seen_ids.txt | ||
OCA Feedback
GitHub mention monitor + feedback collector for OCA pull requests.
Never miss community feedback again.
What it does
GitHub Notification (mention of @you)
│
▼
Analyze context
Is it a reply to an oca-reviewer bot comment?
│
┌────┴────┐
▼ ▼
YES NO
Feedback New mention
on review on a PR
│ │
▼ ▼
Open issue Run oca-reviewer
on Gitea on that PR
+ reply + acknowledge
on GitHub on GitHub
Flow 1: Feedback collection
When someone replies to an oca-reviewer bot comment on a PR:
- Detects the reply via GitHub notifications API
- Opens an issue on Gitea with the feedback + action checklist
- Replies on GitHub thanking the user, linking the issue, and inviting them to contribute
- Sends email notification to the team
Flow 2: Auto-review on mention
When someone @mentions you on an OCA PR you haven't reviewed:
- Detects the mention via GitHub notifications API
- Acknowledges on GitHub ("I'll review this PR shortly")
- Triggers oca-reviewer for a full automated review
Install
git clone https://git.pop.coop/pop/oca-feedback.git
cd oca-feedback
cp .config/settings.env.example .config/settings.env
nano .config/settings.env # fill in your tokens
chmod +x oca-feedback scripts/*.sh
Prerequisites
- gh CLI authenticated (
gh auth login) - jq installed
- Gitea API token from your Gitea instance (Settings → Applications)
- oca-reviewer (optional, for full K8s test reviews)
Usage
# Show all commands
./oca-feedback help
# Scan GitHub notifications once
./oca-feedback scan
# Daemon mode (polls every 5 minutes)
./oca-feedback watch
# Background daemon
nohup ./oca-feedback watch > /tmp/oca-feedback/watch.log 2>&1 &
# Dry-run: see what would happen on a specific PR
./oca-feedback check https://github.com/OCA/bank-payment/pull/1547
# Execute for real: open Gitea issue + reply on GitHub
./oca-feedback process https://github.com/OCA/bank-payment/pull/1547
# Manually trigger oca-reviewer on a PR
./oca-feedback review https://github.com/OCA/bank-payment/pull/1547
# View history of processed notifications
./oca-feedback history
Configuration
Copy .config/settings.env.example to .config/settings.env and fill in your values.
⚠️ settings.env contains secrets and is gitignored. Never commit it.
| Variable | Description | Default |
|---|---|---|
GH_USER |
Your GitHub username | — |
GITEA_URL |
Gitea instance URL | https://git.pop.coop |
GITEA_TOKEN |
Gitea API token | (required) |
GITEA_REVIEWER_REPO |
Repo for feedback issues | pop/oca-reviewer |
OCA_REVIEWER_DIR |
Path to oca-reviewer | ~/Projects/oca-reviewer |
POLL_INTERVAL |
Seconds between scans | 300 |
BOT_SIGNATURE |
Pattern to detect bot comments | Automated Review |
SMTP_HOST |
Email server (optional) | — |
NOTIFY_EMAILS |
Who to notify (optional) | — |
How it integrates
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ GitHub │────▶│ oca-feedback │────▶│ oca-reviewer │
│ Notifications│ │ (classifier) │ │ (K8s + AI) │
└──────────────┘ └──────┬───────┘ └──────────────┘
│
┌──────┴───────┐
▼ ▼
┌──────────┐ ┌──────────────┐
│ Gitea │ │ GitHub PR │
│ (issues) │ │ (reply) │
└──────────┘ └──────────────┘
Project structure
oca-feedback/
├── oca-feedback # CLI entry point
├── scripts/
│ ├── scan.sh # Core: fetch notifications + classify + dispatch
│ ├── analyze-comment.sh # Deep-analyze a specific PR (check/process)
│ └── trigger-review.sh # Bridge to oca-reviewer
├── .config/
│ └── settings.env.example # Example config (copy to settings.env)
├── .gitignore
├── LICENSE
└── README.md
Safety
- Gitea-first: the bot will NOT reply on GitHub if the Gitea issue creation fails (so you never post a reply without a tracking link)
- Dry-run by default:
checkshows everything that would happen;processexecutes for real - Secrets stay local:
settings.envis gitignored; only.env.exampleis tracked
Contributing
Issues and PRs welcome at https://git.pop.coop/pop/oca-feedback
See also:
- oca-reviewer — automated PR review bot
- oca-migrator — AI-powered module migration
License
AGPL-3.0 — PopSolutions