Skip to content

Commit 20a0598

Browse files
authored
[black] Update 22.12.0 -> 23.7.0 (#15620)
## Summary & Motivation Bump black after skipping several releases. Aside from minor bugfixes and performance improvements, highlights are: - condensed formatting of multiline strings in arg lists - cleaner formatting of ternary expressions in arg lists - allowing trailing `"""` of docstring to extend past line limit ## How I Tested These Changes Existing test suite.
1 parent 81baaa8 commit 20a0598

File tree

272 files changed

+1952
-2200
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

272 files changed

+1952
-2200
lines changed

.buildkite/dagster-buildkite/dagster_buildkite/pipelines/dagster_oss_main.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ def build_dagster_oss_main_steps() -> List[BuildkiteStep]:
4040
env={
4141
"DAGSTER_BRANCH": branch_name,
4242
"DAGSTER_COMMIT_HASH": commit_hash,
43-
"DAGSTER_UI_ONLY_OSS_CHANGE": "1"
44-
if not skip_if_no_dagster_ui_changes()
45-
else "",
43+
"DAGSTER_UI_ONLY_OSS_CHANGE": (
44+
"1" if not skip_if_no_dagster_ui_changes() else ""
45+
),
4646
"DAGSTER_CHECKOUT_DEPTH": _get_setting("DAGSTER_CHECKOUT_DEPTH") or "100",
4747
},
4848
),

.buildkite/dagster-buildkite/dagster_buildkite/steps/dagster.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,8 @@ def build_graphql_python_client_backcompat_steps() -> List[CommandStep]:
145145
CommandStepBuilder(":graphql: GraphQL Python Client backcompat")
146146
.on_test_image(AvailablePythonVersion.get_default())
147147
.run(
148-
(
149-
"pip install -e python_modules/dagster[test] -e python_modules/dagster-graphql -e"
150-
" python_modules/automation"
151-
),
148+
"pip install -e python_modules/dagster[test] -e python_modules/dagster-graphql -e"
149+
" python_modules/automation",
152150
"dagster-graphql-client query check",
153151
)
154152
.with_skip(

.buildkite/dagster-buildkite/dagster_buildkite/steps/helm.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,8 @@ def _build_lint_steps(package_spec) -> List[CommandStep]:
7474
CommandStepBuilder("dagster dependency build")
7575
# https://github.com/dagster-io/dagster/issues/8167
7676
.run(
77-
(
78-
"helm repo add bitnami-pre-2022"
79-
" https://raw.githubusercontent.com/bitnami/charts/eb5f9a9513d987b519f0ecd732e7031241c50328/bitnami"
80-
),
77+
"helm repo add bitnami-pre-2022"
78+
" https://raw.githubusercontent.com/bitnami/charts/eb5f9a9513d987b519f0ecd732e7031241c50328/bitnami",
8179
"helm dependency build helm/dagster",
8280
)
8381
.with_skip(skip_if_no_helm_changes() and package_spec.skip_reason)

.buildkite/dagster-buildkite/dagster_buildkite/steps/test_project.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,9 @@ def build_test_project_steps() -> List[GroupStep]:
4242
# credentials
4343
"/scriptdir/aws.pex ecr get-login --no-include-email --region us-west-2 | sh",
4444
'export GOOGLE_APPLICATION_CREDENTIALS="/tmp/gcp-key-elementl-dev.json"',
45-
(
46-
"/scriptdir/aws.pex s3 cp"
47-
" s3://$${BUILDKITE_SECRETS_BUCKET}/gcp-key-elementl-dev.json"
48-
" $${GOOGLE_APPLICATION_CREDENTIALS}"
49-
),
45+
"/scriptdir/aws.pex s3 cp"
46+
" s3://$${BUILDKITE_SECRETS_BUCKET}/gcp-key-elementl-dev.json"
47+
" $${GOOGLE_APPLICATION_CREDENTIALS}",
5048
"export"
5149
" BASE_IMAGE=$${AWS_ACCOUNT_ID}.dkr.ecr.us-west-2.amazonaws.com/test-project-base:py"
5250
+ version

.buildkite/dagster-buildkite/dagster_buildkite/steps/tox.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ def build_tox_step(
4141
None,
4242
[
4343
"tox",
44-
"-vv", # extra-verbose
4544
"-c %s " % tox_file if tox_file else None,
45+
"-vv", # extra-verbose
4646
"-e",
4747
tox_env,
4848
],

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/psf/black
3-
rev: refs/tags/22.12.0:refs/tags/22.12.0
3+
rev: refs/tags/23.7.0:refs/tags/23.7.0
44

55
# We need two instances of the black pre-commit hook because black can only run with a single
66
# config, but we need different configs for docs_snippets and the rest of the repo due to

docs/content/guides/dagster/branch_deployments.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -253,9 +253,11 @@ branch_deployment_jobs = [
253253
defs = Definitions(
254254
assets=[items, comments, stories],
255255
resources=resources[get_current_env()],
256-
jobs=branch_deployment_jobs
257-
if os.getenv("DAGSTER_CLOUD_IS_BRANCH_DEPLOYMENT") == "1"
258-
else [],
256+
jobs=(
257+
branch_deployment_jobs
258+
if os.getenv("DAGSTER_CLOUD_IS_BRANCH_DEPLOYMENT") == "1"
259+
else []
260+
),
259261
)
260262
```
261263

docs/content/integrations/airflow/from-airflow-to-dagster.mdx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,12 @@ with DAG(
4242
retries=3,
4343
)
4444

45-
templated_command = dedent(
46-
"""
45+
templated_command = dedent("""
4746
{% for i in range(5) %}
4847
echo "{{ ds }}"
4948
echo "{{ macros.ds_add(ds, 7)}}"
5049
{% endfor %}
51-
"""
52-
)
50+
""")
5351

5452
t3 = BashOperator(
5553
task_id="templated",

docs/content/integrations/bigquery/reference.mdx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -588,10 +588,8 @@ from dagster import Definitions, asset
588588
def small_petals(bigquery: BigQueryResource):
589589
with bigquery.get_client() as client:
590590
return client.query(
591-
(
592-
'SELECT * FROM IRIS.IRIS_DATA WHERE "petal_length_cm" < 1 AND'
593-
' "petal_width_cm" < 1'
594-
),
591+
'SELECT * FROM IRIS.IRIS_DATA WHERE "petal_length_cm" < 1 AND'
592+
' "petal_width_cm" < 1',
595593
).result()
596594

597595

docs/dagit-screenshot/dagit_screenshot/cli.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,10 @@ def dagit_screenshot(ctx, output_root: str, spec_db: str, workspace_root: str) -
3939
ctx.obj["workspace_root"] = workspace_root
4040

4141

42-
@dagit_screenshot.command(
43-
help="""
42+
@dagit_screenshot.command(help="""
4443
Audit a screenshot spec database. Verifies that screenshot specs are valid and that referenced
4544
workspace files exist. Optionally verify that corresponding output files exist.
46-
"""
47-
)
45+
""")
4846
@click.option(
4947
"--verify-outputs/--no-verify-outputs",
5048
type=click.BOOL,

0 commit comments

Comments
 (0)