test: cover lact.lua's standalone formatting/parsing - #2
Merged
Merged
Conversation
Covers the optional LACT Waybar module (HyDE-Project/HyDE, feat/lact-wrapper-v2, not yet opened as a PR): lact.lua's formatting/parsing logic, standalone from gpuinfo.lua by design (see the branch's own commit messages). Checks malformed, missing, negative, and out-of-range LACT daemon values all degrade to valid Waybar JSON instead of crashing the module. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01X1SjbyvkBXwHm4ZprDQc93
Contributor
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 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. Comment |
3 tasks
Covers HyDE-Project/HyDE#2096's fix for a real gap CodeRabbit found: generate_json() concatenated vendor/family/primary_gpu strings straight into the tooltip, which Waybar renders as Pango markup (custom/lact.jsonc doesn't set "escape": true). A raw '<', '>' or '&' in any of those would corrupt the markup instead of rendering literally. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01X1SjbyvkBXwHm4ZprDQc93
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.
Summary
lact.lua's standalone formatting/parsing logic (independent ofgpuinfo.luaby design): malformed, missing, negative, and out-of-range LACT daemon values must all degrade to valid Waybar JSON instead of crashing the module.Test plan
bash test_lact_wrapper.shpasses against the reallact.lua(verified with the tests dir alongside the HyDE checkout, matching the submodule layout)