You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by li...@apache.org on 2026/10/22 14:19:02 UTC

(arrow-adbc) branch main updated: chore: drop cmake-format pre-commit hook (#4934)

This is an automated email from the ASF dual-hosted git repository.

lidavidm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-adbc.git


The following commit(s) were added to refs/heads/main by this push:
     new ed48aa5664 chore: drop cmake-format pre-commit hook (#4934)
ed48aa5664 is described below

commit ed48aa5664f83255f2d9596a14eaa5ef9aa59024
Author: David Li <li...@gmail.com>
AuthorDate: Thu Oct 22 07:18:56 2026 -0700

    chore: drop cmake-format pre-commit hook (#4934)
    
    On Python 3.15, it breaks because it's misusing re.Scanner:
    
    ```
      File "[...]/cmakelang/lex/__init__.py", line 135, in tokenize
        scanner = re.Scanner([
            # double quoted string
        ...<48 lines>...
             lambda s, t: (TokenType.UNQUOTED_LITERAL, t)),
        ], re.DOTALL)
      File "[...]/lib/python3.15/re/__init__.py", line 406, in __init__
        raise ValueError("Cannot use capturing groups in re.Scanner")
    ValueError: Cannot use capturing groups in re.Scanner
    ```
    
    There are potential alternatives, but for now, let's remove this hook.
    Note that the official recommendation from CMake themselves is to format
    by hand:
    https://gitlab.kitware.com/cmake/cmake/-/work_items/19959
---
 .pre-commit-config.yaml | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 64a6fa3d18..efcd8cd160 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -45,11 +45,6 @@ repos:
     hooks:
       - id: clang-format
         types_or: [c, c++]
-  - repo: https://github.com/cheshirekow/cmake-format-precommit
-    rev: e2c2116d86a80e72e7146a06e68b7c228afc6319  # v0.6.13
-    hooks:
-    - id: cmake-format
-      args: [--in-place]
   - repo: https://github.com/cpplint/cpplint
     rev: 350702a4d39395571bd118c9a3cff0a573488d61  # 2.0.2
     hooks: