Tapestry
  1. Tapestry
  2. TAPESTRY-2422

The Exception report will itself throw an exception if the exception being reported contains a write-only property

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 5.0.11
    • Fix Version/s: 5.0.13
    • Component/s: None
    • Labels:
      None

      Description

      when displayed exception contains at least one write-only property tapestry failing to render error page.
      java.lang.UnsupportedOperationException: Class ui.Exception_detail does not provide an accessor ('getter') method for property 'faultCode'
      at org.apache.tapestry.ioc.internal.services.PropertyAdapterImpl.get(PropertyAdapterImpl.java:81)
      at org.apache.tapestry.ioc.internal.services.ClassPropertyAdapterImpl.get(ClassPropertyAdapterImpl.java:81)
      at org.apache.tapestry.ioc.internal.services.ExceptionAnalyzerImpl.extractInfo(ExceptionAnalyzerImpl.java:105)
      at org.apache.tapestry.ioc.internal.services.ExceptionAnalyzerImpl.analyze(ExceptionAnalyzerImpl.java:50)

      it seems like error in extractInfo method, which does not analyze can it read property or not before invoking adapter.get(). So, it is simple to patch
      Instead of

      Object value = adapter.get(t, name);
      if (value == null) continue;

      Use

      PropertyAdapter pa = adapter.getPropertyAdapter(name);
      if (!pa.isRead()) continue;

      Object value = pa.get(t);
      if (value == null) continue;

        Activity

        Alexander Gavrilov created issue -
        Howard M. Lewis Ship made changes -
        Field Original Value New Value
        Fix Version/s 5.0.13 [ 12313205 ]
        Fix Version/s 5.0.12 [ 12313048 ]
        Howard M. Lewis Ship made changes -
        Priority Critical [ 2 ] Major [ 3 ]
        Summary java.lang.UnsupportedOperationException thrown when tapestry render error page for exception with at leas onw writable only property The Exception report will itself throw an exception if the exception being reported contains a write-only property
        Assignee Howard M. Lewis Ship [ hlship ]
        Howard M. Lewis Ship made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Closed [ 6 ]
        Mark Thomas made changes -
        Workflow jira [ 12431219 ] Default workflow, editable Closed status [ 12568098 ]
        Mark Thomas made changes -
        Workflow Default workflow, editable Closed status [ 12568098 ] jira [ 12591191 ]

          People

          • Assignee:
            Howard M. Lewis Ship
            Reporter:
            Alexander Gavrilov
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 5m
              5m
              Remaining:
              Remaining Estimate - 5m
              5m
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development