Commit 3534faf3 authored by Wei Shoulin's avatar Wei Shoulin
Browse files

fix(csst_dfs_client): update success condition in write_file function

- Change the success condition from checking response code to response success flag
parent f819b17d
Pipeline #9223 failed with stages
in 0 seconds
......@@ -114,7 +114,7 @@ def write_file(local_file: Union[IO, str, list]) -> Result:
for i in range(0, len(data), batch_size):
batch_data = data[i:i + batch_size]
response = request.post("/api/plan/file", {"plans": batch_data})
if response.code != 200:
if not response.success:
return response
return Result.ok_data(len(data))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment