<div dir="ltr">Hi Sebastian,<div><br></div><div>Can you share your full command line?</div><div><br></div><div>That line of code should not be triggered unless you have either --database (which should cause the script to fail on startup) or --write_cache (which you shouldn't use unless you really know what you're doing!) enabled.</div><div><br></div><div>Regards</div><div><br></div><div>Will McLaren</div><div>Ensembl Variation</div></div><div class="gmail_extra"><br><div class="gmail_quote">On 1 October 2015 at 14:16, Sebastian Ginzel <span dir="ltr"><<a href="mailto:sginze2s@inf.h-brs.de" target="_blank">sginze2s@inf.h-brs.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I am using VEP 80 and use the --offline and --cache option, which usually works fine, but now fails on one input file with the message:<br>
<br>
Can't call method "db" on an undefined value at /path_to_lib/ensembl_80/lib/ensembl-variation/modules/Bio/EnsEMBL/Variation/Utils/VEP.pm line 6360, <GEN0> line 190004<br>
<br>
After digging into the code I found that this line is called when a variant is not available in the cache and VEP tries to retrieve the information from the database via through the get_variations_from_region function.<br>
<br>
The line where the script fails is:<br>
    if(defined($config->{vfa}->db)) {<br>
<br>
Other functions such as 'have_pubmed' have an additional condition which prevents the error:<br>
    if(defined($config->{vfa}) && defined($config->{vfa}->db)) {<br>
<br>
I fixed the error for my VEP script by adding the "defined($config->{vfa})" condition. But now I am wondering if the error is intentional and if not which should be the default return value, if the script is running in offline mode.<br>
<br>
<br>
Best wishes,<br>
Sebastian Ginzel<br>
<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
Dev mailing list    <a href="mailto:Dev@ensembl.org" target="_blank">Dev@ensembl.org</a><br>
Posting guidelines and subscribe/unsubscribe info: <a href="http://lists.ensembl.org/mailman/listinfo/dev" rel="noreferrer" target="_blank">http://lists.ensembl.org/mailman/listinfo/dev</a><br>
Ensembl Blog: <a href="http://www.ensembl.info/" rel="noreferrer" target="_blank">http://www.ensembl.info/</a><br>
</blockquote></div><br></div>