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

Extraction of annotation files error with getAnnotation(bgee) #27

Open
Ni-Ar opened this issue Jul 7, 2022 · 0 comments
Open

Extraction of annotation files error with getAnnotation(bgee) #27

Ni-Ar opened this issue Jul 7, 2022 · 0 comments

Comments

@Ni-Ar
Copy link

Ni-Ar commented Jul 7, 2022

Hi again,

I tried to specify a folder where to dump all Bgee data as following and I get unzipping problems I believe. My goal, would be to
specify the path to a cluster that is mounted on my laptop so that I don't need to have all the species data on my computer but can be stored and cached somewhere else.

library(BgeeDB)

Specify a simple folder in my home directory.

Bgee_path <- "~/Bgee"

Create a new Bgee object like this:

bgee <- Bgee$new(species = "Mus_musculus", dataType = "rna_seq", 
                 pathToData = Bgee_path, release = "15.0")
Querying Bgee to get release information...

Building URL to query species in Bgee release 15_0...

Submitting URL to Bgee webservice... (https://bgee.org/bgee15_0/api/?page=r_package&action=get_all_species&display_type=tsv&source=BgeeDB_R_package&source_version=2.20.1)

Query to Bgee webservice successful!

API key built: 839b6b011488b [omissis] 9c4a13

Get mouse annotation

annotation_bgee_mouse <- getAnnotation(bgee)
tar: could not chdir to '~/Bgee/Mus_musculus_Bgee_15_0'


Saved annotation files in ~/Bgee/Mus_musculus_Bgee_15_0 folder.
Error in getAnnotation(bgee) : 
  ERROR: extraction of annotation files from downloaded zip file went wrong.
In addition: Warning messages:
1: In untar(file.path(myBgeeObject$pathToData, annotationFile), exdir = myBgeeObject$pathToData) :/usr/bin/tar -xf '/Users/niar/Bgee/Mus_musculus_Bgee_15_0/Mus_musculus_RNA-Seq_experiments_libraries.tar.gz' -C '~/Bgee/Mus_musculus_Bgee_15_0'returned error code 1
2: In file.rename(from = myData, to = file.path(myBgeeObject$pathToData,  :
  cannot rename file '/Users/niar/Bgee/Mus_musculus_Bgee_15_0/Mus_musculus_RNA-Seq_experiments_libraries/Mus_musculus_RNA-Seq_experiments.tsv' to '/Users/niar/Bgee/Mus_musculus_Bgee_15_0/Mus_musculus_RNA-Seq_experiments.tsv', reason 'No such file or directory'
3: In file.rename(from = myData, to = file.path(myBgeeObject$pathToData,  :
  cannot rename file '/Users/niar/Bgee/Mus_musculus_Bgee_15_0/Mus_musculus_RNA-Seq_experiments_libraries/Mus_musculus_RNA-Seq_libraries.tsv' to '/Users/niar/Bgee/Mus_musculus_Bgee_15_0/Mus_musculus_RNA-Seq_libraries.tsv', reason 'No such file or directory'

And if I check in the subfolder:

ls -1 ~/Bgee/
Mus_musculus
Mus_musculus_Bgee_15_0
release.tsv

and the subfolders are all empty, while the release.tsv file seems okay.

My system tar version

/usr/bin/tar  --version
bsdtar 3.3.2 - libarchive 3.3.2 zlib/1.2.11 liblzma/5.0.5 bz2lib/1.0.6

R details:

packageVersion("BgeeDB")
[1] ‘2.20.1
Session info ─────────────────────────────────────────────
 setting  value
 version  R version 4.1.2 (2021-11-01)
 os       macOS Catalina 10.15.7
 system   x86_64, darwin17.0
 ui       RStudio
 language (EN)
 collate  en_US.UTF-8
 ctype    en_US.UTF-8
 tz       Europe/Madrid
 date     2022-07-07
 rstudio  2022.02.3+492 Prairie Trillium (desktop)
 pandoc   2.10.1 @ /usr/local/bin/pandoc

Thanks!

garethgillard added a commit to garethgillard/BgeeDB_R that referenced this issue Aug 13, 2024
I was getting errors that the FTP download was not completing. The same as this issue from 2 years ago: BgeeDB#27. I found this was because of how the Bgee database and R package is set up now, the path that is set to where files are downloaded and extracted (pathToData), is the same path that line 76 of getAnnotation.R script deletes by unlinking (dirname(myData)). This removes all downloaded BGee data when running and therefore returns an error. I guess this line was left over from a previous set up. I think just removing will be a fix with no problems.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant