anthropics / anthropics/claude-code-action

Logging tool permission errors somewhere ..

Abierto
#357 0 comentarios 1 reacción 0 asignados Ver en GitHub
enhancement p3
Lenguaje dominante
TypeScript
Estrellas
8.9k
Forks
2.1k
Merge medio
3 d 9 h
PR fusionados (30 d)
10

Descripción

I'm working in integrating this into an internal tool to help our teams get some extra insights into PRs ..
I'm seeing that the agent at times likes to invent creative ways of getting some information and decides to run various permutation of for example Bash commands ..
I'm trying to avoid just letting it run any Bash command, but I'd like to also get observability into when it tries to run a command, but it doesn't have the permissions to.

I already tried enabling otlp telemetry, and while the logs and metrics are interesting, they seem to only log "actually attempted" tool executions, and not those denied by "allowed_tools"

I know I can manually see the failed tools in the job execution summary, but I was hoping to hook up some monitors to this event so that we can react and evaluate if we should be allowing these additional tools on a per case basis.

Is there currently an easy way to hook .. anything .. I'd be happy if I can trigger a shell script when a tool is denied, I can then log an event about it or whatever ..

Also how much is this implementation specific to the GHA edition of claude code, should I also be filing a ticket against claude code itself to perhaps have a new event type be logged for denied tools?

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.