fast-aircraft-design / FAST-OAD

FAST-OAD: An open source framework for rapid Overall Aircraft Design
GNU General Public License v3.0
47 stars 25 forks source link

Mission viewer update_layout #549

Open Mokyoslurp opened 2 months ago

Mokyoslurp commented 2 months ago

This PR adds a method to update the mission viewer layout before displaying it.

christophe-david commented 2 months ago

Thanks for the proposal. Before proper reviewing, I would want to ask if adding a method is required. The existing display() method has no argument, and could have the parameters of your new method (with proper naming please, no dict1 allowed 😉), especially since none of them is mandatory. Also, did you check the unit tests locally? As you can see, they failed in the GitHub workflow.

Mokyoslurp commented 1 month ago

You are right, this could be done directly in display method. The way I did it is a copy of plotly's workflow (update then display), so that I could factorize some code with other plots. The method signature is a pure copy of plotly's (they have that dict1) but I agree this is a bad naming. Tests are buggy on my VScode for some reason so I wasn't able to run all of them automatically