[ http://jira.codehaus.org/browse/MNG-3701?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brett Porter updated MNG-3701: ------------------------------ Fix Version/s: 2.0.10 > ClassCastException when building settings.xml with profiles that have > activeByDefault set > ----------------------------------------------------------------------------------------- > > Key: MNG-3701 > URL: http://jira.codehaus.org/browse/MNG-3701 > Project: Maven 2 > Issue Type: Bug > Components: Settings > Affects Versions: 2.0.10 > Reporter: John Casey > Priority: Blocker > Fix For: 2.0.10 > > > from Paul Benedict: > {noformat} > I tried RC5 and got this weird error. > > >c:\dev\apache-maven-2.0.10-RC5\bin\mvn.bat site:deploy > --------------------------------------------------- > constituent[0]: > file:/c:/Dev/apache-maven-2.0.10-RC5/bin/../lib/maven-2.0.10-RC5-uber.jar > --------------------------------------------------- > java.lang.ClassCastException: Settings.addActiveProfiles(string) > parameter must be instanceof java.lang.String > at > org.apache.maven.settings.Settings.addActiveProfile(Settings.java:112) > at > org.apache.maven.settings.DefaultMavenSettingsBuilder.activateDefaultProfiles(DefaultMavenSettingsBuilder.jav > a:198) > at > org.apache.maven.settings.DefaultMavenSettingsBuilder.buildSettings(DefaultMavenSettingsBuilder.java:178) > at > org.apache.maven.settings.DefaultMavenSettingsBuilder.buildSettings(DefaultMavenSettingsBuilder.java:154) > at > org.apache.maven.settings.DefaultMavenSettingsBuilder.buildSettings(DefaultMavenSettingsBuilder.java:142) > at org.apache.maven.cli.MavenCli.buildSettings(MavenCli.java:345) > at org.apache.maven.cli.MavenCli.main(MavenCli.java:201) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > at java.lang.reflect.Method.invoke(Method.java:597) > at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) > at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) > at > org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) > at org.codehaus.classworlds.Launcher.main(Launcher.java:375) > {noformat} > Then, in a later message: > {noformat} > When I reinstalled 2.0.10-RC5, it ran fine. Then I realized my > reinstall didn't include my custom settings.xml, but once I put that > back into /conf, everything went bonkers again. So that's where the > problem is. > You can reproduce the problem by doing the following: > - Edit the original settings.xml that comes with Maven > - Within <profiles>, add this: > <profile> > <activation> > <activeByDefault>true</activeByDefault> > </activation> > </profile> > The exception from my previous email should then be given: > java.lang.ClassCastException: Settings.addActiveProfiles(string) > parameter must be instanceof java.lang.String > {noformat} -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira