Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release notes

## Unversioned

### Bugfixes

* Fix a bug in which field names for the capacities of a `Storage` node resulted in error message for the investment data checks.

## Version 0.9.3 (2025-10-23)

## Bugfixes
Expand Down
10 changes: 6 additions & 4 deletions ext/EMIExt/checks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,16 @@ function EMB.check_node_data(
return
end

for cap_fields ∈ fieldnames(typeof(data))
sub_data = getfield(data, cap_fields)
cap_map = Dict(:charge => charge, :level => level, :discharge => discharge)

for (cap, cap_fun) ∈ cap_map
sub_data = getfield(data, cap)
isnothing(sub_data) && continue
check_inv_data(
sub_data,
EMB.capacity(getproperty(n, cap_fields)),
EMB.capacity(cap_fun(n)),
𝒯,
" of field `" * String(cap_fields) * "`",
" of field `" * String(cap) * "`",
check_timeprofiles,
)
end
Expand Down