Skip to content

Commit 3f6153b

Browse files
chore(python): use black==22.3.0 (#301)
Source-Link: googleapis/synthtool@6fab84a Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:7cffbc10910c3ab1b852c05114a08d374c195a81cdec1d4a67a1d129331d0bfe
1 parent 938fe7c commit 3f6153b

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

document_ai/snippets/batch_process_documents_sample.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ def batch_process_documents(
6363
# Location can be 'us' or 'eu'
6464
name = f"projects/{project_id}/locations/{location}/processors/{processor_id}"
6565
request = documentai.types.document_processor_service.BatchProcessRequest(
66-
name=name, input_documents=input_config, document_output_config=output_config,
66+
name=name,
67+
input_documents=input_config,
68+
document_output_config=output_config,
6769
)
6870

6971
operation = client.batch_process_documents(request)

document_ai/snippets/noxfile.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
# WARNING - WARNING - WARNING - WARNING - WARNING
3030
# WARNING - WARNING - WARNING - WARNING - WARNING
3131

32-
BLACK_VERSION = "black==19.10b0"
32+
BLACK_VERSION = "black==22.3.0"
3333

3434
# Copy `noxfile_config.py` to your directory and modify it instead.
3535

@@ -253,7 +253,7 @@ def py(session: nox.sessions.Session) -> None:
253253

254254

255255
def _get_repo_root() -> Optional[str]:
256-
""" Returns the root folder of the project. """
256+
"""Returns the root folder of the project."""
257257
# Get root of this repository. Assume we don't have directories nested deeper than 10 items.
258258
p = Path(os.getcwd())
259259
for i in range(10):

document_ai/snippets/process_document_splitter_sample.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def process_document_splitter_sample(
7575

7676

7777
def page_refs_to_string(page_refs: dict) -> str:
78-
""" Converts a page ref to a string describing the page or page range."""
78+
"""Converts a page ref to a string describing the page or page range."""
7979
if len(page_refs) == 1:
8080
num = str(int(page_refs[0].page) + 1)
8181
return f"page {num} is"

0 commit comments

Comments
 (0)