I am using google colab. I am trying to download the training data. I obtain the following error. Any hint?
files = synapseutils.syncFromSynapse(syn,'syn53643828',path=destination_folder)
SynapseHTTPError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/synapseutils/sync.py in _sync_file(self, entity_id, parent_folder_sync, path, ifcollision, followLink, progress, downloadFile)
370 ):
--> 371 entity = self._syn.get(
372 entity_id,
17 frames
SynapseHTTPError: 403 Client Error:
insufficient_scope. Request lacks scope(s) required by this service: download
The above exception was the direct cause of the following exception:
ValueError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/synapseutils/sync.py in _sync_root(self, root, root_path, ifcollision, followLink, progress, downloadFile, manifest)
435 exception = root_folder_sync.get_exception()
436 if exception:
--> 437 raise ValueError("File download failed during sync") from exception
438
439 (
ValueError: File download failed during sync
Created by bruno jedynak jedynak Hi @jedynak,
The error you provided indicates it failed due to lack of sufficient access to download the folder. I see that you are on the participant team. Based on your code, here is the code snippet that can download the folder:
```sh
import synapseclient
import synapseutils
syn = synapseclient.Synapse()
syn.login(email='', authToken='')
# You should see the welcome message with your name once logged in:
Welcome, !
synapseutils.syncFromSynapse(syn, 'syn53643828', path='')
```
Please ensure you are logged in with the account that has registered for the Challenge. For more details, see the [login](https://python-docs.synapse.org/reference/client/?h=login#synapseclient.Synapse.login) function documentation.
If you prefer using the CLI, here is the code snippet:
`synapse get -r syn53643828`
Please let me know if you have any issues. Hi, yes, I am a member of this team.
Here is the line I used in Google colab:
files = synapseutils.syncFromSynapse(syn,'syn53643828',path=destination_folder)
Here is the error message I received:
SynapseHTTPError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/synapseutils/sync.py in _sync_file(self, entity_id, parent_folder_sync, path, ifcollision, followLink, progress, downloadFile)
370 ):
--> 371 entity = self._syn.get(
372 entity_id,
17 frames
SynapseHTTPError: 403 Client Error:
insufficient_scope. Request lacks scope(s) required by this service: download
The above exception was the direct cause of the following exception:
ValueError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/synapseutils/sync.py in _sync_root(self, root, root_path, ifcollision, followLink, progress, downloadFile, manifest)
435 exception = root_folder_sync.get_exception()
436 if exception:
--> 437 raise ValueError("File download failed during sync") from exception
438
439 (
ValueError: File download failed during sync Hi @jedynak,
Before attempting to download the file, did you join the @AIInstituteinDynamicSystemsChallengeParticipants team? It's necessary for access.
If so, could you please share the code snippet or commands you executed? This will help us identify the issue more effectively.
Thank you,
Rong