Repository navigation
Add a staff-only karma command for a ckey - #117
Merged
Merged
Conversation
<key>karma <ckey> (Ambassador, Admin) reads the Civ13 coordinator's per-ckey karma snapshot (<group root>/shared-records/karma/<ckey>.json) and shows the admin standing, playtime, kindly/poorly counts and the heaviest givers with their standing, hours, admin-notes flag and warning flags. It answers only in the staff_bot channel or a DM, since karma is hidden from players. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016WTP2Tn9GrJ9LZtL9UmHVY
|
Caution Review failedThe pull request is closed.
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Requested by Val · project thread
What
<key>karma <ckey>(Ambassador, Admin) shows a player's hidden karma from Civ13's planned karma system: admin standing, playtime (alive, awake and connected), kindly/poorly counts raw and weighted, and the heaviest givers with their own standing, hours, admin-notes flag and warning flags (burst, shared connection, low weight, giver banned). A verified Discord ID resolves to its ckey, likeckeyinfo.staff_botchannel or a DM and refuses everywhere else.<group root>/shared-records/karma/<ckey>.json, which the Civ13 coordinator will write per ckey on every change (same pattern asactivityreadingplayer-activity-weekly.json). Every field is validated and text is stripped of mentions and markdown.Status
The Civ13 side that writes the snapshot is not built yet, so until it lands the command answers "No karma for
ckey: no karma recorded for that ckey." Merging this is harmless on its own.Tests
php tests/local/karma-snapshot.php: PASS (place rule, ckey validation, missing/broken/mismatched/oversized files, field filtering, sorting, cut-off, mention and markdown stripping)php -lon the new class, the command andMessageServiceManager.php: no syntax errorsstatus-heartbeatworkflow beside the activity test.Not verified: a live Discord run.
Generated by Claude Code