On Mon, Aug 4, 2014 at 1:44 AM, Wolfgang Mauerer <wm@xxxxxxxxxxxxxxxx> wrote: > On 02/08/2014 12:42, Mitchell Joblin wrote: > > - the mailing list analysis periods may not always include > > the analysis periods for the version control system > > > > - now we check for the case where the period falls outside > > the mailing list analysis range ignore the periods rather > > than fail completely > > > > Signed-off-by: Mitchell Joblin <mitchell.joblin.ext@xxxxxxxxxxx> > > --- > > codeface/R/boundaries.r | 17 ++++++++++++----- > > 1 file changed, 12 insertions(+), 5 deletions(-) > > > > diff --git a/codeface/R/boundaries.r b/codeface/R/boundaries.r > > index 5f971bc..b915883 100644 > > --- a/codeface/R/boundaries.r > > +++ b/codeface/R/boundaries.r > > @@ -25,11 +25,18 @@ get.boundaries <- function(i, conf) { > > rc <- NA > > rc <- tstamps.rc[i,]$date > > > > - return(data.frame(date.start=tstamps.release[i,]$date, > > - date.end=tstamps.release[i+1,]$date, > > - date.rc_start=rc, > > - tag=tag, > > - cycle=paste(tag.start, tag, sep="-"))) > > + if(identical(tag, character(0)) | identical(tag.start, character(0))) > { > > + df <- data.frame() > > the approach makes sense, but did you make sure that all callers of > get.boundaries() deal correctly with empty data frames? > The function get.boundaries() is only called by prepare.release.boundaries() and that is fine with handling empty data frames. If all the release boundaries are empty then we have another problem and that will probably result in another failure. I am working on getting the email analysis to be more robust to these kinds of things. I any case this patch is solid. Kind regards, Mitchell > > Thanks, Wolfgang > > > + } > > + else { > > + df <- data.frame(date.start=tstamps.release[i,]$date, > > + date.end=tstamps.release[i+1,]$date, > > + date.rc_start=rc, > > + tag=tag, > > + cycle=paste(tag.start, tag, sep="-")) > > + } > > + > > + return(df) > > } > > > > prepare.release.boundaries <- function(conf) { > > > > >