I have 2 copies of a Jupyter notebook, at different locations in my machine. When I run one of the notebooks I get a "BiomartException", but not when I run the other one. The exception I get is:
BiomartException: Query ERROR: caught BioMart::Exception::Database: Could not connect to mysql database ensembl_mart_99: DBI connect('database=ensembl_mart_99;host=127.0.0.1;port=5316','ensro',...) failed: Can't connect to MySQL server on '127.0.0.1' (111) at /net/isilonP/public/ro/ensweb/live/mart/www_99/biomart-perl/lib/BioMart/Configuration/DBLocation.pm line 98.
Anything similar happened to anybody? how did they cope with it?
Thank you :)
I am getting the same issue in R. I will run a getBM function one time and get that error, then I will try again seconds later and it will run with no error. Here is a simple example that is doing this:
Just to clarify--I am accessing mine from the same location each time with inconsistent results.
I believe I am getting the error raised at the same point as you, as I can access the full drosophila dataset, but when I query it I get the exception raised. :/
I'm getting the same problem, from this code:
mart <- useMart("ENSEMBL_MART_ENSEMBL")
mart <- useDataset("hsapiens_gene_ensembl", mart)
annotLookup <- getBM(mart=mart, attributes=c("ensembl_gene_id", "gene_biotype", "external_gene_name"), filter="ensembl_gene_id", values=rownames(cts), uniqueRows=TRUE)
and consistently, i.e. re-trying doesn't help
Moving this to a comment since it is not an answer to the question originally posted above.
Sounds like there is some kind of a database lock that may be preventing access. Have you tried adding a delay before the second query?
looks like from either one location you can't access the MySQL (or ensembl web-) server.
Can you check that you're able to connect to it from both locations you mention?
Hey thanks for your reply!
I do connect to the MySQL server as I can successfully run the below command:
It is when I run the below command, requesting for the gene_biotype that I get the issue raised: