Grails
  1. Grails
  2. GRAILS-8379

Changes to statically defined where queries lead to a NoClassDefFoundError

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.0-RC2
    • Fix Version/s: None
    • Component/s: Spring Loaded
    • Labels:
      None

      Description

      Steps to reproduce

      1. Interactive mode.
      2. run-app (with that broken static query)
      3. Modify Book.groovy to:

      package resources.test
      
      class Book {
      
          String title
          Date releaseDate
          
          static where = {
              title == 'The Stand '
          }
          
          static constraints = {
              title blank:false
          }
      }
      
      

      4. exit
      5. run-app

      You'll see a NoClassDefFoundError

        Activity

        Hide
        Aaron Long added a comment -

        Seems like the only workaround is to do a "grails clean" for us. This happens anytime we change a static where query in a domain object, regardless of whether we are using interactive mode.

        Show
        Aaron Long added a comment - Seems like the only workaround is to do a "grails clean" for us. This happens anytime we change a static where query in a domain object, regardless of whether we are using interactive mode.

          People

          • Assignee:
            Andy Clement
            Reporter:
            Graeme Rocher
          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Last Reviewed:

              Development