Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ericscript error #1

Open
sscien opened this issue Jan 12, 2022 · 7 comments
Open

Ericscript error #1

sscien opened this issue Jan 12, 2022 · 7 comments

Comments

@sscien
Copy link
Collaborator

sscien commented Jan 12, 2022

This error pops up from running Fusion pipeline on RIS compute1

In file(file, ifelse(append, "a", "w")) :
cannot open file '/usr/local/envs/Fusion/share/ericscript-0.5.5-5/lib/data/_resources/.flag.dbexists': Permission denied
Execution halted
readline() on closed filehandle FILE at /usr/local/envs/Fusion/bin/ericscript.pl line 177.
Use of uninitialized value $flagdb in numeric eq (==) at /usr/local/envs/Fusion/bin/ericscript.pl line 178.

@sscien
Copy link
Collaborator Author

sscien commented Jan 12, 2022

nf-core/rnafusion#164

This seems to be a docker-specific issue, thinking of overwriting the ericscript.pl in conda env or executing ericscript.pl outside conda.

@sscien
Copy link
Collaborator Author

sscien commented Jan 12, 2022

Solution 1: chmod 777 /usr/local/envs/Fusion/share/ericscript-0.5.5-5/lib/data/_resources/.flag.dbexists

chmod o-rwx /usr/local/envs/Fusion/share/ericscript-0.5.5-5/lib/data/_resources/

chmod: changing permissions of '/usr/local/envs/Fusion/share/ericscript-0.5.5-5/lib/data/_resources/': Operation not permitted

Solution2:
/storage1/fs1/dinglab/Active/Projects/PECGS/PECGS_pipeline/Fusion/ericscript-0.5.5/ericscript.pl
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
Can't locate Pod/Usage.pm in @inc (you may need to install the Pod::Usage module) (@inc contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at /storage1/fs1/dinglab/Active/Projects/PECGS/PECGS_pipeline/Fusion/ericscript-0.5.5/ericscript.pl line 5.
BEGIN failed--compilation aborted at /storage1/fs1/dinglab/Active/Projects/PECGS/PECGS_pipeline/Fusion/ericscript-0.5.5/ericscript.pl line 5.

@sscien
Copy link
Collaborator Author

sscien commented Jan 12, 2022

Pod::Usage has been bundled with Perl since Perl 5.6.0. You have a broken (i.e. partial) installation of Perl, since it's missing that module.

Since your system is suppose to have it already, Pod::Usage is not bundled in the perlbrew installer like the other modules it uses.

Either install Pod::Usage first, or use the correct command line args for perlbrew (since it loads Pod::Usage when a help message needs to be displayed, from what I can tell).

@sscien
Copy link
Collaborator Author

sscien commented Jan 12, 2022

Solution 3
FROM continuumio/miniconda3:4.3.11

ARG DEBIAN_FRONTEND=noninteractive

RUN conda install -c bioconda pyvcf

COPY filter_nsamples.py /opt/conda/bin
RUN chmod +x /opt/conda/bin/filter_nsamples.py

RUN sed -i 's/args.output, inp/open(args.output, 'w'), inp/' /opt/conda/bin/vcf_filter.py
ENV PATH="/opt/conda/bin:${PATH}"
ARG PATH="/opt/conda/bin:${PATH}"

CMD ["/bin/bash cd /opt"]

@sscien
Copy link
Collaborator Author

sscien commented Jan 13, 2022

Pod::Usage has been bundled with Perl since Perl 5.6.0. You have a broken (i.e. partial) installation of Perl, since it's missing that module.

Since your system is suppose to have it already, Pod::Usage is not bundled in the perlbrew installer like the other modules it uses.

Either install Pod::Usage first, or use the correct command line args for perlbrew (since it loads Pod::Usage when a help message needs to be displayed, from what I can tell).

This was because we were not calling perl from the conda env.

Solution:
In ericscript.pl
change #!/usr/bin/ perl to #!/usr/bin/env perl

@sscien
Copy link
Collaborator Author

sscien commented Jan 13, 2022

This issue was caused by the permission issue with ericscript docker, which hasn't been solved by other people. ericscript hasn't been updated for many years.

Ultimate solution:

So instead of using theericscript.plfrom conda, we use theericscript.plfrom local which we could modify. And we use all other dependencies from the conda env.

In fusion_pipeline_ris_v1.sh, change In ericscript.pl to

/storage1/fs1/dinglab/Active/Projects/PECGS/PECGS_pipeline/Fusion/ericscript-0.5.5/ericscript.pl -o ERICSCRIPT --remove -ntrim 0 --refid homo_sapiens -db $genome_db -p $cpu -name $sample $fq_1 $fq_2 1> logs/ericscript.out 2> logs/ericscript.err

@sscien
Copy link
Collaborator Author

sscien commented Jan 13, 2022

Here are the logs for successfully testing ericscript

(Fusion) y.song@compute1-exec-262:/storage1/fs1/dinglab/Active/Projects/ALCHEMIST/Alchemist_analysis/RNA-seq_Fusion_Alchemist_batch_01_11_22/ALCH-ACXH-TTP1-A$ /storage1/fs1/dinglab/Active/Projects/PECGS/PECGS_pipeline/Fusion/ericscript-0.5.5/ericscript.pl -o ERICSCRIPT --remove -ntrim 0 --refid homo_sapiens -db $genome_db -p 4 -name ALCH-ACXH-TTP1-A ALCH-ACXH-TTP1-A_1.fastq.gz ALCH-ACXH-TTP1-A_2.fastq.gz
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
During startup - Warning messages:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_COLLATE failed, using "C"
3: Setting LC_TIME failed, using "C"
4: Setting LC_MESSAGES failed, using "C"
5: Setting LC_MONETARY failed, using "C"
6: Setting LC_PAPER failed, using "C"
7: Setting LC_MEASUREMENT failed, using "C"
[EricScript] Updating BWA indexes for homo_sapiens ...^[[Odone.

[EricScript] Starting EricScript analysis for sample ALCH-ACXH-TTP1-A.
[EricScript] Aligning with bwa ...^[[B^[[B^[[I^[[Odone.
During startup - Warning messages:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_COLLATE failed, using "C"
3: Setting LC_TIME failed, using "C"
4: Setting LC_MESSAGES failed, using "C"
5: Setting LC_MONETARY failed, using "C"
6: Setting LC_PAPER failed, using "C"
7: Setting LC_MEASUREMENT failed, using "C"
[EricScript] Extracting discordant alignments ... During startup - Warning messages:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_COLLATE failed, using "C"
3: Setting LC_TIME failed, using "C"
4: Setting LC_MESSAGES failed, using "C"
5: Setting LC_MONETARY failed, using "C"
6: Setting LC_PAPER failed, using "C"
7: Setting LC_MEASUREMENT failed, using "C"
done.
[EricScript] Building exon junction reference ... During startup - Warning messages:
1: Setting LC_CTYPE failed, using "C"
2: Setting LC_COLLATE failed, using "C"
3: Setting LC_TIME failed, using "C"
4: Setting LC_MESSAGES failed, using "C"
5: Setting LC_MONETARY failed, using "C"
6: Setting LC_PAPER failed, using "C"
7: Setting LC_MEASUREMENT failed, using "C"
done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant