You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Another sub-issue of #1134 but this one is distinct enough to get its own issue: certain fields are units system-dependent in some structs but not in others. For instance, the result of get_active_power is units system-dependent in ThermalStandard:
making it frustrating to try to write polymorphic code that does the right thing for both.
As an incremental fix before the #1134 overhaul, I propose we work towards the principle that each getter function (a) either performs conversion for all types or does not perform conversion for any types and (b) clearly states which of these it is in its docstrings.
The text was updated successfully, but these errors were encountered:
Update from synchronous discussion: there is a nuance here in that Source doesn't have a base power, so it cannot report quantities in device base units. @rodrigomha will add a base power field to Source.
Another sub-issue of #1134 but this one is distinct enough to get its own issue: certain fields are units system-dependent in some structs but not in others. For instance, the result of
get_active_power
is units system-dependent inThermalStandard
:PowerSystems.jl/src/models/generated/ThermalStandard.jl
Line 147 in 71b9bf4
but not in
Source
:PowerSystems.jl/src/models/generated/Source.jl
Line 105 in 71b9bf4
making it frustrating to try to write polymorphic code that does the right thing for both.
As an incremental fix before the #1134 overhaul, I propose we work towards the principle that each getter function (a) either performs conversion for all types or does not perform conversion for any types and (b) clearly states which of these it is in its docstrings.
The text was updated successfully, but these errors were encountered: