Hello, I tried to download sample data from Synapse demo project (Simple matrix example Python). So, I logined into synapse on python, and tried to get demo files. ``` Iimport synapseclient import synapseutils syn = synapseclient.Synapse() syn.login('synapse_username','password') files = synapseutils.syncFromSynapse(syn, 'syn1901030') ``` and the result was as below ``` Welcome, My name! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! WARNING: ifcollision=overwrite.localis being IGNORED because the download destination is synapse's cache. Instead, the behavior is "overwrite.local". !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Traceback (most recent call last): File "getSynapse.py", line 11, in files = synapseutils.syncFromSynapse(syn, 'syn1901030') File "/usr/local/lib/python2.7/dist-packages/synapseutils/sync.py", line 84, in syncFromSynapse ent = syn.get(result['entity.id'], downloadLocation = path, ifcollision = ifcollision, followLink=followLink) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 695, in get return self._getWithEntityBundle(entityBundle=bundle, entity=entity, **kwargs) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 784, in _getWithEntityBundle self._download_file_entity(downloadLocation, entity, ifcollision, submission) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 841, in _download_file_entity downloadPath) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 1847, in _downloadFileHandle raise exc_info[0](exc_info[1]) **io.UnsupportedOperation: seek** ``` Could you check why this error occurs? and How can I solve this problem?

Created by Seunghwan Shin dolph04
Hello I got the error as shown below ``` Traceback (most recent call last): File "getSynapse.py", line 25, in aFile = syn.get('syn1901031') File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 695, in get return self._getWithEntityBundle(entityBundle=bundle, entity=entity, **kwargs) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 784, in _getWithEntityBundle self._download_file_entity(downloadLocation, entity, ifcollision, submission) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 841, in _download_file_entity downloadPath) File "/usr/local/lib/python2.7/dist-packages/synapseclient/client.py", line 1847, in _downloadFileHandle raise exc_info[0](exc_info[1]) io.UnsupportedOperation: seek ``` and synapseclient.__version__ is '1.7.2' Thank you!
Could you try to use `syn.get` to get a single file? In your example syn1901030 is a Folder. The `syn.get` function does not fetch the whole contents of a Folder. You could try this ID, which is a File in the Folder you tried: ``` aFile = syn.get('syn1901031') ``` Let's see if you get the same error. Could you also let me know what version of the Synapse Python client you have? ``` import synapseclient synapseclient.__version__ ``` Thanks!
1. ubuntu 14.04 2. Python 2.7.6 3. Company network I tried to use syn.get('syn1901030') instead of synapseutils.syncFromSynapse(syn, 'syn1901030'), then I got entity information as below ``` Folder: Simple matrix example Python (syn1901030) path=. properties: accessControlList=/repo/v1/entity/syn1901030/acl annotations=/repo/v1/entity/syn1901030/annotations concreteType=org.sagebionetworks.repo.model.Folder createdBy=377358 createdOn=2013-06-01T18:29:24.698Z entityType=org.sagebionetworks.repo.model.Folder etag=44bb5acd-311f-4d8d-8964-1ad3358645ce id=syn1901030 modifiedBy=377358 modifiedOn=2013-06-01T18:29:24.698Z name=Simple matrix example Python parentId=syn1899339 uri=/repo/v1/entity/syn1901030 annotations: ``` However, when I try to download files by using syncFromSynapse, the upper error occurs. My system is connected to our corporate networks. Therefore, some security settings may be a problem. To download files from synapse by using Python/R, what additional security settings should I change?
Thanks for the report, @dolph04! There are two things going on there: The `WARNING` is explainable, and I have filed a bug report for that (it can safely be ignored): https://sagebionetworks.jira.com/browse/SYNPY-570 The error you're getting I'm not sure about. I have filed a separate bug report for that as well: https://sagebionetworks.jira.com/browse/SYNPY-571 1. What operating system are you using? 1. What Python version? 1. Anything else about your operating environment (shared HPC system, AWS, etc). Thanks!

How to download files of "Synapse demo project" by using python page is loading…