🐛 Discordロール差分同期の管理外ロール削除バグを修正 #229
Open
Tivo0921 wants to merge 8 commits into
Open
Conversation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Deployed on https://dev-pr-229-birbz3fm6q-an.a.run.app |
8 tasks
4 tasks
|
Deployed on https://dev-pr-229-birbz3fm6q-an.a.run.app |
Shion1305
approved these changes
May 11, 2026
| # env files | ||
| .env* | ||
| !.env.example | ||
| env.share |
* ♻️ Discordロール同期を学年・学部のみに絞り込む - 付与対象を学年・学部ロールのみに変更(興味分野・メンバー種別は付与しない) - 既存の興味分野・種別ロールは管理対象として削除する - 同期結果の付与/削除カラムをロールIDではなく名前で表示 - ensureRolesInMap後に逆引きマップを構築し新規作成ロールも名前解決できるよう修正 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * ♻️ PR#235レビュー対応: Discordロール種別ごとの分岐と退会者ロールを実装 - 卒業生: 卒業生ロールのみ付与(年度・学部ロールなし) - その他: その他ロールのみ付与 - 退会者: opt-out確定時に退会者ロールを付与 - 再入会: 退会者ロールを削除し通常ロールを付与 - isProfileValueName に退会者を追加(管理対象に含める) - MemberRoleParams に memberType / optedOut を追加 - バルク同期でも種別ごとに正しいロールを ensureRolesInMap に渡すよう修正 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> --------- Co-authored-by: Shun Ikeda <shunikeda@ShunnoMacBook-Pro.local> Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> Co-authored-by: Shion Ichikawa <shion1305@gmail.com>
|
Deployed on https://dev-pr-229-birbz3fm6q-an.a.run.app |
.env*パターンで自動的に無視されるため、明示的なエントリが不要になる Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Deployed on https://dev-pr-229-birbz3fm6q-an.a.run.app |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
feature/discord-role-syncの差分同期実装で発生していた2つのバグを修正する。修正内容
1. 管理外ロールを誤って削除するバグ(
lib/discord-role.ts)問題:
managedRoleIdsをギルドの全ロールで構成していたため、ADMIN_ROLE_IDや Botロールなど、このシステムが管理しない役割も削除対象になっていた(403エラー)
修正: 以下の名前に一致するロールのみを管理対象と見なすよう変更
MEMBER_TYPES(学部生 / 院生 / 卒業生 / その他)FACULTIES(教育学部 / 経済学部 …)GRADUATE_SCHOOLS(理工学府 …)ALL_PRESET_TAGS(Python / React …)学部1年/修士2年など)2. Script コンポーネントの警告(
app/layout.tsx)問題: Next.js 16 で
<head>内の<Script strategy="beforeInteractive" dangerouslySetInnerHTML>が非推奨になりコンソール警告が出ていた修正: 素の
<script dangerouslySetInnerHTML>に置き換え.gitignoreへのenv.share追加env.shareが誤ってコミットされないよう.gitignoreに追記(あぶなかった)依存関係
このブランチは
feature/discord-role-syncをベースにしています。先にそちらをマージしてください。