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
Copy file name to clipboardExpand all lines: docs/changelog.md
+74-3Lines changed: 74 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,74 @@
1
+
# 0.13.0
2
+
3
+
- Engine updated to [**DSS C-API 0.13.0**](https://github.com/dss-extensions/dss_capi/releases/tag/0.13.0), which is very compatible with OpenDSS 9.6.1.1 (plus some official SVN commits up to rev 3595, plus our own changes.
4
+
-**New test suite,** which runs many more files and validates more of the API. We now use `pytest` for some more complex tests, while the numeric validation is done with the new `compare_outputs.py`.
5
+
-**New `DSS.AdvancedTypes`:** toggle matrix shapes and complex numbers in many of the properties and functions of the API. This is disabled by default.
6
+
-**New `DSS.CompatFlags`:** to address some concerns about compatibility, we added a few toggles to toggle behavior that matches the official OpenDSS more closely. This flags will be refined in later releases.
7
+
- Drop deprecated IR classes and a few undocumented functions.
8
+
- Use **more enums** throughout the code, which helps both readability and documentation. Some enums were complemented.
9
+
-**`DSS.AdvancedTypes`** toggle: enabling `AdvancedTypes` allows using **array/matrix shapes and complex numbers** as results from properties/functions in the API.
10
+
-**Plotting**: Implement several plot types. Only a few issues need to be addressed to consider the plotting system complete!
11
+
-**Notebook integration**: Initial prototype available. It is enabled automatically when `DSS.Plotting.enable()` is run in a notebook, providing integration with some DSS messages and outputs.
12
+
- It also registers the **`%%dss` cell magic**. Use it in a cell to run DSS-language code directly. We found it useful for exploration and learning.
13
+
- Updated `patch_dss_com` to patch a few more classes.
14
+
- Drop Python 3.6 support, include 3.11 officially in the tests.
15
+
-**DSSContext disposal:** use CFFI to track the disposal of the contexts instead of manually tracking. This could remove memory leaks if you application creates too many DSSContexts (which is not recommended).
16
+
-**DSS.Obj:** remove some redundant properties, fix several issues. While it's not complete yet (some known limitations), you can see the tests for a few examples of how to create circuits without .DSS scripts/files in [tests/test_obj.py](https://github.com/dss-extensions/dss_python/blob/master/tests/test_obj.py) and [tests/test_batch.py](https://github.com/dss-extensions/dss_python/blob/master/tests/test_batch.py) -- the first creates each object explicitly, while the second uses batch operations to fill properties from arrays and lists.
17
+
- Add `typing_extensions` as a dependency to address Python typing needs in the main API code and the new Obj API.
18
+
- Docs: mark more properties as "**(API Extension)**".
19
+
- Internal code refactoring and clean-up.
20
+
21
+
## DSS C-API 0.13.0 changes
22
+
23
+
[**check its repo for more info**](https://github.com/dss-extensions/dss_capi/)
24
+
25
+
- Clean-up several files to ease the transition from Pascal to C++; more enum usage, remove redundant internal properties, rename some class members, etc. Some final steps still remain (that work is done in private branches).
26
+
- Fixes a couple of minor memory leaks.
27
+
- Removed our old *Legacy Models* mechanism. Right now, the API functions still exist, but will have no effect when setting and will throw an error. For a future version, the functions will be removed. This toggle was introduced in 2020, some time after the removal of the legacy models in the official OpenDSS. We believe users had enough time to fully migrate and the extra maintenance burden is not justified anymore.
28
+
- Transition some deprecated and buggy properties to throw specific errors, instead of generic messages. Issue: https://github.com/dss-extensions/dss_capi/issues/118
29
+
-`Export` command: When the user provides a filename, use it as-is, otherwise could be an invalid path in case-sensitive file systems (e.g. Linux, most likely).
30
+
-`Dump` and `Save` commands: in some cases, our internal "hybrid enums" were not being converted correctly for dumps. A few classes had incomplete dump implementations since v0.12.0; some strings needed to be escaped for correct output.
31
+
- CtrlQueue: adjust string formatting of items; although this doesn't affect the numeric results, the strings from the queue had some truncated numbers.
32
+
- Property system: For compatibility with the official version, allow autoresizing some arrays when given conflicting number of elements through the text interface or scripts.
33
+
-`Like` property: Although not recommended and [deprecated in the official OpenDSS](https://sourceforge.net/p/electricdss/discussion/861977/thread/8b59d21eb6/?limit=25#b57c/f668), the sequence of properties filled in the original copy is also copied. If you use `Like`, remember to check if the copy actually worked since some classes are known to not copy every property correctly.
34
+
- Plotting and UI: The engine side plotting callback system is now complete. There are fixes for `DaisyPlot` and `GeneralDataPlot`, especially multi-platform handling. Changed how some properties are exposed in the JSON interchange to the callbacks. Implement argument handling and callback dispatch for `DI_Plot`, `CompareCases` and `YearlyCurves`.
35
+
-`New` commands: Fix potential issue with null pointers and duplicate names when `DuplicatesAllowed=False`.
36
+
- EnergyMeter: Fix error message when the metered element is not a PDElement.
37
+
- CIMXML export: Fix issues present since v0.12.0; reported in https://github.com/dss-extensions/OpenDSSDirect.py/issues/121
38
+
- Parser: properly error out when given excessive number of elements for matrices; implemented due to the report in https://github.com/dss-extensions/OpenDSSDirect.py/issues/122
39
+
- Port most changes from the official OpenDSS up to SVN revision 3595 (OpenDSS v9.6.1.1 + a couple of CIMXML updates); check [OpenDSS v9.6.1.1 README.txt](https://sourceforge.net/p/electricdss/code/3595/tree/trunk/Version8/README.txt) for some complementary info to the list below.
40
+
- Relay, UPFC, UPFCControl changes ported.
41
+
- CIMXML exports: Various updates.
42
+
- RegControl: More log and debug trace entries.
43
+
- LoadMult: Set `SystemYChanged` when changing `LoadMult`**through a DSS script or DSS command** (doesn't affect `Solution_Set_LoadMult`)
44
+
- Port PVSystem, Storage, InvControl, and StorageController changes, including the new grid-forming mode (GFM). For DSS Extensions, we added a new class InvBasedPCE to avoid some redundancy and make things clearer.
45
+
- Port DynamicExp and related functionality. In our implementation, we also add a new class DynEqPCE to avoid some redundant code (could still be improved). the Generator and the new InvBasePCE derive from this new DynEqPCE. **Note**: the `DynamicEq` functionality from the upstream still seems incomplete and some things are not fully implemented or maybe buggy, so we only ported now to remove the burden of porting this down the line. If you find issues, feel free to report here on DSS Extensions, but we recommended checking first with the official OpenDSS -- if the issue is also found in the official version, prefer to report in the official OpenDSS forum first so everyone gets the fixes and our implementation doesn't diverge too much.
46
+
- CktElement/API: add a few new functions related to state variables.
47
+
- Circuit, Line: port the `LongLineCorrection` flag now that it seems to be fixed upstream. Note that we didn't publish releases with the previous buggy version from the upstream OpenDSS (that applied the long-line correction for everything).
48
+
- LineSpacing: port side-effect from upstream; changing `nconds` now reallocates and doesn't leak previously allocated memory. Not a common operation, so it's not very relevant.
49
+
- CktElement: port code for handling losses in AutoTrans
50
+
- Other API updates:
51
+
- DSSContext API: allow `null` pointer for the prime/default instance. This should ease the transition. Issue: https://github.com/dss-extensions/dss_capi/issues/119
52
+
- Error API: add `Error_Set_Description` to allow easier setting an error message from callbacks (this is for advanced usage)
53
+
- Batch and Obj API:
54
+
- For a couple of fast-path operations, add checks for edit state, automatically issuing `BeginEdit` and `EndEdit` for the objects in the batch.
55
+
- Allow passing strings (object names) instead of pointers for object references
56
+
- Automatically add new elements to the current DSSContext (since we have not yet published a manipulation API)
57
+
- For symmetric matrices, if the user passes only the triangle, follow the same convention as the Text interface. Includes specific fix for (parts of) complex matrices (like the R or X matrices when internally Z is stored). If the user provides full matrices, the previous behavior was correct, no changes required.
58
+
-`Fuses_Reset`: fix C header (remove extra/unused parameter)
59
+
-`Fuses_Get_State` and `Fuses_Get_NormalState`: add missing string copy. Sometimes this could cause memory corruption.
-`Monitors_Get_dblHour`: For harmonics solution, return empty array. Previously, it was returning a large array instead of a single element (`[0]`) array. A small issue adjusted for compatibility with the official COM API results.
64
+
-`Reactors_Set_Bus1`: Match the side-effects of the property API for two-terminal reactors.
65
+
- New `DSS_Set_CompatFlags`/`DSS_Get_CompatFlags` function pair: introduced to address some current and potential future concerns about compatibility of results with the official OpenDSS. See the API docs for more info.
66
+
- New `DSS_Set_EnableArrayDimensions`/`DSS_Get_EnableArrayDimensions`: for Array results in the API, implement optional matrix sizes; when setting `DSS_Set_EnableArrayDimensions(true)`, the array size pointer will be filled with two extra elements to represent the matrix size (if the data is a matrix instead of a plain vector). For complex number, the dimensions are filled in relation to complex elements instead of double/float64 elements even though we currently reuse the double/float64 array interface. Issue: https://github.com/dss-extensions/dss_capi/issues/113
67
+
68
+
Note that a couple of SVN changes were ignored on purpose since they introduced potential issues, while many other changes and bug-fixes did not affect the DSS C-API version since our implementation is quite different in some places.
69
+
70
+
71
+
1
72
# 0.12.1
2
73
3
74
- Expose `Storages` in Python
@@ -6,7 +77,7 @@
6
77
7
78
# 0.12.0
8
79
9
-
- Removed CmathLib: not useful in Python or most programming languages targetted by DSS Extensions.
80
+
- Removed CmathLib: not useful in Python or most programming languages targeted by DSS Extensions.
10
81
- Allow creating multiple DSS engine instances via `DSS.NewContext()`.
11
82
- Reenabled Parallel interface and PM functions (actors and so on), based on a new implementation.
12
83
- Enable incremental Y matrix options -- controlled by `DSS.YMatrix.SolverOptions`, options listed in `SparseSolverOptions`.
@@ -29,7 +100,7 @@ This version still maintains basic compatibility with the 0.10.x series of relea
29
100
- The code was finally unified, merging remaining features from OpenDSS v8+ (with few exceptions). Most of the DSS PM commands and functions were enabled. To achieve this, most of the global variables from the OpenDSS engine were encapsulated in a new class, a DSS Context class. Multi-threaded features are based on DSSContexts, both the original OpenDSS PM features and new extensions.
30
101
- Using DSS Contexts, user threads are now possible.
31
102
- Initial ARM64/AARCH64 support added. ARM32 building scripts were also added. Support includes Apple M1 support, including parallel/multi-threading features.
32
-
- Finally use KLUSolveX (our KLUSolve fork, rewritten and extended), enabling incremental Y updates for transformers and capacitor banks. **Documentation including usage notes and limitations still not written.** This was planned for version v0.13, but momved back to v0.12 to enable ARM32 (armv7l) support and better results in ARM64 (aarch64).
103
+
- Finally use KLUSolveX (our KLUSolve fork, rewritten and extended), enabling incremental Y updates for transformers and capacitor banks. **Documentation including usage notes and limitations still not written.** This was planned for version v0.13, but moved back to v0.12 to enable ARM32 (armv7l) support and better results in ARM64 (aarch64).
33
104
- Experimental callbacks for plotting and message output. Expect initial support in Python soon after DSS C-API v0.12 is released.
34
105
- Introduce `AllowChangeDir` mechanism: defaults to enabled state for backwards compatibility. When disabled, the engine will not change the current working directory in any situation. This is exposed through a new pair of functions
35
106
`DSS_Set_AllowChangeDir` and `DSS_Get_AllowChangeDir`, besides the environment variable `DSS_CAPI_ALLOW_CHANGE_DIR`.
@@ -106,7 +177,7 @@ DSS C-API 0.10.7 changes:
106
177
107
178
DSS C-API 0.10.6 changes:
108
179
109
-
- This version should be fully API compatible with 0.10.3+. The behavior of some functions changed with the new extensions. Especially, empty strings are explicitely return as nulls instead of "\0". This conforms to the behavior already seen in arrays of strings.
180
+
- This version should be fully API compatible with 0.10.3+. The behavior of some functions changed with the new extensions. Especially, empty strings are explicitly return as nulls instead of "\0". This conforms to the behavior already seen in arrays of strings.
110
181
- The binary releases now use Free Pascal 3.2.0. We observed the solution process is around 6% faster, and results are even closer to the official OpenDSS.
111
182
- The releases now include both the optimized/default binary and a non-optimized/debug version. See the [Debugging](https://github.com/dss-extensions/dss_capi/blob/0.10.x/docs/debug.md) document for more.
112
183
- Extended API validation and **Extended Errors** mechanism:
0 commit comments