Sage-Bionetworks / synapser

An R package providing programmatic access to Synapse
Apache License 2.0
32 stars 21 forks source link

synSetAnnotations not accessible in MacOS/Windows but works fine on Linux #331

Closed anngvu closed 6 months ago

anngvu commented 6 months ago

Operating system

NOT an issue on Ubuntu Linux, but an issue on Mac OSX and Windows 10.

Description of the problem

> synapser::synSetAnnotations("syn51811164", annotations=list(foo="bar", baz=1))
Error: 'synSetAnnotations' is not an exported object from 'namespace:synapser'

Expected behavior

Works fine on Linux. Submits and prints the annotations as a list.

Actual behavior

> synapser::synSetAnnotations("syn51811164", annotations=list(foo="bar", baz=1))
Error: 'synSetAnnotations' is not an exported object from 'namespace:synapser'

Output of sessionInfo()R version 4.2.1 (2022-06-23)

Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS 14.3.1

Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/lib/libRlapack.dylib

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] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] synapser_2.0.0.200

loaded via a namespace (and not attached):
 [1] compiler_4.2.1   rjson_0.2.21     here_1.0.1       Matrix_1.6-5     rprojroot_2.0.4 
 [6] tools_4.2.1      Rcpp_1.0.12      reticulate_1.28  codetools_0.2-18 grid_4.2.1      
[11] jsonlite_1.8.8   png_0.1-8        lattice_0.22-5  
thomasyu888 commented 6 months ago

Ah, apologies for the inconvenience. That function was removed as it wasn't working properly within the R client: https://r-docs.synapse.org/news/index.html. See changelog.

We should definitely have some sort of deprecation warning...

anngvu commented 6 months ago

😦 Oh that's a big bummer; have always considered this to be a pretty core, at least one of the top 3 in usage for us. Updating the function docs would be helpful, thanks.

thomasyu888 commented 6 months ago

@anngvu we do plan on adding it back in after we refactor some things in the client. It just currently doesn't work due to the way reticulate converts objects that inherit from Python dict