Integers should be accepted as floats
Open
Nobody has claimed this yet.
help wanted
- Dominant language
- EmberScript
- Stars
- 26
- Forks
- 68
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 1
Description
Bug report
Required Info:
- Operating System: Ubuntu 22.04
- Installation type: binary
- Version or commit hash: 0.15.0
- DDS implementation: cyclonedds
- Client library (if applicable): rclpy
Steps to reproduce issue
- Define a message with a float field
- Try to assign an integer to the field.
Expected behavior
The integer should be automatically casted to a float.
Actual behavior
You manually have to cast the integer to float, otherwise you get the error message AssertionError: The 'x' field must be of type 'float.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the assignment through the rclpy client library with a message containing a float field. Inspect the generated Python message field validation and identify where integer values are rejected. Done means integer assignment is accepted as a float without the reported AssertionError, with regression coverage for the behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100