alxjrvs / alxjrvs/orrey

Google return path: events.watch, renewal, nightly reconcile, echo-loop prevention

Ouverte
#48 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
phase:7
Langage dominant
HTML
Étoiles
0
Forks
0
Merge moyen
1 h 34 min
PR mergées (30 j)
23

Description

The only loopable edge. Orrey is a reconciler: changes made directly on the Orrey calendar (a GM dragging a session) flow back to D1, and D1 remains the source of truth.

- [ ] `events.watch` on the Orrey calendar with a webhook route on the Worker. The push carries **no body**; it is a signal to list changes with `syncToken`. Because `syncToken` is incompatible with `timeMin`/`q`/`privateExtendedProperty`, list the whole calendar — that is why Orrey has its own.
- [ ] Daily cron (`0 4 * * *`): renew watch channels (7-day TTL, no auto-renew). Track channel id / expiry in `settings`.
- [ ] Nightly cron (`30 5 * * *`): full reconcile — list all events, compare fingerprints against `calendar_links`, because `events.watch` is not 100% reliable.
- [ ] **Echo-loop prevention:** an inbound change whose content fingerprint matches what Orrey last wrote is ignored. A real change updates the session, posts a reschedule notice in the thread, re-projects Discord (new event if lapsed) — and re-fingerprints so the resulting Google update is recognised as our own.
- [ ] Deleted-in-Google → mark the session's calendar link as missing and re-insert (D1 wins); never cancel a session from Google.
- [ ] Google attendee `responseStatus` doesn't RSVP for anyone — never read it as intent.

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

Start from the Worker webhook route and scheduled cron entry points, then find where settings, calendar_links, sessions, Discord projection, and Google calendar writes are handled. Done means events.watch is renewed daily, nightly full reconcile runs, inbound Google changes update or restore D1-owned sessions, and echo-loop/RSVP rules are enforced.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
google-cloud
Domaine
api, backend, cloud
Type d'issue
Fonctionnalité
Difficulté
5/5
Temps estimé
Plus d'une semaine
Activité
Active
Clarté
Plutôt claire
Accessibilité débutants
28/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.