java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode

Atlassian JIRA | Mark Chaimungkalanont | 1 decade ago
  1. 0

    Extending the *SearchRequestPortlet* for Kaamelot Portlet, I use *WorklogService.hasPermissionToCreate(JiraServiceContext jiraServiceContext, Issue issue)* . As *SearchRequestPortlet* provides through its *SearchProvider* a list of Issue based on class DocumentIssueImpl, the *hasPermissionToCreate()* fails with follow stacktrace. {code} 2007-07-11 11:28:24,944 http-8080-Processor24 ERROR [com.atlassian.velocity.DefaultVelocityManager] MethodInvocationException occurred getting message body from Velocity: java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode at com.atlassian.jira.issue.DocumentIssueImpl.getString(DocumentIssueImpl.java:306) at com.atlassian.jira.workflow.SimpleWorkflowManager.isEditable(SimpleWorkflowManager.java:482) at com.atlassian.jira.issue.managers.DefaultIssueManager.isEditable(DefaultIssueManager.java:348) at sun.reflect.GeneratedMethodAccessor149.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.atlassian.util.profiling.object.ObjectProfiler.profiledInvoke(ObjectProfiler.java:71) at com.atlassian.jira.config.component.SwitchingInvocationHandler.invoke(SwitchingInvocationHandler.java:28) at $Proxy3.isEditable(Unknown Source) at com.atlassian.jira.bc.issue.worklog.DefaultWorklogService.isIssueInEditableWorkflowState(DefaultWorklogService.java:514) at com.atlassian.jira.bc.issue.worklog.DefaultWorklogService.hasPermissionToCreate(DefaultWorklogService.java:342) {code} *DocumentIssueImpl* throws _*UnsupportedOperationException*_ on *getString()* call done by *SimpleWorkflowManager.isEditable(Issue issue)*. In *SimpleWorkflowManager.isEditable(Issue issue)*, the retrieve of StatusId .. {code:java}final String status = issue.getString("status");{code} should be done as follow : {code:java}final String status = issue.getStatusObject().getId();{code}

    Atlassian JIRA | 9 years ago | Vincent Thoulé
    java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode
  2. 0

    Extending the *SearchRequestPortlet* for Kaamelot Portlet, I use *WorklogService.hasPermissionToCreate(JiraServiceContext jiraServiceContext, Issue issue)* . As *SearchRequestPortlet* provides through its *SearchProvider* a list of Issue based on class DocumentIssueImpl, the *hasPermissionToCreate()* fails with follow stacktrace. {code} 2007-07-11 11:28:24,944 http-8080-Processor24 ERROR [com.atlassian.velocity.DefaultVelocityManager] MethodInvocationException occurred getting message body from Velocity: java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode at com.atlassian.jira.issue.DocumentIssueImpl.getString(DocumentIssueImpl.java:306) at com.atlassian.jira.workflow.SimpleWorkflowManager.isEditable(SimpleWorkflowManager.java:482) at com.atlassian.jira.issue.managers.DefaultIssueManager.isEditable(DefaultIssueManager.java:348) at sun.reflect.GeneratedMethodAccessor149.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.atlassian.util.profiling.object.ObjectProfiler.profiledInvoke(ObjectProfiler.java:71) at com.atlassian.jira.config.component.SwitchingInvocationHandler.invoke(SwitchingInvocationHandler.java:28) at $Proxy3.isEditable(Unknown Source) at com.atlassian.jira.bc.issue.worklog.DefaultWorklogService.isIssueInEditableWorkflowState(DefaultWorklogService.java:514) at com.atlassian.jira.bc.issue.worklog.DefaultWorklogService.hasPermissionToCreate(DefaultWorklogService.java:342) {code} *DocumentIssueImpl* throws _*UnsupportedOperationException*_ on *getString()* call done by *SimpleWorkflowManager.isEditable(Issue issue)*. In *SimpleWorkflowManager.isEditable(Issue issue)*, the retrieve of StatusId .. {code:java}final String status = issue.getString("status");{code} should be done as follow : {code:java}final String status = issue.getStatusObject().getId();{code}

    Atlassian JIRA | 9 years ago | Vincent Thoulé
    java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    atlassianlabs / automation / issues / #22 - UnsupportedOperationException from Analytics when using scheduled Event publisher — Bitbucket

    bitbucket.org | 1 year ago
    java.lang.UnsupportedOperationException: This code or velocity template expects a GenericValue, but received an Issue. We need to recode
  5. 0

    In the bundle <dependency> <groupId>org.apache.servicemix.bundles</groupId> <artifactId>org.apache.servicemix.bundles.fop</artifactId> <version>1.0_2</version> </dependency> It seems that there is a difference between the bundle and original fop jar(http://repo1.maven.org/maven2/org/apache/xmlgraphics/fop/1.0/fop-1.0.jar). It leaves out service configuration in the bundle under META-INF\services\. there are some excpetion when using it in karaf: 2012-12-13 16:22:41,596 | ERROR | qtp1553639268-32 | DefaultFOProcessor | 675 - fo-to-pdf-converter - 1.0.41001.20121213-1411-RELEASE | Transformation failed: Don't know how to handle "application/pdf" as an output format. Neither an FOEventHandler, nor a Renderer could be found fo r this output format. java.lang.UnsupportedOperationException: Don't know how to handle "application/pdf" as an output format. Neither an FOEventHandler, nor a Renderer c ould be found for this output format. at org.apache.fop.render.RendererFactory.createFOEventHandler(RendererFactory.java:361) at org.apache.fop.fo.FOTreeBuilder.<init>(FOTreeBuilder.java:105) at org.apache.fop.apps.Fop.createDefaultHandler(Fop.java:101) at org.apache.fop.apps.Fop.<init>(Fop.java:79) at org.apache.fop.apps.FopFactory.newFop(FopFactory.java:271)

    SpringSource Issue Tracker | 4 years ago | cliff.chen
    java.lang.UnsupportedOperationException: Don't know how to handle "application/pdf" as an output format. Neither an FOEventHandler, nor a Renderer c ould be found for this output format.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.UnsupportedOperationException

      This code or velocity template expects a GenericValue, but received an Issue. We need to recode

      at com.atlassian.jira.issue.DocumentIssueImpl.getString()
    2. com.atlassian.jira
      DocumentIssueImpl.getString
      1. com.atlassian.jira.issue.DocumentIssueImpl.getString(DocumentIssueImpl.java:236)
      1 frame
    3. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      4. java.lang.reflect.Method.invoke(Method.java:585)
      4 frames
    4. webwork.util
      ValueStack.test
      1. webwork.util.InjectionUtils$DefaultInjectionImpl.invoke(InjectionUtils.java:61)
      2. webwork.util.InjectionUtils.invoke(InjectionUtils.java:52)
      3. webwork.util.ValueStack.findValue(ValueStack.java:426)
      4. webwork.util.SimpleTest.test(SimpleTest.java:391)
      5. webwork.util.ValueStack.test(ValueStack.java:129)
      5 frames
    5. webwork.view.taglib
      ElseIfTag.doStartTag
      1. webwork.view.taglib.ElseIfTag.doStartTag(ElseIfTag.java:42)
      1 frame
    6. org.apache.jsp
      issuepicker_jsp._jspService
      1. org.apache.jsp.secure.popups.issuepicker_jsp._jspService(org.apache.jsp.secure.popups.issuepicker_jsp:1494)
      1 frame