fix(csv): accept decoded time drum units in round-trip#14
Open
GruppoVeneta wants to merge 9 commits into
Open
Conversation
Owner
|
Thanks! I’ll take a look at this in the next day or so and probably merge. |
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
Allow CSV parsing and writer round-trip validation to accept every time-drum unit that the binary decoder can already emit (
Tms,Ts,Tm,Th, andTd).Previously,
parse_af_call()validated units against_TIME_FC, which only contains the units whose binary function codes are currently implemented. As a result, exporting a CLICK program containing a time drum in seconds, minutes, or hours failed during CSV round-trip validation with:The CSV parser does not build a binary blob, so it now validates against
_DRUM_UNIT_TO_INDEX. Binary encoding remains conservative:_compute_func_codes()still rejects units without known function codes.Tests
Ts,Tm, andTh.git diff --check: passed.The issue was reproduced from a real CLICK program export using ClickNick 0.19.3 / laddercodec 0.1.8.