You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Ludovic Claude (JIRA)" <ji...@codehaus.org> on 2007/02/07 11:17:44 UTC
[jira] Commented: (SCM-278) NPE when running changelog
[ http://jira.codehaus.org/browse/SCM-278?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_86992 ]
Ludovic Claude commented on SCM-278:
------------------------------------
Adding the following lines to VssHistoryCommand.java takes care of this issue. It works well for me, builds are now executed when there are modifications in the VSS repository.
//Display only versions that fall within specified data range.
if ( startDate != null )
{
+ if (endDate == null)
+ {
+ endDate = new Date(); // = now
+ }
SimpleDateFormat sdf = new SimpleDateFormat( "dd/MM/yyyy", Locale.ENGLISH );
String dateRange = sdf.format( endDate ) + "~" + sdf.format( startDate );
command.createArgument().setValue( VssConstants.FLAG_VERSION_DATE + dateRange );
}
return command;
> NPE when running changelog
> --------------------------
>
> Key: SCM-278
> URL: http://jira.codehaus.org/browse/SCM-278
> Project: Maven SCM
> Issue Type: Bug
> Components: maven-scm-provider-vss
> Environment: SourceSafe 6.0d, Win XP
> Reporter: Ludovic Claude
>
> Hello,
> I have the following error when I try to update an existing project with Continuum. The first checkout of the project works fine, but when I modify some sources in VSS, I get this error. Forcing the build a second time works fine, so it's not a showstopper bug.
> org.apache.maven.continuum.scm.ContinuumScmException: Error while update sources.
> at org.apache.maven.continuum.scm.DefaultContinuumScm.updateProject(DefaultContinuumScm.java:272)
> at org.apache.maven.continuum.core.action.UpdateWorkingDirectoryFromScmContinuumAction.execute(UpdateWorkingDirectoryFromScmContinuumAction.java:58)
> at org.apache.maven.continuum.buildcontroller.DefaultBuildController.build(DefaultBuildController.java:166)
> at org.apache.maven.continuum.buildcontroller.BuildProjectTaskExecutor.executeTask(BuildProjectTaskExecutor.java:47)
> at org.codehaus.plexus.taskqueue.execution.ThreadedTaskQueueExecutor$ExecutorRunnable.run(ThreadedTaskQueueExecutor.java:103)
> at java.lang.Thread.run(Thread.java:534)
> Caused by: org.apache.maven.scm.ScmException: Exception while executing SCM command.
> at org.apache.maven.scm.command.AbstractCommand.execute(AbstractCommand.java:59)
> at org.apache.maven.scm.provider.vss.VssScmProvider.update(VssScmProvider.java:209)
> at org.apache.maven.scm.provider.AbstractScmProvider.update(AbstractScmProvider.java:386)
> at org.apache.maven.scm.provider.AbstractScmProvider.update(AbstractScmProvider.java:363)
> at org.apache.maven.continuum.scm.DefaultContinuumScm.updateProject(DefaultContinuumScm.java:242)
> ... 5 more
> Caused by: java.lang.NullPointerException
> at java.util.Calendar.setTime(Calendar.java:902)
> at java.text.SimpleDateFormat.format(SimpleDateFormat.java:782)
> at java.text.SimpleDateFormat.format(SimpleDateFormat.java:775)
> at java.text.DateFormat.format(DateFormat.java:314)
> at org.apache.maven.scm.provider.vss.commands.changelog.VssHistoryCommand.buildCmdLine(VssHistoryCommand.java:114)
> at org.apache.maven.scm.provider.vss.commands.changelog.VssHistoryCommand.executeChangeLogCommand(VssHistoryCommand.java:52)
> at org.apache.maven.scm.command.changelog.AbstractChangeLogCommand.executeCommand(AbstractChangeLogCommand.java:91)
> at org.apache.maven.scm.command.update.AbstractUpdateCommand.executeCommand(AbstractUpdateCommand.java:63)
> at org.apache.maven.scm.command.AbstractCommand.execute(AbstractCommand.java:55)
--
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