Copilot commented on code in PR #63919:
URL: https://github.com/apache/airflow/pull/63919#discussion_r3066472291
##########
dev/breeze/src/airflow_breeze/utils/docker_command_utils.py:
##########
@@ -182,8 +182,11 @@ def check_docker_is_running():
)
if response.returncode != 0:
console_print(
- "[error]Docker is not running.[/]\n[warning]Please make sure
Docker is installed and running.[/]"
- )
+ "[error]Docker is not running.[/]\n"
+ "[warning]Please make sure Docker is installed and running.[/]\n"
+ "[info]If you are using environments like GitHub Codespaces,
Docker may not be available or properly configured.[/]\n"
+ "[info]Refer to the Breeze documentation for supported development
environments and setup instructions.[/]"
+)
Review Comment:
This multi-line message is easy to accidentally break (as seen with the
closing `)` indentation). Consider switching to a single triple-quoted string
(or assembling a list of lines and `'\\n'.join(...)`) to make the structure
clearer and reduce the chance of formatting/indentation mistakes. This is
optional but helps prevent regressions when the message is edited again.
```suggestion
"\n".join(
[
"[error]Docker is not running.[/]",
"[warning]Please make sure Docker is installed and
running.[/]",
"[info]If you are using environments like GitHub
Codespaces, Docker may not be available or properly configured.[/]",
"[info]Refer to the Breeze documentation for supported
development environments and setup instructions.[/]",
]
)
)
```
##########
dev/breeze/src/airflow_breeze/utils/docker_command_utils.py:
##########
@@ -182,8 +182,11 @@ def check_docker_is_running():
)
if response.returncode != 0:
console_print(
- "[error]Docker is not running.[/]\n[warning]Please make sure
Docker is installed and running.[/]"
- )
+ "[error]Docker is not running.[/]\n"
+ "[warning]Please make sure Docker is installed and running.[/]\n"
+ "[info]If you are using environments like GitHub Codespaces,
Docker may not be available or properly configured.[/]\n"
+ "[info]Refer to the Breeze documentation for supported development
environments and setup instructions.[/]"
+)
Review Comment:
Line 189 dedents the closing parenthesis of `console_print(...)` to the left
margin, which will break Python block indentation (likely causing an
`IndentationError` / unexpected dedent given the surrounding indented `if`
block). Keep the closing `)` indented consistently with the `console_print(`
call (and let the formatter handle wrapping) so the statement remains part of
the indented suite.
```suggestion
)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]