Skip to content

Conversation

@nicopop
Copy link
Contributor

@nicopop nicopop commented Jan 6, 2025

while testing for my YamlCompare req rule (ill do another pr soon)
I noticed that whenever a requirement function cause an exception its not that clear where/what function caused said error unless actively debugging (which is not something most of the devs will do)
to do this I added a try except with a custom message that tell exactly in what area the function was called.
image
before this it would jump to the green part of the image
I also changed the recusion test from >= to > so it make more sense with existing error message

I know line 143 of rules.py look weird but in fstring the way to escape {} is to double them
like so "{{{func_name}({item[1]})}}" become this in output: {func_name(item[1])}

@nicopop nicopop self-assigned this Jan 6, 2025
@silasary silasary merged commit 3d3dd67 into main Jan 12, 2025
@silasary silasary deleted the req-function-tweaks branch January 12, 2025 04:52
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.

4 participants