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

Error when try adding a student on a blocked section/group

    XMLWordPrintable

    Details

    • 21 Status:
      Resolved
    • 20 status:
      Verified
    • Test Plan:
      Hide

      1. Go to section info tool
      2. Add a new section
      3. Add a student on the new section
      4. Go to assignments
      5. Fill title, instructions
      6. The selected group(s), as a group assignment (one group member submits on behalf of the entire group)
      7. Select the new section and click Post
      8. Go to section info tool
      9. Click Student Memberships
      10. Click a new student
      11. Click Assign to the new section

       

      Show
      1. Go to section info tool 2. Add a new section 3. Add a student on the new section 4. Go to assignments 5. Fill title, instructions 6. The selected group(s), as a group assignment (one group member submits on behalf of the entire group) 7. Select the new section and click Post 8. Go to section info tool 9. Click Student Memberships 10. Click a new student 11. Click Assign to the new section  

      Description

      See testing plan and attached image

      Different behaviours on each Sakai. Worst behaviour on 20.x

      Error on log

      20.x - ERROR and on log is shown.
      22-Oct-2020 09:02:33.847 WARN [http-nio-20020-exec-18] org.sakaiproject.portal.util.ErrorReporter.logAndMail Bug Report bug-id: c8aa045e-56f2-4dfe-bcbc-5dbaf23ef685 user: 2885dc62-1299-4088-a07d-d7d2138d2c7d usage-session: 97c2d9f5-f86c-409b-9fde-befc62910541 time: Oct 22, 2020 9:02:33 AM EDT user comment: null stack trace
      org.sakaiproject.portal.api.PortalHandlerException: java.lang.NullPointerException
          at org.sakaiproject.portal.charon.handlers.WorksiteHandler.doPost(WorksiteHandler.java:69)
      caused by: java.lang.NullPointerException
          at javax.faces.webapp._ErrorPageWriter.writeVariables(_ErrorPageWriter.java:325)
          at javax.faces.webapp._ErrorPageWriter.writeVariables(_ErrorPageWriter.java:302)
          at javax.faces.webapp._ErrorPageWriter.debugHtml(_ErrorPageWriter.java:183)
          at javax.faces.webapp._ErrorPageWriter.handleThrowable(_ErrorPageWriter.java:483)
          at javax.faces.webapp._ErrorPageWriter.handleException(_ErrorPageWriter.java:468)
          at javax.faces.webapp.FacesServlet.handleLifecycleException(FacesServlet.java:254)
          at javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.sakaiproject.util.RequestFilter.doFilter(RequestFilter.java:426)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.sakaiproject.tool.section.filter.RoleFilter.doFilter(RoleFilter.java:126)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712)
          at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:459)
          at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:384)
          at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312)
          at org.sakaiproject.jsf.util.JsfTool.dispatch(JsfTool.java:223)
          at org.sakaiproject.jsf.util.JsfTool.doPost(JsfTool.java:258)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:652)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:733)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712)
          at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:459)
          at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:352)
          at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312)
          at org.sakaiproject.tool.impl.ActiveToolComponent$MyActiveTool.forward(ActiveToolComponent.java:508)
          at org.sakaiproject.portal.charon.SkinnableCharonPortal.forwardTool(SkinnableCharonPortal.java:1500)
          at org.sakaiproject.portal.charon.handlers.SiteHandler.doToolBuffer(SiteHandler.java:1254)
          at org.sakaiproject.portal.charon.handlers.SiteHandler.bufferContent(SiteHandler.java:1088)
          at org.sakaiproject.portal.charon.handlers.SiteHandler.doSite(SiteHandler.java:499)
          at org.sakaiproject.portal.charon.handlers.SiteHandler.doGet(SiteHandler.java:275)
          at org.sakaiproject.portal.charon.handlers.SiteHandler.doGet(SiteHandler.java:163)
          at org.sakaiproject.portal.charon.handlers.WorksiteHandler.doPost(WorksiteHandler.java:69)
          at org.sakaiproject.portal.charon.SkinnableCharonPortal.doPost(SkinnableCharonPortal.java:1173)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:652)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:733)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.sakaiproject.util.RequestFilter.doFilter(RequestFilter.java:475)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:202)
          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
          at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:541)
          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
          at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:747)
          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
          at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:373)
          at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
          at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:868)
          at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1589)
          at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
          at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
          at java.lang.Thread.run(Thread.java:748)

       

      Ideal behaviour should be like 12.x or 19.x

      12.x - Error on log and section tool IS NOT restarted. Stay at Student Memberships
      22-Oct-2020 09:00:46.211 ERROR [http-apr-20012-exec-75] org.sakaiproject.component.section.sakai.SectionManagerImpl.addStudentToSection .addStudentToSection: User with id eb0c4d2d-2ab8-48dd-b25b-ba3edc84ecd8 cannot be inserted in group with id 4c837eb0-a8a2-4670-afc7-b4dcdb3b77f8 because the group is locked 
      19.x - Error on log and section tool IS NOT restarted. Stay at Student Memberships
      22-Oct-2020 09:06:37.603 ERROR [http-nio-20019-exec-65] org.sakaiproject.component.section.sakai.SectionManagerImpl.addStudentToSection .addStudentToSection: User with id 9b51bc22-229c-404e-9e81-23f025c76cc5 cannot be inserted in group with id 502fb7ef-559f-4d3f-9487-1444b6236915 because the group is locked
      22.x - Warn on log and section tool IS restarted. Main page of section pool.
      22-Oct-2020 09:15:08.954 WARN [http-nio-20113-exec-2] org.sakaiproject.portal.charon.handlers.SiteHandler.bufferContent Failed to buffer content.
      org.sakaiproject.tool.api.ToolException: javax.servlet.ServletException: /editStudentSections.jsp(156,16) '#{editStudentSectionsBean.processJoinSection}' java.lang.IllegalStateException: Can't add member 685255b6-49b2-4e14-86d1-296e720842b8 with role Student to a locked group
      	at org.sakaiproject.tool.impl.ActiveToolComponent$MyActiveTool.forward(ActiveToolComponent.java:520)
      	at org.sakaiproject.portal.charon.SkinnableCharonPortal.forwardTool(SkinnableCharonPortal.java:1502)
      	at org.sakaiproject.portal.charon.handlers.SiteHandler.doToolBuffer(SiteHandler.java:1254)
      	at org.sakaiproject.portal.charon.handlers.SiteHandler.bufferContent(SiteHandler.java:1088)
      	at org.sakaiproject.portal.charon.handlers.SiteHandler.doSite(SiteHandler.java:499)
      	at org.sakaiproject.portal.charon.handlers.SiteHandler.doGet(SiteHandler.java:275)
      	at org.sakaiproject.portal.charon.handlers.SiteHandler.doGet(SiteHandler.java:163)
      	at org.sakaiproject.portal.charon.handlers.WorksiteHandler.doPost(WorksiteHandler.java:69)
      	at org.sakaiproject.portal.charon.SkinnableCharonPortal.doPost(SkinnableCharonPortal.java:1175)
      	at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
      	at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.sakaiproject.util.RequestFilter.doFilter(RequestFilter.java:496)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:200)
      	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
      	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:490)
      	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:139)
      	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
      	at org.apache.catalina.valves.RemoteIpValve.invoke(RemoteIpValve.java:679)
      	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:74)
      	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
      	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:408)
      	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
      	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:836)
      	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1747)
      	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      	at java.lang.Thread.run(Thread.java:748)
      Caused by: javax.servlet.ServletException: /editStudentSections.jsp(156,16) '#{editStudentSectionsBean.processJoinSection}' java.lang.IllegalStateException: Can't add member 685255b6-49b2-4e14-86d1-296e720842b8 with role Student to a locked group
      	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:683)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.sakaiproject.util.RequestFilter.doFilter(RequestFilter.java:447)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.sakaiproject.tool.section.filter.RoleFilter.doFilter(RoleFilter.java:126)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712)
      	at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:459)
      	at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:384)
      	at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312)
      	at org.sakaiproject.jsf2.util.JsfTool.dispatch(JsfTool.java:215)
      	at org.sakaiproject.jsf2.util.JsfTool.doPost(JsfTool.java:250)
      	at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
      	at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
      	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
      	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
      	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:712)
      	at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:459)
      	at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:352)
      	at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:312)
      	at org.sakaiproject.tool.impl.ActiveToolComponent$MyActiveTool.forward(ActiveToolComponent.java:508)
      	... 35 more
      Caused by: org.apache.jasper.el.JspELException: /editStudentSections.jsp(156,16) '#{editStudentSectionsBean.processJoinSection}' java.lang.IllegalStateException: Can't add member 685255b6-49b2-4e14-86d1-296e720842b8 with role Student to a locked group
      	at org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:85)
      	at javax.faces.event.MethodExpressionActionListener.processAction(MethodExpressionActionListener.java:148)
      	at javax.faces.event.ActionEvent.processListener(ActionEvent.java:96)
      	at javax.faces.component.UIComponentBase.broadcast(UIComponentBase.java:839)
      	at javax.faces.component.UICommand.broadcast(UICommand.java:315)
      	at javax.faces.component.UIData.broadcast(UIData.java:1158)
      	at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:870)
      	at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1418)
      	at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82)
      	at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)
      	at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:201)
      	at javax.faces.webapp.FacesServlet.service(FacesServlet.java:670)
      	... 61 more
      Caused by: java.lang.IllegalStateException: Can't add member 685255b6-49b2-4e14-86d1-296e720842b8 with role Student to a locked group
      	at org.sakaiproject.site.impl.BaseGroup.insertMember(BaseGroup.java:425)
      	at org.sakaiproject.component.section.sakai.SectionManagerImpl.addStudentToSection(SectionManagerImpl.java:953)
      	at org.sakaiproject.component.section.sakai.SectionManagerImpl.addSectionMembership(SectionManagerImpl.java:887)
      	at org.sakaiproject.tool.section.jsf.backingbean.EditStudentSectionsBean.processJoinSection(EditStudentSectionsBean.java:225)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:498)
      	at org.apache.el.parser.AstValue.invoke(AstValue.java:247)
      	at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:267)
      	at org.apache.jasper.el.JspMethodExpression.invoke(JspMethodExpression.java:74)
      	... 72 more 

       Can't be tested on 21.x because there isn't any category on Section Info tool

        Gliffy Diagrams

          Zeplin

            Attachments

              Issue Links

                Activity

                  People

                  Assignee:
                  jesusmmp Jesus Maria Mendez
                  Reporter:
                  jesusmmp Jesus Maria Mendez
                  Votes:
                  0 Vote for this issue
                  Watchers:
                  4 Start watching this issue

                    Dates

                    Created:
                    Updated:
                    Resolved:

                      Git Integration