You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
User keyword type conversion between int/float and bool not working correctly #5630
Type conversion for user keyword arguments does not handle bool to int/float correctly. For example, Log As Int ${FALSE} yields False (bool) instead of 0 (int).
Expected Behavior
When a keyword parameter is typed as int, passing ${FALSE} should convert to 0, not keep the bool value.
I agree that it would make sense if integer conversion would convert Boolean values to actual integers. In Python isinstance(True, int) is true, but it is generally considered a mistake and it's less surprising for our users if keywords having arguments like arg: int actually get integers, not Boolean values.
Could you clarify what kind of changes you are planning for float conversion? The title and description talks about int/float conversion, but your examples and also the PR ignore floats altogether.
On a quick code changes in the PR look good, but test or tests are needed and documentation should possibly be updated.
Finally, notice that this is not only about user keyword argument conversion. We use the same conversion logic everywhere.
Activity
themavik commentedon Mar 19, 2026
Fix submitted in #5631.
pekkaklarck commentedon Mar 20, 2026
I agree that it would make sense if integer conversion would convert Boolean values to actual integers. In Python
isinstance(True, int)is true, but it is generally considered a mistake and it's less surprising for our users if keywords having arguments likearg: intactually get integers, not Boolean values.Could you clarify what kind of changes you are planning for float conversion? The title and description talks about int/float conversion, but your examples and also the PR ignore floats altogether.
On a quick code changes in the PR look good, but test or tests are needed and documentation should possibly be updated.
Finally, notice that this is not only about user keyword argument conversion. We use the same conversion logic everywhere.