Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MtbEffector causes issues when interacting with dynManager.setState #850

Closed
atharris-work opened this issue Nov 15, 2024 · 1 comment · Fixed by #869
Closed

MtbEffector causes issues when interacting with dynManager.setState #850

atharris-work opened this issue Nov 15, 2024 · 1 comment · Fixed by #869
Assignees
Labels
bug Something isn't working

Comments

@atharris-work
Copy link

Describe the bug
High level: Importing MtbEffector causes calls to dynManager.setState to fail, likely due to a missing %include "swig_eigen.i" line in MtbEffector.i. This occurs whenever MtbEffector is imported, regardless of whether the module itself is called (perhaps another bug).

Low level: Importing MtbEffector seems to override other BSK modules that implement the dynamics engine (dynManager, stateObject, etc). In addition, MtbEffector.i lacks the call to SWIG that results in Eigen functions/datatypes being properly wrapped, leading to errors when MtbEffector is imported into code.

To reproduce
Steps to reproduce the behavior:

  1. Add import MtbEffector to scenarioHohmann.py
  2. Run the scenario normally
  3. See error; described in additional detail in this discussion

Expected behavior

  • Manually setting states through the dynManager should work in sims that include MtbEffectors
  • Importing a module that isn't used shouldn't break other modules.

Desktop (please complete the following information):

  • OS: Ubuntu 22.04
  • BSK Version: Develop on 11/8, commit a413b11
  • Python version: 3.10.12

Additional context

  • Adding %include "swig_eigen.i" to MtbEffector.i` resolves this issue.
  • Someone should look into why the dynamics engine is re-swigged for every individual effector/dynamics related class, and whether this is necessary (lower priority).
@schaubh
Copy link
Contributor

schaubh commented Nov 22, 2024

Mm, interesting. Wasn't aware of this behavior. Thanks for sharing.

@schaubh schaubh added the bug Something isn't working label Nov 27, 2024
@schaubh schaubh added this to Basilisk Nov 27, 2024
@schaubh schaubh moved this to 🏗 In progress in Basilisk Nov 27, 2024
@Natsoulas Natsoulas moved this from 🏗 In progress to 👀 In review in Basilisk Dec 9, 2024
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Basilisk Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants