[ensembl-dev] Could not get adaptor MetaContainer for homo_sapiens core

Reece Hart reece at harts.net
Sat May 28 16:17:22 BST 2016


More info: getting a Transcript adaptor works, but getting a Gene or Slice
adaptor fails.
This is with perl 5.22.1 on Ubuntu 16.04.

#!/usr/bin/env perl

use Bio::EnsEMBL::Registry;

my $registry = 'Bio::EnsEMBL::Registry';

$registry->load_registry_from_db(
    -host => 0 ? 'ensembldb.ensembl.org' : 'useastdb.ensembl.org',
    -user => 'anonymous'
);

my @db_adaptors = @{ $registry->get_all_DBAdaptors() };
printf("Got %d adapters with get_all_DBAdaptors\n", $#db_adaptors + 1);

foreach $a_type ('Gene', 'Transcript', 'Slice') {
    print("=" x 80, "\n");
    print("Trying to get $a_type adaptor...\n");
    my $a = $registry->get_adaptor( 'Human', 'Core', $a_type );
    print("Got $a_type adaptor\n");
}


Gives

snafu$ stdbuf -e0 -o0 /tmp/e-error
Got 180 adapters with get_all_DBAdaptors
================================================================================
Trying to get Gene adaptor...

-------------------- WARNING ----------------------
MSG: 'Bio::EnsEMBL::DBSQL::MetaContainer' cannot be found.
Exception UNIVERSAL does not export anything at
/home/reece/opt/es/84/bioperl-live/Bio/Tree/TreeFunctionsI.pm line 94.
BEGIN failed--compilation aborted at
/home/reece/opt/es/84/bioperl-live/Bio/Tree/TreeFunctionsI.pm line 94.
Compilation failed in require at /usr/share/perl/5.22/base.pm line 97.
...propagated at /usr/share/perl/5.22/base.pm line 106.
BEGIN failed--compilation aborted at
/home/reece/opt/es/84/bioperl-live/Bio/Tree/Tree.pm line 111.
Compilation failed in require at
/home/reece/opt/es/84/bioperl-live/Bio/DB/Taxonomy.pm line 83.
BEGIN failed--compilation aborted at
/home/reece/opt/es/84/bioperl-live/Bio/DB/Taxonomy.pm line 83.
Compilation failed in require at
/home/reece/opt/es/84/bioperl-live/Bio/Species.pm line 102.
BEGIN failed--compilation aborted at
/home/reece/opt/es/84/bioperl-live/Bio/Species.pm line 102.
Compilation failed in require at
/home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/MetaContainer.pm
line 59.
BEGIN failed--compilation aborted at
/home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/MetaContainer.pm
line 59.
Compilation failed in require at (eval 203) line 2.


FILE: Bio/EnsEMBL/Registry.pm LINE: 1169
CALLED BY: Bio/EnsEMBL/Registry.pm  LINE: 2852
Date (localtime)    = Sat May 28 08:14:03 2016
Ensembl API version = 84
---------------------------------------------------
================================================================================
Trying to get Transcript adaptor...
================================================================================
Trying to get Slice adaptor...

-------------------- WARNING ----------------------
MSG: 'Bio::EnsEMBL::DBSQL::MetaContainer' cannot be found.
Exception Attempt to reload Bio/EnsEMBL/DBSQL/MetaContainer.pm aborted.
Compilation failed in require at (eval 206) line 2.


FILE: Bio/EnsEMBL/Registry.pm LINE: 1169
CALLED BY: EnsEMBL/DBSQL/DBAdaptor.pm  LINE: 988
Date (localtime)    = Sat May 28 08:14:03 2016
Ensembl API version = 84
---------------------------------------------------

-------------------- WARNING ----------------------
MSG: Could not find MetaContainer adaptor in the registry for homo_sapiens
core

FILE: EnsEMBL/DBSQL/DBAdaptor.pm LINE: 991
CALLED BY: EnsEMBL/DBSQL/SliceAdaptor.pm  LINE: 135
Date (localtime)    = Sat May 28 08:14:03 2016
Ensembl API version = 84
---------------------------------------------------

-------------------- EXCEPTION --------------------
MSG: Could not get adaptor MetaContainer for homo_sapiens core

STACK Bio::EnsEMBL::DBSQL::DBAdaptor::AUTOLOAD
/home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/DBAdaptor.pm:995
STACK Bio::EnsEMBL::DBSQL::SliceAdaptor::new
/home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/SliceAdaptor.pm:135
STACK Bio::EnsEMBL::Registry::get_adaptor
/home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/Registry.pm:1182
STACK toplevel /tmp/e-error:18
Date (localtime)    = Sat May 28 08:14:03 2016
Ensembl API version = 84
---------------------------------------------------


On Fri, May 27, 2016 at 11:18 PM, Reece Hart <reece at harts.net> wrote:

> I've been banging my head against this error for a while now. Does it ring
> a bell to anyone?
>
> MSG: Could not get adaptor MetaContainer for homo_sapiens core
>
> STACK Bio::EnsEMBL::DBSQL::DBAdaptor::AUTOLOAD
> /home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/DBAdaptor.pm:995
> STACK Bio::EnsEMBL::DBSQL::SliceAdaptor::new
> /home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/DBSQL/SliceAdaptor.pm:135
> STACK Bio::EnsEMBL::Registry::get_adaptor
> /home/reece/opt/es/84/ensembl/modules/Bio/EnsEMBL/Registry.pm:1182
> STACK toplevel ./sbin/ensembl-fetch:206
> Date (localtime)    = Fri May 27 23:11:02 2016
> Ensembl API version = 84
>
>
> I verified the same issue with code lifted almost directly from the core
> api tutorial:
>
> use Bio::EnsEMBL::Registry;
>
> my $registry = 'Bio::EnsEMBL::Registry';
>
> $registry->load_registry_from_db(
>     -host => 'ensembldb.ensembl.org', # alternatively '
> useastdb.ensembl.org'
>     -user => 'anonymous'
> );
>
> my $sa = $registry->get_adaptor( 'Human', 'Core', 'Slice' );
>
>
> Oddly (to me), $registry->get_all_DBAdaptors() works.
>
> This is with e-84.
>
> Thanks,
> Reece
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20160528/f4c92e69/attachment.html>


More information about the Dev mailing list