Debugs no longer working

After the latest update a previously configured debug handler no longer seems to be working.

sensuctl handler create debug-check --type pipe --command “cat | python3 -m json.tool > /var/log/sensu/debug-check.json”
sensuctl check set-handlers check-path debug-check
sensuctl handler create debug-check-inf --type pipe --command “cat | python3 -m json.tool > /var/log/sensu/debug-check-inf.json”
sensuctl check set-handlers check-path-inf debug-check-inf

So i just tried to reproduce the problem and I wasn’t able to running sensu-backend 6.1.1.

I created a simple check-path check set it to unpublished and made sure it was part of a subscription for an entity that was active.

I then created debug-check handler and added it to the check’s handlers as per your steps.

I then executed the check manual with sensuctl check execute check-path and the log file was populated as I expected.

So a couple of things for you to look at while diagnosing.

  1. is the agent you expect to run the check actually running?
  2. You’ll want to check the sensu-backend log for errors. On a systemd based linux system something like journalctl -u sensu-backend --since="1 days ago" |grep debug-check

I note on the backend log. You may want to put the backend in to debug log level while you diagnose the problem so you can see the all the messages indicating that the backend executed the handler.
Ex of ‘info’ level sensu-backend msg from my journalctl output indicating handler executed:

Oct 23 09:59:33 carbon sensu-backend[305930]: {"assets":null,"check":"check-paths","component":"pipelined","entity":"carbon-f31","event_uuid":"c4211805-8c33-469b-b6ef-49b48e3dc90a","handler":"debug-check","level":"info","msg":"event pipe handler executed","namespace":"default","output":"","status":0,"time":"2020-10-23T09:59:33-08:00"}

If you have something like a directory/file permissions error not letting you write the file, the backend should log that as an error msg.

Here is the vagrant config I’m using if you’d like to see it as I have it currently configured

All working, it was a typo in the end, thank you fo your time.