Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-42909

Assignments - can't remove or edit All Purpose items

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: CLOSED
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 19.4, 20.0, 21.0 [Tentative]
    • Fix Version/s: 19.4, 20.0, 21.0 [Tentative]
    • Component/s: Assignments
    • Labels:
      None
    • 20 status:
      Verified
    • 19 status:
      Verified
    • Test Plan:
      Hide
      1. Create an assignment and add an All Purpose item.
      2. Edit the assignment and try to edit the access for the All Purpose item, adding users and removing others.
      3. Edit the assignment and try to remove the All Purpose item.
      Show
      Create an assignment and add an All Purpose item. Edit the assignment and try to edit the access for the All Purpose item, adding users and removing others. Edit the assignment and try to remove the All Purpose item.

      Description

      When trying to remove or edit the All Purpose option associated with an assignment, this error is thrown:

      18-Dec-2019 02:53:19.314 WARN [http-nio-20013-exec-49] org.sakaiproject.cheftool.VelocityPortletPaneledAction.actionDispatch Exception calling method doAssignment_form java.lang.reflect.InvocationTargetException (Caused by java.lang.IllegalArgumentException: Removing a detached instance org.sakaiproject.assignment.api.model.AssignmentAllPurposeItemAccess#1)
      java.lang.reflect.InvocationTargetException
      ...
      Caused by: java.lang.IllegalArgumentException: Removing a detached instance org.sakaiproject.assignment.api.model.AssignmentAllPurposeItemAccess#1
      	at org.hibernate.jpa.event.internal.core.JpaDeleteEventListener.performDetachedEntityDeletionCheck(JpaDeleteEventListener.java:69)
      	at org.hibernate.event.internal.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:106)
      	at org.hibernate.event.internal.DefaultDeleteEventListener.onDelete(DefaultDeleteEventListener.java:73)
      	at org.hibernate.internal.SessionImpl.fireDelete(SessionImpl.java:956)
      	at org.hibernate.internal.SessionImpl.delete(SessionImpl.java:896)
      	at org.springframework.orm.hibernate4.HibernateTemplate$24.doInHibernate(HibernateTemplate.java:794)
      	at org.springframework.orm.hibernate4.HibernateTemplate.doExecute(HibernateTemplate.java:341)
      	at org.springframework.orm.hibernate4.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:309)
      	at org.springframework.orm.hibernate4.HibernateTemplate.delete(HibernateTemplate.java:787)
      	at org.springframework.orm.hibernate4.HibernateTemplate.delete(HibernateTemplate.java:782)
      	at org.sakaiproject.assignment.impl.AssignmentSupplementItemServiceImpl.removeAllPurposeItemAccess(AssignmentSupplementItemServiceImpl.java:411)
      	at org.sakaiproject.assignment.impl.AssignmentSupplementItemServiceImpl.cleanAllPurposeItemAccess(AssignmentSupplementItemServiceImpl.java:359)
      

      Same thing happens when trying to remove or edit the users with access to an All Purpose item.

        Gliffy Diagrams

          Zeplin

            Attachments

              Issue Links

                Activity

                  People

                  Assignee:
                  bergarvi Bernardo Garcia Vila
                  Reporter:
                  bergarvi Bernardo Garcia Vila
                  Votes:
                  0 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                    Dates

                    Created:
                    Updated:
                    Resolved:

                      Git Integration