Skip to content

Recorder not working in unit test #1097

@Will-Schwend

Description

@Will-Schwend

Describe the bug
When utilizing a recorder for an output message for a new module the times method produces an error and one of the data fields in the message produces uninitialized values after the initial time step.

To reproduce
Steps to reproduce the behavior:

  1. Pull the branch feature/Mujoco-System-Mass-Matrix
  2. Run: python src/simulation/mujocoDynamics/MJSystemMassMatrix/_UnitTest/test_MJSystemMassMatrix.py
  3. Terminal will output first the last instance of the massMatrixOutMsg.MassMatrix message which contains the correct values, the next value printed is the number of spacecraft hub degrees of freedom which works properly, the third output is the values from the recorder attached to the massMatrixOutMsg that correspond to the correct values shown as the first output.
  4. To produce the error associated with the recorder times uncomment line 275 in the test script.

Expected behavior
The values in the recorder should match the values in from reading the message at each timestep.

Screenshots
Mass Matrix Recording Errors:

Image

Error when accessing times data in recorder:

Image

Desktop (please complete the following information):

  • OS: macOS
  • Version 15.6.1
  • Python version 3.11.9

Additional context
N/A

Metadata

Metadata

Labels

bugSomething isn't working

Type

Projects

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions