Which invitation a dual-role member receives is decided by pass order, not product intent
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 35/100
Hướng nghiên cứu
Bắt đầu với PR #2867 và luồng lời mời trong find_or_create_invitation. Đọc Admin::InvitationController, Event#verified_students và Event#verified_coaches để hiểu cách trạng thái role, verified và attending được giữ lại qua các lần chuyển role. Product trước tiên phải chọn lời mời nào sẽ được ưu tiên và liệu thay đổi role có đặt lại trạng thái hay không; hoàn thành nghĩa là hành vi đã chọn được triển khai và được bảo vệ bởi các specs hiện có.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Summary
PR #2867 made (event/workshop, member) the invitation identity, so a member subscribed as both student and coach now receives exactly one invitation and one email. Which email that is depends on the invitation pass order: Coach first for events, Student first for workshops. The order is an implementation detail, not a product decision.
The specs in PR #2867 pin the surviving role and email subject, so a pass reorder cannot flip this silently — but if product wants, for example, the coach email to always win, that is a separate change.
Decision needed
For a member with both roles, which invitation should win?
- Keep pass order (current behavior: Coach for events, Student for workshops)
- Coach email always wins
- Student email always wins
Related: cleanup of existing duplicate rows (see companion issue), where the same "which one survives" question applies to historical rows.
Related design call (from the PR #2867 review): verified/attending state across role flips
The role flip carries verified and attending state across roles. Admin::InvitationController sets verified: true per row, and Event#verified_students / Event#verified_coaches select by role + accepted + verified. Consequence: a verified Coach invitation flipped to Student (via the self-RSVP role-choice-wins path in find_or_create_invitation) counts in verified_students with no admin action, and the coach-side verified record is gone. Under the old two-row design, verification stayed per role.
If product picks option 1 above (pass order), this needs no action. If product picks option 2 or 3, the flip direction should also decide whether a role change resets verified (and possibly attending).
Flagged by the ce-code-review run on PR #2867 (adversarial + correctness reviewers, confirmed by validation).
- Ngôn ngữ chính
- Ruby
- Star
- 104
- Fork
- 205
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 67
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của codebar/planner
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
-
Clean up historical duplicate invitation rows (one member, two invitations per event/workshop) Đang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 25/100
-
good first issue performance
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 78/100
-
enhancement good first issue
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
Tất cả issue của codebar/planner
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
bug
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 90/100
riscv/riscv-unified-db#2626 ·
-
Component: GLib
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
ds-drift
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
we-promise/sure#3693 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
simp/pupmod-simp-simp#395 ·