Skip to content
This repository was archived by the owner on May 17, 2024. It is now read-only.

Commit 8f091e8

Browse files
vvkhgithub-actions[bot]
authored andcommitted
style fixes by ruff
1 parent da1af64 commit 8f091e8

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

data_diff/databases/bigquery.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class Dialect(BaseDialect):
7676
TYPE_ARRAY_RE = re.compile(r"ARRAY<(.+)>")
7777
TYPE_STRUCT_RE = re.compile(r"STRUCT<(.+)>")
7878
# [BIG]NUMERIC, [BIG]NUMERIC(precision, scale), [BIG]NUMERIC(precision)
79-
TYPE_NUMERIC_RE = re.compile(r'^((BIG)?NUMERIC)(?:\((\d+)(?:, (\d+))?\))?$')
79+
TYPE_NUMERIC_RE = re.compile(r"^((BIG)?NUMERIC)(?:\((\d+)(?:, (\d+))?\))?$")
8080
# https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#parameterized_decimal_type
8181
# The default scale is 9, which means a number can have up to 9 digits after the decimal point.
8282
DEFAULT_NUMERIC_PRECISION = 9
@@ -128,9 +128,7 @@ def parse_type(
128128
if m:
129129
precision = int(m.group(3)) if m.group(3) else None
130130
scale = int(m.group(4)) if m.group(4) else None
131-
col_type = Decimal(
132-
precision=scale if scale else 0 if precision else 9
133-
)
131+
col_type = Decimal(precision=scale if scale else 0 if precision else 9)
134132
return col_type
135133

136134
return col_type

0 commit comments

Comments
 (0)