lanl-ansi / PowerModelsDistribution.jl

A Julia/JuMP Package for Unbalanced Power Network Optimization
https://lanl-ansi.github.io/PowerModelsDistribution.jl/stable/
Other
146 stars 43 forks source link

[BUG] Type :status => Int should be enum in _eng_model_dtypes #465

Closed John-Boik closed 1 month ago

John-Boik commented 3 months ago

I'm not sure exactly how _eng_model_dtypes is used, but it appears that the last line in the example below should be an enum (e.g., ENABLED) rather than an Int. The example is for the key :bus, but an Int status is also used in other keys of this dictionary.

"Data types of accepted fields in the engineering data model"
const _eng_model_dtypes = Dict{Symbol,Dict{Symbol,Type}}(
    :bus => Dict{Symbol,Type}(
        :status => Int,

Similarly, the type for transformer configuration should be an enum, not String, and the type for load model should be enum and not String.