Author Topic: Error with piping and --ec in bedops 2.0.0  (Read 3068 times)

melissa

  • Newbie
  • *
  • Posts: 7
Error with piping and --ec in bedops 2.0.0
« on: March 05, 2013, 08:05:39 PM »
Hi bedops team,
I just downloaded version 2.0.0 and am experiencing incorrect behavior on piped input with the --ec option.  I am using the linux binaries. Here are some examples:

# here is the bedfile
[mt269@swiftgen ~]$ cat small.bed
chr1   0   1

# this works fine
[mt269@swiftgen ~]$ ~/bedops_2.0.0/bedops --merge --ec small.bed
chr1   0   1

# and so does this
mt269@swiftgen ~]$ cat small.bed | ~/bedops_2.0.0/bedops --merge --ec -
chr1   0   1

# but this doesn't
[mt269@swiftgen ~]$ cat small.bed | ~/bedops_2.0.0/bedops --merge --ec /dev/stdin
# (returns nothing!)

# and neither does this
[mt269@swiftgen ~]$ ~/bedops_2.0.0/bedops --merge --ec <( cat small.bed )
# (also returns nothing)

All of these commands work fine with version 1.2.5.  They also work fine with either version without the --ec option.  Any idea what is going on?

Thanks, and I love the software.  It has revolutionized the work flow in our lab :-)
-Melissa

sjn

  • Administrator
  • Jr. Member
  • *****
  • Posts: 72
Re: Error with piping and --ec in bedops 2.0.0
« Reply #1 on: March 05, 2013, 08:19:09 PM »
Thanks for the kind words, Melissa!

Well, I have to be honest - your use cases that break are something I've never tried.  We'll take a close look soon.

Yes, the --ec mode changed with the latest release to support starch archives, and to support the new --chrom operation.  That's true without --ec too though and both modes should work fine with the cases shown.

Shane
« Last Edit: March 06, 2013, 07:31:15 AM by sjn »