When a user calls GET /path, if Datalad is used, we call datalad get on the requested path to download all files from the remote. However, if one of these files is a symlink to another file from the dataset, this other file will not be gotten. In that sense, let's say a user sends a GET /path/symlink.txt?action=content, even if the file pointed to by the symlink is a file the user should have access to, as it would not be gotten by a datalad get, we would run into issues. The same goes for symlinks pointing to folders. On a datalad get, the pointed at folder's content will not be gotten automatically by datalad. A specific datalad get on the folder pointed at by the symlink have to be used. Adding to that the fact that all files inside a dataset are symlinks for as long as they are not unlocked, the situation can get complicated to know what to explicitely get and what not to get.
I currently an implementation that seems to be working in all of our possible cases on the datalad-gdrive-1 branch on my fork, which should be merged soon. However, after discussion with the Datalad team, they may implement a new option that could solve our problem directly from Datalad. Please keep an eye on this issue datalad/datalad#2747 and edit the code in consequence if the solution ends up being implemented internally in Datalad.
When a user calls
GET /path, if Datalad is used, we calldatalad geton the requested path to download all files from the remote. However, if one of these files is a symlink to another file from the dataset, this other file will not be gotten. In that sense, let's say a user sends aGET /path/symlink.txt?action=content, even if the file pointed to by the symlink is a file the user should have access to, as it would not be gotten by adatalad get, we would run into issues. The same goes for symlinks pointing to folders. On adatalad get, the pointed at folder's content will not be gotten automatically by datalad. A specificdatalad geton the folder pointed at by the symlink have to be used. Adding to that the fact that all files inside a dataset are symlinks for as long as they are not unlocked, the situation can get complicated to know what to explicitely get and what not to get.I currently an implementation that seems to be working in all of our possible cases on the
datalad-gdrive-1branch on my fork, which should be merged soon. However, after discussion with the Datalad team, they may implement a new option that could solve our problem directly from Datalad. Please keep an eye on this issue datalad/datalad#2747 and edit the code in consequence if the solution ends up being implemented internally in Datalad.