-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
parsing error of transformer xhl vs x12 parameters in circuit.ToJSON() #101
Comments
It looks like the problem is a bit worse. It appears that Also, the same problem appears in OpenDSSDirect.py and dss_python versions. And the problem is not in the |
Looks like you found a corner-case bug, but it's the other way around --
Zero should not be allowed for On the OpenDSS GUI, it will give a warning popup about the zero value, but still replace the value. When running through the official COM DLL with AllowForms=false (the typical scenario for automation with the official OpenDSS), users don't see the warning and the behavior matches what happens here on DSS-Extensions. Nowadays, on DSS-Extensions, it might be a better idea to adjust that to generate a proper error when 0 is used as input, adding a compatibility flag to restore the current/legacy behavior. Same idea for read-only properties (OpenDSS silently ignores writing to those). I'll make changes according to this. Redundant properties/fields (search for "redundant" in https://dss-extensions.org/dss-format/Transformer.html ) such as synonyms are omitted from the JSON output, so Also note that (
Yeah, all projects here share the same engine, it wouldn't make sense to group these in the same GitHub org and have them behave differently. The general behavior should be very close across all programming languages we support. There will be an option to use the official engine in the next release of DSS C-API, but it will be quite limited -- none of our extended functionality at engine level, and initially only supporting Windows since it's supported by EPRI at the moment. |
I'm not sure if this is the right repository to report this problem, but it looks like the circuit.ToJSON function of OpenDSSDirect will ignore transformer parameters xhl, xht, and xlt, thus setting these parameters to their default values. But it will recognize the alternative versions of the parameters, x12, x13, and x23.
An example DSS file comes from the test sets of PowerModelsDistribtion, given below. Saving this as a file and using the script below to generate a JSON object, the object has default values for xhl, xht, and xlt of transformer [1], rather than zeros. Changing the DSS file to use x12=0, x13=0, and x23=0 instead results in a JSON object with the correct (zero) values.
Julia Script, where the DSS file is saved as filename.dss:
DSS script:
The text was updated successfully, but these errors were encountered: