Uploaded image for project: 'Crucible'
  1. Crucible
  2. CRUC-7717

Can't search for allowed group in Review Details when "Allowed Review Participants" are specified.

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Low Low
    • 4.1.0
    • 3.10.0
    • None
    • None

      Let's assume that you have following Crucible project settings:
      Allowed reviewers:

      • users: allowed_user
      • groups: allowed_grup (with user: user_of_allowed_group)

      When you use search box to add a reviewer, you want to see specific result items for the phrase: "allowed"

      • you expect to see the result: allowed_user, allowed_group, user_of_allowed_group
      • you can see items for any user from allowed user list (here: allowed_user)
      • you can see items for any user being a member of allowed groups (here: user_of_allowed_group)
      • but you can't see an item for a group itself (here: allowed_group), so there is not option to click for the group item and add all members

      The source of this problem is in the broken logic inside ReviewerFinderAjaxAction#getAllowedActiveReviewers, which provides final data populated to the ajax response.

       List<ReviewerData> allowed = new ArrayList<>();
       if (getReview() != null) {
          // first we try to collect all allowed users and all members of allowed groups
          // note that getAllowedRevierwers() returns flattened list of allowed users and members of allowed groups
          allowed.addAll(ImmutableList.copyOf(Iterables.transform(filter(getReview().getProject().getAllowedReviewers(), prefix, true), UserOrGroup.fromUserFunction)));
      }
      // so if there is no allowed user/group...
      if (allowed.isEmpty()) {
          // ... we perform global search and we allow users and groups to be returned
          allowed.addAll(getActiveUsersAndCurrentReviewers(prefix));
      }
      Collections.sort(allowed);
      return allowed;
      

      You can look at the rest of this class here: https://fisheye.dev.internal.atlassian.com/browse/FE-git/src/java/com/atlassian/crucible/actions/search/ajax/ReviewerFinderAjaxAction.java?r1=6ef375d16e137256ad58eaaa6d7d3de8a4b2bd10&r2=6ef375d16e137256ad58eaaa6d7d3de8a4b2bd10&u=20

            [CRUC-7717] Can't search for allowed group in Review Details when "Allowed Review Participants" are specified.

            Owen made changes -
            Workflow Original: FE-CRUC Bug Workflow [ 2941909 ] New: JAC Bug Workflow v3 [ 2955859 ]
            Owen made changes -
            Workflow Original: FECRU Development Workflow - Triage - Restricted [ 1511256 ] New: FE-CRUC Bug Workflow [ 2941909 ]
            Owen made changes -
            Workflow Original: FECRU Development Workflow - Triage [ 1386905 ] New: FECRU Development Workflow - Triage - Restricted [ 1511256 ]
            Adam Borowski (Inactive) made changes -
            Assignee New: Adam Borowski [ aborowski ]
            Adam Borowski (Inactive) made changes -
            Fix Version/s New: 4.1.0 [ 61350 ]
            Resolution New: Fixed [ 1 ]
            Status Original: Open [ 1 ] New: Closed [ 6 ]

            Solved by CRUC-7676.
            Ad the moment we allow to pick any group, even if is not configured as allowed for review. The reason is that user might intentionally pick that group because some of members might be allowed. This can occur, when such members belong to another, allowed group, or are specified as allowed reviewer explicite in the project configuration.

            Adam Borowski (Inactive) added a comment - Solved by CRUC-7676 . Ad the moment we allow to pick any group, even if is not configured as allowed for review. The reason is that user might intentionally pick that group because some of members might be allowed. This can occur, when such members belong to another, allowed group, or are specified as allowed reviewer explicite in the project configuration.
            Piotr Swiecicki made changes -
            Remote Link New: This issue links to "AAC: In Crucible, on Edit Details page, why can't I search for groups in the Reviewers: list? (Web Link)" [ 175933 ]
            Mikolaj Zyromski made changes -
            Status Original: Needs Triage [ 10030 ] New: Open [ 1 ]
            Adam Borowski (Inactive) made changes -
            Remote Link New: This issue links to "Page (Extranet)" [ 173365 ]
            Piotr Swiecicki made changes -
            Link New: This issue relates to CRUC-7676 [ CRUC-7676 ]

              aborowski Adam Borowski (Inactive)
              aborowski Adam Borowski (Inactive)
              Affected customers:
              1 This affects my team
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: