diff --git a/.travis.yml b/.travis.yml
index daecc9c..365f0fa 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -2,70 +2,26 @@ notifications:
   slack: wtsi-cgpit:ptUMR1tkNyZJYd9TpGoss8WR
   email: false
 
-env:
- - CC=gcc
+sudo: false
 
-addons:
- apt:
-  packages:
-   - autoconf
-   - bsdtar
-   - build-essential
-   - curl
-   - exonerate
-   - libboost-iostreams-dev
-   - libboost-dev
-   - libbz2-dev
-   - libcurl4-openssl-dev
-   - libexpat1-dev
-   - libgoogle-perftools-dev
-   - liblzma-dev
-   - libncurses5-dev
-   - libpng12-dev
-   - libpstreams-dev
-   - lsof
-   - nettle-dev
-   - time
-   - unzip
-   - zlib1g-dev
-   - libgd-dev
-   - libdb-dev
-   - liblzma-dev
-   - libgnutls-dev
-   - libtasn1-6-dev
-   - p11-kit
+services:
+  - docker
 
-install:
- - git clone --depth 1 --single-branch --branch develop https://github.com/cancerit/cgpBigWig.git
- - cd cgpBigWig
- - ./setup.sh $HOME/wtsi-opt
- - cd ../
- - rm -rf cgpBigWig
- - git clone --depth 1 --single-branch --branch develop https://github.com/cancerit/PCAP-core.git
- - cd PCAP-core
- - ./setup.sh $HOME/wtsi-opt
- - cd ../
- - rm -rf PCAP-core
- - git clone --depth 1 --single-branch --branch dev https://github.com/cancerit/cgpVcf.git
- - cd cgpVcf
- - ./setup.sh $HOME/wtsi-opt
- - cd ../
- - rm -rf cgpVcf
- - git clone --depth 1 --single-branch --branch dev https://github.com/cancerit/VAGrENT.git
- - cd VAGrENT
- - ./setup.sh $HOME/wtsi-opt
- - cd ../
- - rm -rf VAGrENT
- - git clone --depth 1 --single-branch --branch dev https://github.com/cancerit/grass.git
- - cd grass
- - ./setup.sh $HOME/wtsi-opt
- - cd ../
- - rm -rf grass
-
-language: perl
+script:
+ - set -e
+ - echo 'Build and check docker image'
+ - docker build -t brass .
+ - docker images | grep -c brass
+ - echo 'Verify program(s) from each inherited base image - cgpbigwig'
+ - docker run -t --rm brass bwjoin --version
+ - echo 'Verify program(s) from each inherited base image - pcap-core'
+ - docker run -t --rm brass bwa_mem.pl -version
+ - docker run -t --rm brass bammarkduplicates2 --version
+ - docker run -t --rm brass samtools --version
+ - docker run -t --rm brass bash -c 'bwa 2>&1 | grep Version'
+ - echo 'Verify program(s) from this repo'
+ - docker run -t --rm brass brass.pl --version
+ - docker run -t --rm brass brass-group --version
+ - docker run -t --rm brass brass-assemble --version
 
-perl:
- - "5.22"
 
-script:
- - ./setup.sh $HOME/wtsi-opt 2
diff --git a/CHANGES.md b/CHANGES.md
index bec6958..23bd70a 100644
--- a/CHANGES.md
+++ b/CHANGES.md
@@ -1,5 +1,12 @@
 # Changes
 
+## v6.3.1
+
+* Handle undefined value edge case #95.
+  * Thanks to @udvzol for reproducible test data.
+* Updated travis build (#89)
+* Fixed up dockerfile to reduce build time when testing.
+
 ## v6.3.0
 
 * Adds stand alone (supported) docker container
diff --git a/Dockerfile b/Dockerfile
index e3bf331..6bfe98a 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM  quay.io/wtsicgp/dockstore-cgpmap:3.1.4 as builder
+FROM  quay.io/wtsicgp/pcap-core:5.0.4 as builder
 
 USER  root
 
@@ -57,6 +57,11 @@ ADD build/opt-build.sh build/
 RUN bash build/opt-build.sh $OPT
 
 # build the tools in this repo, separate to reduce build time on errors
+COPY Rsupport Rsupport
+COPY distros distros
+ADD build/opt-build-local-deps.sh build/
+RUN bash build/opt-build-local-deps.sh $OPT
+
 COPY . .
 RUN bash build/opt-build-local.sh $OPT
 
diff --git a/build/opt-build-local-deps.sh b/build/opt-build-local-deps.sh
new file mode 100644
index 0000000..7608eea
--- /dev/null
+++ b/build/opt-build-local-deps.sh
@@ -0,0 +1,80 @@
+#! /bin/bash
+
+set -xe
+
+if [[ -z "${TMPDIR}" ]]; then
+  TMPDIR=/tmp
+fi
+
+set -u
+
+if [ "$#" -lt "1" ] ; then
+  echo "Please provide an installation path such as /opt/ICGC"
+  exit 1
+fi
+
+# get path to this script
+SCRIPT_PATH=`dirname $0`;
+SCRIPT_PATH=`(cd $SCRIPT_PATH && pwd)`
+
+# get the location to install to
+INST_PATH=$1
+mkdir -p $1
+INST_PATH=`(cd $1 && pwd)`
+echo $INST_PATH
+
+# get current directory
+INIT_DIR=`pwd`
+
+CPU=`grep -c ^processor /proc/cpuinfo`
+if [ $? -eq 0 ]; then
+  if [ "$CPU" -gt "6" ]; then
+    CPU=6
+  fi
+else
+  CPU=1
+fi
+echo "Max compilation CPUs set to $CPU"
+
+SETUP_DIR=$INIT_DIR/install_tmp
+mkdir -p $SETUP_DIR/distro # don't delete the actual distro directory until the very end
+mkdir -p $INST_PATH/bin
+cd $SETUP_DIR
+
+# make sure tools installed can see the install loc of libraries
+set +u
+export LD_LIBRARY_PATH=`echo $INST_PATH/lib:$LD_LIBRARY_PATH | perl -pe 's/:\$//;'`
+export PATH=`echo $INST_PATH/bin:$PATH | perl -pe 's/:\$//;'`
+export MANPATH=`echo $INST_PATH/man:$INST_PATH/share/man:$MANPATH | perl -pe 's/:\$//;'`
+export PERL5LIB=`echo $INST_PATH/lib/perl5:$PERL5LIB | perl -pe 's/:\$//;'`
+set -u
+
+# Rlibs
+if [ ! -e $SETUP_DIR/Rlib.success ]; then
+  cd $INIT_DIR/Rsupport
+  ./setupR.sh $OPT
+  touch $SETUP_DIR/Rlib.success
+fi
+
+## install included distro for velvet
+if [ ! -e $SETUP_DIR/velvet.success ]; then
+  cd $INIT_DIR
+  cd $INIT_DIR/distros
+  tar -mzxf velvet_1.2.10.tgz
+  cd velvet_1.2.10
+  make MAXKMERLENGTH=95 velveth velvetg
+  mv velveth $INST_PATH/bin/velvet95h
+  mv velvetg $INST_PATH/bin/velvet95g
+  make clean
+  make velveth velvetg   	# don't do multi-threaded make
+  mv velveth $INST_PATH/bin/velvet31h
+  mv velvetg $INST_PATH/bin/velvet31g
+  ln -fs $INST_PATH/bin/velvet95h $INST_PATH/bin/velveth
+  ln -fs $INST_PATH/bin/velvet95g $INST_PATH/bin/velvetg
+  cd $INIT_DIR
+  rm -rf $INIT_DIR/distros/velvet_1.2.10
+  touch $SETUP_DIR/velvet.success
+fi
+
+# cleanup all junk
+rm -rf $SETUP_DIR
diff --git a/build/opt-build-local.sh b/build/opt-build-local.sh
index d7dac37..66f7e4c 100755
--- a/build/opt-build-local.sh
+++ b/build/opt-build-local.sh
@@ -49,33 +49,6 @@ export MANPATH=`echo $INST_PATH/man:$INST_PATH/share/man:$MANPATH | perl -pe 's/
 export PERL5LIB=`echo $INST_PATH/lib/perl5:$PERL5LIB | perl -pe 's/:\$//;'`
 set -u
 
-# Rlibs
-if [ ! -e $SETUP_DIR/Rlib.success ]; then
-  cd $INIT_DIR/Rsupport
-  ./setupR.sh $OPT
-  touch $SETUP_DIR/Rlib.success
-fi
-
-## install included distro for velvet
-if [ ! -e $SETUP_DIR/velvet.success ]; then
-  cd $INIT_DIR
-  cd $INIT_DIR/distros
-  tar -mzxf velvet_1.2.10.tgz
-  cd velvet_1.2.10
-  make MAXKMERLENGTH=95 velveth velvetg
-  mv velveth $INST_PATH/bin/velvet95h
-  mv velvetg $INST_PATH/bin/velvet95g
-  make clean
-  make velveth velvetg   	# don't do multi-threaded make
-  mv velveth $INST_PATH/bin/velvet31h
-  mv velvetg $INST_PATH/bin/velvet31g
-  ln -fs $INST_PATH/bin/velvet95h $INST_PATH/bin/velveth
-  ln -fs $INST_PATH/bin/velvet95g $INST_PATH/bin/velvetg
-  cd $INIT_DIR
-  rm -rf $INIT_DIR/distros/velvet_1.2.10
-  touch $SETUP_DIR/velvet.success
-fi
-
 ## brass c++
 if [ ! -e $SETUP_DIR/brass.success ]; then
   cd $INIT_DIR
diff --git a/perl/bin/brass.pl b/perl/bin/brass.pl
index ab1a81c..2e953c2 100755
--- a/perl/bin/brass.pl
+++ b/perl/bin/brass.pl
@@ -1,7 +1,7 @@
 #!/usr/bin/perl
 
 ########## LICENCE ##########
-# Copyright (c) 2014-2018 Genome Research Ltd.
+# Copyright (c) 2014-2020 Genome Research Ltd.
 #
 # Author: CASM/Cancer IT <cgphelp@sanger.ac.uk>
 #
@@ -371,7 +371,7 @@ =head1 SYNOPSIS
     -genome    -g   Genome fasta file
     -species   -s   Species name
     -assembly  -as  Assembly name
-    -protocol  -pr  Sequencing protocol (WGS|WXS|RNA)
+    -protocol  -pr  Sequencing protocol (WGS only - remains for compat)
     -g_cache   -gc  Genome cache file.
     -viral     -vi  Virus sequences from NCBI
     -microbe   -mi  Microbe sequences file prefix from NCBI, please exclude '.N.fa.2bit'
diff --git a/perl/bin/get_abs_bkpts_from_clipped_reads.pl b/perl/bin/get_abs_bkpts_from_clipped_reads.pl
index 6d88e1a..8a722f2 100644
--- a/perl/bin/get_abs_bkpts_from_clipped_reads.pl
+++ b/perl/bin/get_abs_bkpts_from_clipped_reads.pl
@@ -1,7 +1,7 @@
 #!/usr/bin/perl
 
 ########## LICENCE ##########
-# Copyright (c) 2014-2018 Genome Research Ltd.
+# Copyright (c) 2014-2020 Genome Research Ltd.
 #
 # Author: CASM/Cancer IT <cgphelp@sanger.ac.uk>
 #
@@ -600,8 +600,7 @@ sub collect_reads_by_region {
   $dir = ($dir eq '+' ? 1 : -1);
   $mate_dir = ($mate_dir eq '+' ? 1 : -1);
 
-  my @aln = $bam->get_features_by_location($chr, $start, $end);
-  @aln = grep {
+  my @aln = grep {
     # !is_supplementary($_->flag) &&
     $_->get_tag_values('FLAGS') =~ /PAIRED/ &&
     $_->get_tag_values('FLAGS') !~ /UNMAPPED/ &&
@@ -615,13 +614,14 @@ sub collect_reads_by_region {
     (
       $ignore_mate_pos ||
       (
+        defined $_->mate_seq_id &&
         $_->mate_seq_id eq $mate_chr &&
         $_->mstrand   eq $mate_dir &&
         $_->mate_start  <= $mate_end &&
         $_->mate_start + $_->length - 1 >= $mate_start
       )
     )
-  } @aln;
+  } $bam->get_features_by_location($chr, $start, $end);
   return @aln;
 }
 
diff --git a/perl/lib/Bio/Brass.pm b/perl/lib/Bio/Brass.pm
index ad91e6c..2c81c6c 100644
--- a/perl/lib/Bio/Brass.pm
+++ b/perl/lib/Bio/Brass.pm
@@ -1,7 +1,7 @@
 package Bio::Brass;
 
 ########## LICENCE ##########
-# Copyright (c) 2014-2019 Genome Research Ltd.
+# Copyright (c) 2014-2020 Genome Research Ltd.
 #
 # Author: CASM/Cancer IT <cgphelp@sanger.ac.uk>
 #
@@ -46,7 +46,7 @@ our @EXPORT = qw(find_breakpoints find_dusty_vertices
 		 is_dusty get_isolated_bp_alignment get_isolated_bp_surrounding_region
 		 $VERSION);
 
-our $VERSION = '6.3.0';
+our $VERSION = '6.3.1';
 
 =head1 NAME