Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-9194

Groovy fails when a script starts with a #

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    Description

      An exception occurs in Groovy if the groovy file contains the character #.

      This happens on linux systems where a script that starts with a # will result in an error:

      Exception in thread "main" java.lang.ClassFormatError: Illegal class name "" in class file 

      simply doing this:

      groovy /path/#myfile

      will produce this error.

      This is a regression caused by GROOVY-6641

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            paulk Paul King
            joseph.henry Joseph Henry
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment