https://issues.apache.org/jira/browse/WICKET-6796

On Mon, Jun 1, 2020 at 4:08 PM Sven Meier <[email protected]> wrote:

> +1 that should have no negative impact
>
> Sven
>
> On 01.06.20 11:22, Martin Grigorov wrote:
> > Hi,
> >
> > I like the idea to catch UnsupportedOperationException at
> > org.apache.wicket.IGenericComponent#setModelObject(T) and re-throw it as:
> > throw new WicketRuntimeException("You need to use read/write Model for
> > component '{}", this.getPageRelativePath(), uox)
> >
> > Does anyone see a drawback ?
> >
> > Martin
> >
> > On Sat, May 30, 2020 at 11:42 PM Sven Meier <[email protected]> wrote:
> >
> >> Hi,
> >>
> >> just put a breakpoint on IModel#setObject().
> >>
> >> Once your problem hits that breakpoint, you'll be able to derive the
> >> offending component/model from the stacktrace/variables in your favorite
> >> IDE.
> >>
> >> Have fun
> >> Sven
> >>
> >>
> >> On 30.05.20 17:13, smallufo wrote:
> >>> Is it possible to try { setObjectObject(value) } catch { e }
> >>> and pinpoint which class/model causes this problem ?
> >>> Or is it too costly ?
> >>>
> >>>
> >>> Francois Meillet <[email protected]> 於 2020年5月30日 週六
> 下午11:02寫道:
> >>>
> >>>> Hope that help
> >>>>
> >>>> During the process of throwing an exception, the Java Virtual Machine
> >>>> abruptly completes, one by one, any expressions, statements, method
> and
> >>>> constructor invocations, initializers, and field initialization
> >> expressions
> >>>> that have begun but not completed execution in the current thread.
> This
> >>>> process continues until a handler is found that indicates that it
> >> handles
> >>>> that particular exception by naming the class of the exception or a
> >>>> superclass of the class of the exception (§11.2 <
> >>>>
> https://docs.oracle.com/javase/specs/jls/se11/html/jls-11.html#jls-11.2
> >>> ).
> >>>> If no such handler is found, then the exception may be handled by one
> >> of a
> >>>> hierarchy of uncaught exception handlers (§11.3 <
> >>>>
> https://docs.oracle.com/javase/specs/jls/se11/html/jls-11.html#jls-11.3
> >>> )
> >>>> - thus every effort is made to avoid letting an exception go
> unhandled.
> >>>>
> >>>> https://docs.oracle.com/javase/specs/jls/se11/html/jls-11.html <
> >>>> https://docs.oracle.com/javase/specs/jls/se11/html/jls-11.html>
> >>>>
> >>>>
> >>>> François
> >>>>
> >>>>
> >>>>
> >>>>> Le 30 mai 2020 à 16:52, smallufo <[email protected]> a écrit :
> >>>>>
> >>>>> Francois Meillet <[email protected]> 於 2020年5月30日 週六
> >> 下午10:48寫道:
> >>>>>> sompage?67-1.-border-content-border_body-form is the path to your
> >> model
> >>>>> Yes , but it may contains deep-nested model
> >>>>>
> >>>>> The form contains FormComponentPanel and contains another
> >>>>> FormComponentPanels and widgets , very deep ...
> >>>>> The error may lay under very deep model , which is very hard to
> debug.
> >>>>> And the error message should be able to pinpoint which model causes
> the
> >>>>> problem
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [email protected]
> >> For additional commands, e-mail: [email protected]
> >>
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to