cc: implement new DiagnoseCCTriggers command #1712
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Review commit-by-commit.
Add a new debug command,
DiagnoseCCTriggers
, that lists all custom commands triggering on its input and identifies potential issues. The intent is for support members to instruct users to runDiagnoseCCTriggers
in the event of custom commands not triggering as the user expects; we can also consider adding a note in the documentation and/or control panel pointing to this command where appropriate.Sample output:
![output from running the DiagnoseCCTriggers command](https://private-user-images.githubusercontent.com/56809242/354704599-56952190-699e-4e70-99a3-280d77f80d45.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkwODUyMTIsIm5iZiI6MTczOTA4NDkxMiwicGF0aCI6Ii81NjgwOTI0Mi8zNTQ3MDQ1OTktNTY5NTIxOTAtNjk5ZS00ZTcwLTk5YTMtMjgwZDc3ZjgwZDQ1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMDklMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjA5VDA3MDgzMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTdjYmY0YjZkZGM3MWUzMTgwYmIyZmJjNzEzNTUxODQ0MGVhMjZjZjI2OGQ4ZTJjMmEyMDBlYTc3M2FiY2YzMjMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.FfCUrS2MyV_PQh1tqyrImWdA0TvraVr8kNWo15aWkGc)
To implement
DiagnoseCCTriggers
, some light refactoring to enable code reuse was necessary (see first 3 commits.)In the server, Henri proposed that, instead of a command, a control panel warning could be generated when there are conflicting triggers. Though such a warning would definitely be more discoverable, it is difficult to implement--requiring significantly more code than this PR--and near-impossible to make as robust as a command, so it would not catch all cases.) So we stick with the command here.