fix: error rows written to wrong file and default sensors mismatch - #5
Conversation
Error rows used ${device//://} which replaces colons with slashes,
creating nested directories instead of writing to the same file as
normal data. The initial fix (removing colons) could cause
collisions — e.g. 0000:03:00.0 and 0000:030:0.0 both produce
000003000.0.csv. Using underscores (${device//:/_}) produces
0000_03_00.0.csv which is both unique and reversible.
Update the post-process filename parser to use the simpler
replace('_', ':') instead of the regex-based approach.
Closes: #4
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Updated per review feedback:
Force-pushed a single clean commit. |
atheurer
left a comment
There was a problem hiding this comment.
File path fix looks good — colon→underscore is the right choice and the post-process reverse mapping is cleaner.
One note: the PR description mentions aligning default sensors from 1,2,6,127 to 1,2,6, but I don't see that change in the diff. Was it dropped or is it planned for a separate PR?
Apparently 127 is a valid sensor and the documentation was lacking so it remains. |
Summary
${device//://}(colon→slash, creating nested dirs) while normal rows used${device//:}(remove colons). Data went to different files.1,2,6,127but README and all usage examples document1,2,6. Sensor 127 is not a valid MVCR sensor index.Note: the Jira ticket also flagged the CDM metric class as potentially wrong (
countvspower), but investigation showscountis correct per the CDM specification — power watt readings are a gauge/level measurement which falls undercount.tool-powerusingpowermay itself be a bug.Closes #4
Test plan
1,2,6🤖 Generated with Claude Code