nasa / fprime-tools

F´ Python tooling and helpers.
https://github.com/nasa/fprime
Apache License 2.0
20 stars 38 forks source link

Remove restrictions for the Build class to setup its platform #216

Open weggert2 opened 2 weeks ago

weggert2 commented 2 weeks ago

Which allows users to call fprime-util generate several times without faiure

Related Issue(s) https://github.com/nasa/fprime/issues/2869
Has Unit Tests (y/n) yes
Documentation Included (y/n) yes

Change Description

Removes restrictions on calling Build.invent and Build.__setup_default more than once. I admit I don't understand the full implications of this, so I'd encourage the author @LeStarch to evaluate whether this breaks things. Anecdotally, locally installing this allows me to call generate in my fprime project several times without error.

Rationale

Fixes a (perceived) bug that fprime-util generate should not fail if a cache already exists

Testing/Review Recommendations

There is a very simple included unit test that shows that calling Builder.invent() twice does not raise an assertion. Please let me know what else I need to test.