groovy / gmaven

Groovy integration for Maven
http://groovy.github.io/gmaven/
Apache License 2.0
51 stars 21 forks source link

NullPointerException for org.codehaus.gmaven:groovy-maven-plugin:2.1 #32

Closed BraveLittleTapok closed 1 year ago

BraveLittleTapok commented 1 year ago

Hello everyone! I have an issue with library I think, it happens after I try to do mvn package. I already tried to delete everything from .m2 folder, Invalidate caches in Idea and install everything again

That's an error: [ERROR] Failed to execute goal org.codehaus.gmaven:groovy-maven-plugin:2.1:execute (default) on project RacetracMobileTFA: Execution default of goal org.codehaus.gmaven:groovy-maven-plugin:2.1:execute failed.: NullPointerException -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException

And that's pom file:

            <plugin>
                <groupId>org.codehaus.gmaven</groupId>
                <artifactId>groovy-maven-plugin</artifactId>
                <version>2.1</version>
                <dependencies>
                    <dependency>
                        <groupId>org.yaml</groupId>
                        <artifactId>snakeyaml</artifactId>
                        <version>1.23</version>
                    </dependency>
                </dependencies>
                <executions>
                    <execution>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>execute</goal>
                        </goals>
                        <configuration>
                            <defaults>
                                <config>global</config>
                            </defaults>
                            <source>
                                ${project.basedir}/src/main/resources/script/PropertyFileGenerator.groovy
                            </source>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

Any ideas? :(

jdillon commented 1 year ago

Can you paste the stack trace with --errors enabled?

BraveLittleTapok commented 1 year ago

I found the issue: problem was in my properties.yaml there were lines like:

ua:
UA: <some code>

after deleting first string , problem was gone