From f687d5d2794786a3909ef4df43337920c65e34db Mon Sep 17 00:00:00 2001 From: Alex Malins Date: Thu, 29 Jan 2026 18:05:08 +0900 Subject: [PATCH 1/4] Update Google developer URLs The existing URLs all redirect to these new URLs --- docs/filelist.rst | 4 ++-- docs/filemanagement.rst | 8 ++++---- docs/fsspec.rst | 2 +- docs/oauth.rst | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/filelist.rst b/docs/filelist.rst index 90899993..71ddbf2e 100644 --- a/docs/filelist.rst +++ b/docs/filelist.rst @@ -43,6 +43,6 @@ Sample code continues from above: .. _`GoogleDriveFile`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile .. _`GoogleDriveFileList`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFileList -.. _`parameters of Files.list()`: https://developers.google.com/drive/v2/reference/files/list#request +.. _`parameters of Files.list()`: https://developers.google.com/workspace/drive/api/reference/rest/v2/files/list#request .. _`GetList()`: /PyDrive2/pydrive2/#pydrive2.apiattr.ApiResourceList.GetList -.. _`search for files`: https://developers.google.com/drive/api/v2/search-files +.. _`search for files`: https://developers.google.com/workspace/drive/api/guides/search-files diff --git a/docs/filemanagement.rst b/docs/filemanagement.rst index 09c8d18e..f8891c99 100644 --- a/docs/filemanagement.rst +++ b/docs/filemanagement.rst @@ -126,7 +126,7 @@ Note: ``InsertPermission()`` calls ``GetPermissions()`` after successfully inserting the permission. You can find more information on the permitted fields of a permission -`here `_. +`here `_. This file is now shared and anyone with the link can view it. But what if you want to check whether a file is already shared? @@ -338,12 +338,12 @@ it you indicate that you acknowledge the risks of downloading potential malware. .. _`Upload()`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.Upload .. _`GoogleAuth`: /PyDrive2/pydrive2/#pydrive2.auth.GoogleAuth .. _`CreateFile()`: /PyDrive2/pydrive2/#pydrive2.drive.GoogleDrive.CreateFile -.. _`Files resource`: https://developers.google.com/drive/v2/reference/files#resource-representations +.. _`Files resource`: https://developers.google.com/workspace/drive/api/reference/rest/v2/files#resource-representations .. _`SetContentFile(filename)`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.SetContentFile .. _`SetContentString(content)`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.SetContentString .. _`GetContentFile(filename)`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.GetContentFile .. _`GetContentString()`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.GetContentString -.. _`official documentation`: https://developers.google.com/drive/v2/reference/files#resource-representations +.. _`official documentation`: https://developers.google.com/workspace/drive/api/reference/rest/v2/files#resource-representations .. _`known`: https://productforums.google.com/forum/#!topic/docs/BJLimQDGtjQ .. _`abusive`: https://support.google.com/docs/answer/148505 -.. _`query_parameters`: https://developers.google.com/drive/api/guides/search-files#examples +.. _`query_parameters`: https://developers.google.com/workspace/drive/api/guides/search-files#examples diff --git a/docs/fsspec.rst b/docs/fsspec.rst index 4216b96d..8a2930fe 100644 --- a/docs/fsspec.rst +++ b/docs/fsspec.rst @@ -122,6 +122,6 @@ about and manipulating files, refer to fsspec docs on .. _`fsspec`: https://filesystem-spec.readthedocs.io/en/latest/ .. _`GDriveFileSystem`: /PyDrive2/pydrive2/#pydrive2.fs.GDriveFileSystem -.. _`delegation of authority`: https://developers.google.com/admin-sdk/directory/v1/guides/delegation +.. _`delegation of authority`: https://developers.google.com/workspace/guides/create-credentials .. _`Abusive files`: /PyDrive2/filemanagement/index.html#abusive-files .. _`how to use a filesystem`: https://filesystem-spec.readthedocs.io/en/latest/usage.html#use-a-file-system diff --git a/docs/oauth.rst b/docs/oauth.rst index 493a6229..8a7cb3c1 100644 --- a/docs/oauth.rst +++ b/docs/oauth.rst @@ -111,7 +111,7 @@ Fields explained: :get_refresh_token (bool): True if you want to retrieve refresh token along with access token. **Default**: False. **Required**: No. :oauth_scope (list of str): OAuth scope to authenticate. **Default**: ['https://www.googleapis.com/auth/drive']. **Required**: No. -.. _delegated: https://developers.google.com/admin-sdk/directory/v1/guides/delegation +.. _delegated: https://developers.google.com/workspace/guides/create-credentials Sample *settings.yaml* ______________________ From 96ee434b8afe946b57447729ee20469270ddc460 Mon Sep 17 00:00:00 2001 From: Alex Malins Date: Thu, 29 Jan 2026 18:05:32 +0900 Subject: [PATCH 2/4] Fix broken search for files link --- docs/filelist.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/filelist.rst b/docs/filelist.rst index 71ddbf2e..f25cfd86 100644 --- a/docs/filelist.rst +++ b/docs/filelist.rst @@ -8,7 +8,7 @@ Get all files which matches the query Create `GoogleDriveFileList`_ instance with `parameters of Files.list()`_ as ``dict``. Call `GetList()`_ and you will get all files that matches your query as a list of `GoogleDriveFile`_. -The syntax and possible option of the query ``q`` parameter can be found in `search for files` Google documentation. +The syntax and possible option of the query ``q`` parameter can be found in `search for files`_ Google documentation. .. code-block:: python From 0e4dd4dd7d9d2687ee71a5a2b8c71a352f8a72ec Mon Sep 17 00:00:00 2001 From: Alex Malins Date: Thu, 29 Jan 2026 18:09:22 +0900 Subject: [PATCH 3/4] Fix broken query strings examples link --- docs/filemanagement.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/filemanagement.rst b/docs/filemanagement.rst index f8891c99..2dc9f66c 100644 --- a/docs/filemanagement.rst +++ b/docs/filemanagement.rst @@ -178,8 +178,9 @@ Get files by complex queries We can get a file by name and by other constraints, usually a filename will be unique but we can have two equal names with different extensions, e.g., *123.jpeg and 123.mp3*. So if you expect only one file add more constraints to -the query, see `Query string examples `_, as a result we get -a list of `GoogleDriveFile`_ instances. +the query, see +`Query string examples `_, +as a result we get a list of `GoogleDriveFile`_ instances. .. code-block:: python @@ -346,4 +347,3 @@ it you indicate that you acknowledge the risks of downloading potential malware. .. _`official documentation`: https://developers.google.com/workspace/drive/api/reference/rest/v2/files#resource-representations .. _`known`: https://productforums.google.com/forum/#!topic/docs/BJLimQDGtjQ .. _`abusive`: https://support.google.com/docs/answer/148505 -.. _`query_parameters`: https://developers.google.com/workspace/drive/api/guides/search-files#examples From fbe3dd789345f832bd0d184fc59ce161e7aa4147 Mon Sep 17 00:00:00 2001 From: Alex Malins Date: Thu, 29 Jan 2026 18:21:31 +0900 Subject: [PATCH 4/4] Replace broken byte order marks link I couldn't find the original forum thread on wayback machine, so replacing with an equivalent from GitHub where a Google employee confirms the issue and links to an Google bug report thread for the issue (it is still not fixed) --- docs/filemanagement.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/filemanagement.rst b/docs/filemanagement.rst index 2dc9f66c..f7ea2859 100644 --- a/docs/filemanagement.rst +++ b/docs/filemanagement.rst @@ -345,5 +345,5 @@ it you indicate that you acknowledge the risks of downloading potential malware. .. _`GetContentFile(filename)`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.GetContentFile .. _`GetContentString()`: /PyDrive2/pydrive2/#pydrive2.files.GoogleDriveFile.GetContentString .. _`official documentation`: https://developers.google.com/workspace/drive/api/reference/rest/v2/files#resource-representations -.. _`known`: https://productforums.google.com/forum/#!topic/docs/BJLimQDGtjQ +.. _`known`: https://github.com/googleapis/google-api-nodejs-client/issues/2404 .. _`abusive`: https://support.google.com/docs/answer/148505