nextcloud / nextcloud/circles

Show more descriptive error message when failing to create team with few letters

Open
#2,567 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

0. Needs triage enhancement
Dominant language
JavaScript
Stars
177
Forks
68
Avg merge
2d 22h
Merged PRs (30d)
60

Description

How to use GitHub
  • Please use the 👍 reaction to show that you are interested into the same feature.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Feature request

Which Nextcloud Version are you currently using: Nextcloud 35.0.0 dev

Is your feature request related to a problem? Please describe.
Yes. Currently, when attempting to create a team using a name with few letters (e.g. "ab"), the frontend only returns generics error messages, like below:
Image
Inspecting the network tab, the actual error can be seen:

// POST ocs/v2.php/apps/circles/circles
{
    "ocs": {
        "meta": {
            "status": "failure",
            "statuscode": 400,
            "message": "Circle name is too short"
        },
        "data": []
    }
}

Describe the solution you'd like

Would be nice to return a more descriptive message to the user on frontend, so he knows what exactly is going on and what has to be changed.

Additional context
lib/Controller/LocalController::create() is the method reached by POST ocs/v2.php/apps/circles/circles endpoint.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at lib/Controller/LocalController::create(), which handles POST ocs/v2.php/apps/circles/circles, and trace how the frontend displays its response. Reproduce team creation with a name such as "ab" and compare the generic frontend message with the returned "Circle name is too short" error. Done means the frontend tells the user what must be changed.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
api, frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.