codeant-ai-for-open-source[bot] commented on PR #38749:
URL: https://github.com/apache/superset/pull/38749#issuecomment-4092590854
## **Sequence Diagram**
This PR adds a new PreToolUse step that blocks git commands attempting to
bypass local hooks, then preserves the existing pre-commit execution for normal
commit commands. It ensures hook-skip attempts are stopped before git runs
while keeping commit checks in place.
```mermaid
sequenceDiagram
participant Agent
participant ClaudeHooks
participant BlockNoVerify
participant PreCommit
participant Git
Agent->>ClaudeHooks: Run Bash tool with git command
ClaudeHooks->>BlockNoVerify: Check command for hook bypass flag
alt Bypass flag detected
BlockNoVerify-->>ClaudeHooks: Reject command
ClaudeHooks-->>Agent: Block execution
else Command allowed
BlockNoVerify-->>ClaudeHooks: Allow command
opt Command is git commit
ClaudeHooks->>PreCommit: Run pre commit checks
PreCommit-->>ClaudeHooks: Checks complete
end
ClaudeHooks->>Git: Execute git command
Git-->>Agent: Return command result
end
```
---
*Generated by [CodeAnt AI](https://codeant.ai)*
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]