From 39bae61c58046a04d1274d36704c463051a8460a Mon Sep 17 00:00:00 2001 From: Jac Fitzgerald Date: Mon, 9 Nov 2026 14:59:44 -0800 Subject: [PATCH] Correct the get_by_id docstring: it sends a PUT get_by_id builds a ProjectItem with only the ID and calls update, so it sends PUT /projects/. The docstring said it used the update endpoint without the ability to update the project, which is wrong. An empty update changed no fields in a live check, and the call needs permission to update the project. Co-Authored-By: Claude Code --- tableauserverclient/server/endpoint/projects_endpoint.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tableauserverclient/server/endpoint/projects_endpoint.py b/tableauserverclient/server/endpoint/projects_endpoint.py index e0b529bc0..6f5500371 100644 --- a/tableauserverclient/server/endpoint/projects_endpoint.py +++ b/tableauserverclient/server/endpoint/projects_endpoint.py @@ -164,7 +164,9 @@ def get_by_path(self, path: str) -> "ProjectItem | None": def get_by_id(self, project_id: str) -> ProjectItem: """ Fetch a project by ID. This is a convenience method making up for a gap in the server API. - It uses the same endpoint as the update method, but without the ability to update the project. + It sends the same request as the update method with no project details set, so it does not + update the project. The request requires permission to update the project, so a user without + that permission gets an error. """ if not project_id: error = "Project ID undefined."