github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {darker}-->


:warning: Python code formatter, darker found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
darker --check --diff -r origin/main...HEAD llvm/utils/git/code-format-helper.py
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from darker here.
</summary>

``````````diff
--- code-format-helper.py       2025-10-28 20:39:06.000000 +0000
+++ code-format-helper.py       2025-10-28 20:40:24.212537 +0000
@@ -497,12 +497,16 @@
         if args.verbose:
             print(f"=== Debug: DumpASTMatchersHelper ===")
             print(f"Current working directory: {os.getcwd()}")
             print(f"Script directory: {self.script_dir}")
             print(f"Script name: {self.script_name}")
-            print(f"Script full path: {os.path.join(self.script_dir, 
self.script_name)}")
-            print(f"Script exists: 
{os.path.exists(os.path.join(self.script_dir, self.script_name))}")
+            print(
+                f"Script full path: {os.path.join(self.script_dir, 
self.script_name)}"
+            )
+            print(
+                f"Script exists: {os.path.exists(os.path.join(self.script_dir, 
self.script_name))}"
+            )
             print(f"Output HTML path: {self.output_html}")
             print(f"Output HTML exists: {os.path.exists(self.output_html)}")
 
         # Verify the input file exists
         matchers_header = "clang/include/clang/ASTMatchers/ASTMatchers.h"
@@ -554,18 +558,22 @@
         )
 
         if args.verbose:
             print(f"Git diff exit code: {proc.returncode}")
             if proc.returncode != 0:
-                print(f"Output HTML was modified (diff length: 
{len(proc.stdout)} chars)")
+                print(
+                    f"Output HTML was modified (diff length: 
{len(proc.stdout)} chars)"
+                )
             else:
                 print(f"Output HTML was NOT modified - check passed!")
 
         # 'LibASTMatchersReference.html' was modified - count as failure
         if proc.returncode != 0:
             if args.verbose:
-                print(f"error: {self.name} detected that {self.output_html} 
was modified")
+                print(
+                    f"error: {self.name} detected that {self.output_html} was 
modified"
+                )
                 print(f"This means the developer needs to run the script 
locally")
                 print(f"Diff preview (first 500 chars):\n{proc.stdout[:500]}")
             return proc.stdout
         else:
             return None

``````````

</details>


https://github.com/llvm/llvm-project/pull/165472
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to