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

improve Traceback calls #20

Open
Pezhvuk opened this issue Mar 14, 2019 · 2 comments
Open

improve Traceback calls #20

Pezhvuk opened this issue Mar 14, 2019 · 2 comments

Comments

@Pezhvuk
Copy link

Pezhvuk commented Mar 14, 2019

Hi Branden,

Perhaps, the hardest issue with debugging, that I have noticed, is the lack of comprehensive Traceback calls, as in the following report:

[1] "/d/as2/u/mp002/sumrep_project/Gupta/igblast"
[1] "/d/as2/u/mp002/sumrep_project/Gupta/fasta/S-GMC_+14d.fasta"
[1] "igblast_S-GMC_+14d_output.tsv"

 /d/harpy1/s/python/v3-5.1.0/bin/AssignGenes.py igblast -s /d/as2/u/mp002/sumrep_project/Gupta/fasta/S-GMC_+14d.fasta -b /d/harpy1/s/igblast/ncbi-igblast-1.12.0 --organism human --loci ig --format airr --exec /d/harpy1/s/igblast/ncbi-igblast-1.12.0/bin/igblastn -o /d/as2/u/mp002/sumrep_project/Gupta/igblast/igblast_S-GMC_+14d_output.tsv --nproc 12 
<simpleError in data.table::fread(., stringsAsFactors = TRUE): File '/d/as2/u/mp002/sumrep_project/Gupta/igblast/igblast_S-GMC_+14d_output.tsv' does not exist or is non-readable. getwd()=='/d/harpy1/s/igblast/ncbi-igblast-1.12.0'>
Warning message in file.remove(.):
“cannot remove file '/d/as2/u/mp002/sumrep_project/Gupta/igblast/igblast_S-GMC_+14d_output.tsv', reason 'No such file or directory'”
Error in getIgBlastAnnotations(input_fileName, output_filename = outputName, : object 'annotations' not found
Traceback:

1. getIgBlastAnnotations(input_fileName, output_filename = outputName, 
 .     num_threads = NO_threads, receptor_type = "BCR", igblast_dir = "/d/harpy1/s/igblast/ncbi-igblast-1.12.0", 
 .     changeo_dir = "/d/harpy1/s/python/v3-5.1.0/bin")

I think the problem has something to do with the sys command for some reason, but there isn't enough info to resolve it. I am experiencing a similar problem with PartisFunctions, too (will post separately).
This particular issue actually turned to be two-fold, the sys command, as well as the absence of germline genes in the expected directory, i.e. ~/shared directory, which would be a problem for the AssignGenes.py script. The AssignGenes.py, I believe, reports this problem, but this is not reflected in the Sumrep error report.

I eventually resolved this issue by changing the assignment to the igblast_command function (the one within the igBlastFunction.R script) by directly passing the command-line command for igblast.

Best,
Peji.

@BrandenOlson
Copy link
Collaborator

BrandenOlson commented Mar 17, 2019

Hey Peji -

Thanks for the info regarding this error. I'll be sure to add an informative error message for this situation.

I absolutely agree that tracebacks could be clearer. I'm currently looking into the cleanest way to incorporate this into general and will keep you updated. I should have more time to work on this once this quarter ends next week.

@Pezhvuk
Copy link
Author

Pezhvuk commented Mar 18, 2019

Hi Branden,

No problem. :)

I am going to try something and see if all the system related error reports could be improved by changing how the system functions are passed, e.g. changing igblast_command %>% system to system(igblast_command, intern=True), or something similar. I will try this for Partis today, and will be in touch shortly.

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

No branches or pull requests

2 participants