Skip to content

fix: limit self-hosted member roles - #3202

Open
breken-ai wants to merge 1 commit into
appwrite:mainfrom
breken-ai:fix/self-hosted-member-role-options
Open

breken-ai wants to merge 1 commit into
appwrite:mainfrom
breken-ai:fix/self-hosted-member-role-options

Conversation

@breken-ai

Copy link
Copy Markdown

The reporter traced self-hosted member edits offering cloud-only roles that have no matching backend project permissions. Limit the edit-role selector to owner and developer on self-hosted instances while preserving the full role list in cloud.

The invitation flow already applies this product boundary; this keeps edits consistent without changing backend permissions or cloud behavior.

Fixes appwrite/appwrite#13730

Verification: git diff --check passes. Bun is unavailable in this environment, so Svelte checks and tests were not run locally.

Built by breken, your AI support engineer - breken.ai - this one's on us.

@appwrite

appwrite Bot commented Sep 16, 2026

Copy link
Copy Markdown

Console (appwrite/console)

Project ID: 688b7bf400350cbd60e9

Sites (1)
Site Status Logs Preview QR
 console-stage
688b7cf6003b1842c9dc
Queued Queued Authorize Preview URL QR Code

Tip

Sites support three domain rule types: Active deployment, Git branch, and Redirect

@greptile-apps

greptile-apps Bot commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

This PR should not merge as the intended self-hosted behavior remains unreachable.

Fix All in Claude CodeFindings

  1. P1 Restriction Is Unreachable
Fix with agent prompt
### Issue 1
src/routes/(console)/organization-[organization]/members/edit.svelte:37
The restricted list is used only inside this edit modal, but the modal's only opening action requires organization-role or project-role support, and both flags require cloud mode. Self-hosted users therefore cannot reach this selector, so this change does not deliver the intended self-hosted behavior.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Summary

This PR defines an owner/developer-only role list and selects it for self-hosted member editing. However, the existing members page hides the edit action on self-hosted installations, leaving the new restriction unreachable.

  • Adds a reusable selfHostedRoles role subset.
  • Uses that subset in the member edit selector.
  • Does not make the self-hosted edit flow reachable.

Reviews (1) · Last reviewed commit: "fix: limit self-hosted member roles"


const supportsProjectRoles = $derived(isCloud && !!$currentPlan?.supportsProjectSpecificRoles);
const defaultRole = isSelfHosted ? 'owner' : 'developer';
const availableRoles = isSelfHosted ? selfHostedRoles : roles;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Restriction Is Unreachable

The restricted list is used only inside this edit modal, but the modal's only opening action requires organization-role or project-role support, and both flags require cloud mode. Self-hosted users therefore cannot reach this selector, so this change does not deliver the intended self-hosted behavior.

Prompt To Fix With AI
This is a comment left during a code review.
Path: src/routes/(console)/organization-[organization]/members/edit.svelte
Line: 37

Comment:
**Restriction Is Unreachable**

The restricted list is used only inside this edit modal, but the modal's only opening action requires organization-role or project-role support, and both flags require cloud mode. Self-hosted users therefore cannot reach this selector, so this change does not deliver the intended self-hosted behavior.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Console roles analyst/editor/billing remove all project access on self-hosted (no backend equivalent)

1 participant