Skip to content

Write SET string values unchanged instead of normalized#216

Open
DAdjadj wants to merge 1 commit into
bvanelli:mainfrom
DAdjadj:fix/action-set-preserves-strings
Open

Write SET string values unchanged instead of normalized#216
DAdjadj wants to merge 1 commit into
bvanelli:mainfrom
DAdjadj:fix/action-set-preserves-strings

Conversation

@DAdjadj

@DAdjadj DAdjadj commented Jul 12, 2026

Copy link
Copy Markdown

Closes #213

Action.run passed values being written through get_value(), which applies get_normalized_string (lowercase + NFD decomposition). That normalization matches Actual's behavior for condition comparison, but Actual's own rule engine preserves the original text when writing action values. As a result, a rule setting notes to #Groceries wrote #groceries (with decomposed accents for non-ASCII text), both on the transaction and on split children.

With this change, SET actions on string/imported_payee typed values write self.value as-is; all other types keep going through get_value() (date parsing, boolean to int, etc.). Condition comparison is untouched and stays case-insensitive, which the added test also covers.

Happy to adjust if you would rather normalize to NFC on write or handle it elsewhere.

get_value() applies get_normalized_string (lowercase + NFD
decomposition), which exists for condition comparison. Action.run was
also passing values being WRITTEN through it, so a rule setting notes
to '#Groceries' wrote '#groceries' with decomposed accents, on the
transaction and on split children. Actual's own rule engine preserves
the original text.

Closes bvanelli#213
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Action.run lowercases and NFD-decomposes string values written by SET rules

1 participant