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

Conflict with the BaseSpaceR package #82

Open
francestong opened this issue Oct 14, 2021 · 0 comments
Open

Conflict with the BaseSpaceR package #82

francestong opened this issue Oct 14, 2021 · 0 comments

Comments

@francestong
Copy link

francestong commented Oct 14, 2021

There's a conflict if both BaseSpaceR and sevenbridges packages are loaded at the same time (doesn't matter the order), and I haven't been able to figure out which functions are causing the issue or use a workaround. This issue keeps crashing my Shiny app that automates the transfer of files from BaseSpace to SevenBridges.

If BaseSpaceR is not loaded, then sevenbridges works fine:

> library(sevenbridges)
> a <- sevenbridges::Auth(
+     token = [mytoken],
+     platform = "aws-us"
+ )
Using platform: aws-us
> a$project()
[[1]]
== Project ==
id : frances/frances-s-demo-project
name : frances's Demo Project
[[2]]
== Project ==
id : internal/fastqs
name : FASTQs

If BaseSpaceR is loaded as well, then sevenbridges is unable to find its own methods:

> library(BaseSpaceR)
BaseSpaceR version 1.37.0, ?BaseSpaceR for help

Attaching package: ‘BaseSpaceR’

The following object is masked from ‘package:sevenbridges’:

    Files
> library(sevenbridges)
> a <- sevenbridges::Auth(
+     token = [mytoken],
+     platform = "aws-us"
+ )
Using platform: aws-us
> a$project()
Error in .Object$initialize(...) : attempt to apply non-function

Unloading BaseSpaceR and its namespace will allow the sevenbridges methods to work again. Note that unload needs to be set to TRUE.

detach("package:BaseSpaceR", unload = TRUE)

Also, using the conflicted package when loading both packages returns no conflicts between each other.

Here are the versions that I'm using:

> packageVersion("BaseSpaceR")
[1] ‘1.37.0’
> packageVersion("sevenbridges")
[1] ‘1.23.0’
> R.version
               _                           
platform       x86_64-apple-darwin17.0     
arch           x86_64                      
os             darwin17.0                  
system         x86_64, darwin17.0          
status                                     
major          4                           
minor          1.1                         
year           2021                        
month          08                          
day            10                          
svn rev        80725                       
language       R                           
version.string R version 4.1.1 (2021-08-10)
nickname       Kick Things                 
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