expired SQLiteConnection in GoSemSim package.
5
0
Entering edit mode
@anupambtech2007-7589
Last seen 9.6 years ago
United States

I have just installed GOSeSim package in Biocoundoctor. I tried to run genesim function. for the 1st time it worked. But after that, its giving below error :

Error in sqliteSendQuery(con, statement, bind.data) :
  expired SQLiteConnection

 

gene ontology GOSemsim • 3.1k views
ADD COMMENT
0
Entering edit mode
Guangchuang Yu ★ 1.2k
@guangchuang-yu-5419
Last seen 9 days ago
China/Guangzhou/Southern Medical Univer…

please post your sessionInfo() and also code for me to reproduce your error.

ADD COMMENT
0
Entering edit mode

> library(org.Hs.eg.db)
> library(GO.db)
> library(GOSemSim)
>
> temp <- geneSim("5921", "9046", ont = "BP", organism = "human", measure = "Wang", combine = "max")
Error in sqliteSendQuery(con, statement, bind.data) :
  expired SQLiteConnection
> sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_IN       LC_NUMERIC=C         LC_TIME=en_IN       
 [4] LC_COLLATE=en_IN     LC_MONETARY=en_IN    LC_MESSAGES=en_IN   
 [7] LC_PAPER=en_IN       LC_NAME=C            LC_ADDRESS=C        
[10] LC_TELEPHONE=C       LC_MEASUREMENT=en_IN LC_IDENTIFICATION=C

attached base packages:
[1] grDevices datasets  parallel  stats     graphics  stats4    utils    
[8] methods   base     

other attached packages:
 [1] BiocInstaller_1.16.2 GOSemSim_1.24.1      GO.db_3.0.0         
 [4] org.Hs.eg.db_3.0.0   AnnotationDbi_1.28.2 GenomeInfoDb_1.2.5  
 [7] IRanges_2.0.1        S4Vectors_0.4.0      Biobase_2.26.0      
[10] BiocGenerics_0.12.1  RSQLite_1.0.0        DBI_0.3.1           

loaded via a namespace (and not attached):
 [1] bitops_1.0-6   digest_0.6.8   httr_0.6.1     Rcpp_0.11.5    RCurl_1.95-4.5
 [6] stringr_0.6.2  swirl_2.2.21   testthat_0.9.1 tools_3.1.2    yaml_2.1.13   
>

 

ADD REPLY
0
Entering edit mode
Guangchuang Yu ★ 1.2k
@guangchuang-yu-5419
Last seen 9 days ago
China/Guangzhou/Southern Medical Univer…

I can't reproduce your error.

 

> temp <- geneSim("5921", "9046", ont = "BP", organism = "human", measure = "Wang", combine = "max")
> temp
$geneSim
[1] 1

$GO1
 [1] "GO:0000281" "GO:0001570" "GO:0009790" "GO:0043524" "GO:0001953"
 [6] "GO:0007165" "GO:0007162" "GO:0030833" "GO:0048514" "GO:0035556"
[11] "GO:0008360" "GO:0051252" "GO:0032320" "GO:0046580"

$GO2
[1] "GO:0007596" "GO:0007165" "GO:0007166" "GO:0050900"

> sessionInfo()
R version 3.1.3 (2015-03-09)
Platform: x86_64-apple-darwin14.1.0 (64-bit)
Running under: OS X 10.10.3 (Yosemite)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] parallel  stats4    stats     graphics  grDevices utils     datasets
[8] methods   base

other attached packages:
 [1] GOSemSim_1.24.1      GO.db_3.0.0          org.Hs.eg.db_3.0.0
 [4] RSQLite_1.0.0        DBI_0.3.1            AnnotationDbi_1.28.2
 [7] GenomeInfoDb_1.3.13  IRanges_2.1.40       S4Vectors_0.5.21
[10] Biobase_2.27.1       BiocGenerics_0.13.4  roxygen2_4.1.0
[13] devtools_1.7.0       magrittr_1.5         BiocInstaller_1.16.2

loaded via a namespace (and not attached):
[1] fortunes_1.5-2 Rcpp_0.11.5    stringr_0.6.2  tools_3.1.3

 

Actually, GOSemSim do not use SQLiteConnection directly, it use interface provided by AnnotationDbi package.

 

Can you post traceback() output after the error shown?

 

 

ADD COMMENT
0
Entering edit mode
@anupambtech2007-7589
Last seen 9.6 years ago
United States

Error in sqliteSendQuery(con, statement, bind.data) :
  expired SQLiteConnection
> temp <- geneSim("5921", "9046", ont = "BP", organism = "human", measure = "Wang", combine = "max")
Error in sqliteSendQuery(con, statement, bind.data) :
  expired SQLiteConnection
> traceback()
26: .Call(rsqlite_query_send, con@Id, as.character(statement), bind.data)
25: sqliteSendQuery(con, statement, bind.data)
24: sqliteGetQuery(conn, statement)
23: .local(conn, statement, ...)
22: dbGetQuery(conn, SQL)
21: dbGetQuery(conn, SQL)
20: dbQuery(conn, SQL)
19: dbSelectFromL2Rchain(dbconn(x), L2Rchain, x@Lkeys, x@Rkeys)
18: getPartialSubmap("BP")
17: eval(expr, envir, enclos)
16: eval(quote(list(...)), env)
15: eval(quote(list(...)), env)
14: standardGeneric("rbind")
13: rbind(getPartialSubmap("BP"), getPartialSubmap("CC"), getPartialSubmap("MF"))
12: .local(x, ...)
11: flatten(x, fromKeys.only = TRUE)
10: flatten(x, fromKeys.only = TRUE)
9: as.list(envir)
8: as.list(envir)
7: mget(i, envir = x, ifnotfound = NA)
6: mget(i, envir = x, ifnotfound = NA)
5: .doubleBracketSub(x, i, j, ...)
4: gomap[[gene]]
3: gomap[[gene]]
2: gene2GO(gene1, organism = organism, ont = ont, dropCodes = drop)
1: geneSim("5921", "9046", ont = "BP", organism = "human", measure = "Wang",
       combine = "max")

 

ADD COMMENT
0
Entering edit mode
Guangchuang Yu ★ 1.2k
@guangchuang-yu-5419
Last seen 9 days ago
China/Guangzhou/Southern Medical Univer…

Do you still have the problem when updating to Bioconductor 3.1 with R 3.2.0?
 

ADD COMMENT
0
Entering edit mode
@paulson-ariel-6239
Last seen 6.8 years ago
United States

I had a similar problem after reloading an old saved session.  I deleted the following cache objects in my environment: "GOSemSimEnv", "SemSimCache", "DOSEEnv" and re-ran the function and things worked fine.

 

ADD COMMENT
0
Entering edit mode

If the issue is due to reloading old saved session, then it is not an issue.

File connection can't be restored in another R session.

> x=file("x.txt", "w")
> x
description       class        mode        text      opened    can read
    "x.txt"      "file"         "w"      "text"    "opened"        "no"
  can write
      "yes"
> save(x, file="x.rda")

If you start another R session and load the x.rda, you will find that x is expired.

> load("x.rda")
> x
Error in summary.connection(x) : invalid connection

 

 

ADD REPLY
0
Entering edit mode

how to delete the following cache objects in the environment: "GOSemSimEnv", "SemSimCache", "DOSEEnv  ???

ADD REPLY
0
Entering edit mode

You can use for example rm(GOSemSimEnv) to delete GOSemSimEnv, but you really don't need to delete them. 

 

ADD REPLY

Login before adding your answer.

Traffic: 617 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6