5c2dea36479f0669a316e693c21a375d192b9e38 kent Wed Mar 13 12:13:20 2019 -0700 Making cdwPairedEnd basically ignore 10x files by allowing new paired_end values cell_barcode and sample_barcode instead of 1 2. diff --git src/hg/cirm/cdw/lib/cdwLib.c src/hg/cirm/cdw/lib/cdwLib.c index 392ca6f..cedcb59 100644 --- src/hg/cirm/cdw/lib/cdwLib.c +++ src/hg/cirm/cdw/lib/cdwLib.c @@ -2102,41 +2102,45 @@ cdwVcfFileSaveToDb(conn, vcf, "cdwVcfFile", 1024); remove(statsFile); /* Clean up and go home. */ freez(&path); return vcf; } char *cdwOppositePairedEndString(char *end) /* Return "1" for "2" and vice versa */ { if (sameString(end, "1")) return "2"; else if (sameString(end, "2")) return "1"; +else if (sameString(end, "cell_barcode") || sameString(end, "sample_barcode")) + return NULL; else { errAbort("Expecting 1 or 2, got %s in oppositeEnd", end); return NULL; } } struct cdwValidFile *cdwOppositePairedEnd(struct sqlConnection *conn, struct cdwFile *ef, struct cdwValidFile *vf) /* Given one file of a paired end set of fastqs, find the file with opposite ends. */ { char *otherEnd = cdwOppositePairedEndString(vf->pairedEnd); +if (otherEnd == NULL) + return NULL; char query[1024]; sqlSafef(query, sizeof(query), "select cdwValidFile.* from cdwValidFile join cdwFile on cdwValidFile.fileId=cdwFile.id" " where experiment='%s' and submitDirId=%d and outputType='%s' and replicate='%s' " " and part='%s' and pairedEnd='%s' and itemCount=%lld and deprecated=''" , vf->experiment, ef->submitDirId, vf->outputType, vf->replicate, vf->part, otherEnd , vf->itemCount); struct cdwValidFile *otherVf = cdwValidFileLoadByQuery(conn, query); if (otherVf == NULL) return NULL; if (otherVf->next != NULL) errAbort("Multiple results from pairedEnd query %s", query); return otherVf; }