OpenMDAO / dymos

Open Source Optimization of Dynamic Multidisciplinary Systems
Apache License 2.0
195 stars 64 forks source link

Fixed an issue where matplotlib was not required to install dymos without specifications but would fail to import. #1035

Closed robfalck closed 6 months ago

robfalck commented 6 months ago

Summary

There were some "bare" imports of matplotlib in the dymos source code that would be executed when import dymos was invoked. Since basic dymos usage doesn't require matplotlib, it was not listed as a prerequisite except when a modifier like pip install dymos[tests] were used.

These bare imports have been moved into more local scopes where they will cause import errors if those particular methods or functions are invoked, but importing dymos will proceed without issue.

Related Issues

Backwards incompatibilities

None

New Dependencies

None

coveralls commented 6 months ago

Coverage Status

coverage: 92.075% (-0.2%) from 92.294% when pulling 524e8bfe55d2fcb04a0d9d4c57cbae82360316bc on robfalck:i1025 into 8afa8ecba001396989b607eb312feb138278e491 on OpenMDAO:master.