makeplane/plane · error · CommandError
Error: User with {email} does not exist
Error message
Error: User with {email} does not exist What it means
Raised by `reactivate_workspace_member` when `User.objects.filter(email=email).first()` returns None (lines 38-42). The email (already lowercased and stripped) matches no `User` row. This command normalizes the email to lower case before lookup, so casing is handled correctly here — a miss means the user genuinely does not exist. Clean non-zero CommandError.
Source
Thrown at apps/api/plane/db/management/commands/reactivate_workspace_member.py:42
# normalize before validating; emails are stored lowercased and stripped (User.save)
slug = slug.strip()
email = email.strip().lower()
# raise error if slug is not present
if not slug:
raise CommandError("Error: Workspace slug is required")
# raise error if email is not present
if not email:
raise CommandError("Error: Email is required")
# filter the user
user = User.objects.filter(email=email).first()
# Raise error if the user is not present
if not user:
raise CommandError(f"Error: User with {email} does not exist")
# filter the workspace
workspace = Workspace.objects.filter(slug=slug).first()
# Raise error if the workspace is not present
if not workspace:
raise CommandError(f"Error: Workspace with slug {slug} does not exist")
# Find the workspace membership (includes inactive members; soft-deleted are excluded by default manager)
workspace_member = WorkspaceMember.objects.filter(workspace=workspace, member=user).first()
# Raise error if the membership is not present
if not workspace_member:
raise CommandError(f"Error: User {email} is not a member of workspace {slug}")
# If already active, report without erroring
if workspace_member.is_active:
self.stdout.write(self.style.SUCCESS(f"User {email} is already an active member of workspace {slug}"))View on GitHub (pinned to 1c8a60f858)
Solutions
- Verify the user: `python manage.py shell -c "from plane.db.models import User; print(User.objects.filter(email='user@example.com').exists())"`
- Use the exact email (the command lowercases it, so case is not the issue here).
- Have the user register/sign in first if no record exists.
Example fix
# before python manage.py reactivate_workspace_member my-ws nonexistent@example.com # after python manage.py reactivate_workspace_member my-ws user@example.com
Defensive patterns
Strategy: validation
Validate before calling
python manage.py shell -c "from plane.db.models import User; import sys; sys.exit(0 if User.objects.filter(email='user@example.com').exists() else 1)"
Type guard
def user_exists(email: str) -> bool:
from plane.db.models import User
return User.objects.filter(email=email.strip().lower()).exists() Try / catch
try:
call_command('reactivate_workspace_member', slug, email)
except CommandError as e:
if 'does not exist' in str(e):
# user not found — register/sign-in first
... Prevention
- Confirm the user has signed in once.
- The command lowercases the email; ensure the user truly exists.
- Pre-check existence before invoking.
When it happens
Trigger: Running `reactivate_workspace_member <slug> nobody@example.com` where no user has that email.
Common situations: User never signed up; deactivated-and-deleted user; wrong domain; typo.
Related errors
- User with the provided email does not exist.
- User not found
- User email is required and should have signed in plane
- Please provide the email of the admin.
- Project ID is required
AI-assisted analysis of makeplane/plane@1c8a60f858 (2026-08-12).
Data as JSON: /api/errors/7ced880e3b897db8.
Report an issue: GitHub.