Wicket
  1. Wicket
  2. WICKET-5215

Better exception message when Page instantiation fails in DefaultPageFactory

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 6.8.0
    • Fix Version/s: 6.9.0, 7.0.0-M1
    • Component/s: wicket
    • Labels:
      None

      Description

      If injecting dependencies to a page fails in DefaultPageFactory.newPage, the exception message is a bit misleading:

      "Can't instantiate page using constructor '...' and argument '...'. Might be it doesn't exist, may be it is not visible (public)."

      It could also mention the possibility of failing to inject the dependencies, which seems to be the case in many occasions.

      Even better, when calling the constructor fails, it could check the existence and visibility of the constructor instead of guessing what was the problem.

        Activity

        Edvard Fonsell created issue -
        Martin Grigorov made changes -
        Field Original Value New Value
        Assignee Martin Grigorov [ mgrigorov ]
        Martin Grigorov made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 6.9.0 [ 12324357 ]
        Fix Version/s 7.0.0 [ 12322958 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Martin Grigorov
            Reporter:
            Edvard Fonsell
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development