googleapis / googleapis/google-cloud-python

Client recursive_delete() return value not documented

未关闭
#17,266 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
priority: p2 type: docs
主要语言
Python
星标
5.4k
派生
1.8k
平均合并
3 天 4 小时
30 天内合并 PR
122

描述

### Determine this is the right repository

- [x] I determined this is the correct repository in which to report this feature request.

### Summary of the feature request

google/cloud/firestore_v1/client.py::recursive_delete() return value is not documented.
Anyone using the recursive_delete() function will get a number and not understand the meaning of it without digging in the implementation which actually calls another function called _recursive_delete().

### Desired code experience

file: client.py
```python
def recursive_delete(
self,
reference: Union[CollectionReference, DocumentReference],
*,
bulk_writer: Optional["BulkWriter"] = None,
chunk_size: int = 5000,
) -> int:
"""Deletes documents and their subcollections, regardless of collection
name.

Passing a CollectionReference leads to each document in the collection
getting deleted, as well as all of their descendents.

Passing a DocumentReference deletes that one document and all of its
descendents.

Args:
reference (Union[
:class:`@google.cloud.firestore_v1.collection.CollectionReference`,
:class:`@google.cloud.firestore_v1.document.DocumentReference`,
])
The reference to be deleted.

bulk_writer (Optional[:class:`@google.cloud.firestore_v1.bulk_writer.BulkWriter`])
The BulkWriter used to delete all matching documents. Supply this
if you want to override the default throttling behavior.

Returns:
int: The number of documents deleted.
"""
```

### Expected results

recursive_delete() should specify what is the returned int value

### API client name and version

_No response_

### Use case

Anyone using the recursive_delete() function that desires to make use of the return value.

### Additional context

_No response_

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。