Skip to content

UI: Disable option to not save lifetime variables for PV-Battery systems. #2087

Merged
brtietz merged 4 commits into
patchfrom
SAM_2008
Jul 8, 2025
Merged

UI: Disable option to not save lifetime variables for PV-Battery systems. #2087
brtietz merged 4 commits into
patchfrom
SAM_2008

Conversation

@berg-michael

@berg-michael berg-michael commented Jun 30, 2025

Copy link
Copy Markdown
Collaborator

Description

SAM#2008 describes a bug in which deselecting the option to save lifetime variables in a PV-Battery simulation leads SAM to crash. The underlying cause of the crash is described more thoroughly in the SAM issue, but briefly, it is a heap corruption bug caused by the smaller, non-lifetime allocations being too small to compute figures for the battery in cmod_pvsamv1.cpp.

This fixes this issue on the UI side by preventing users from deselecting the option to save lifetime variables for PV-Battery systems. It also provides a brief warning why this option is disabled.

Fixes # (issue(s))
#2008

Corresponding branches and PRs:

ssc/SAM_2008

Unit Test Impact:

Tests shouldn't be impacted.

Checklist

  • requires help revision and I added that label
  • adds, removes, modifies, or deletes variables in existing compute modules
  • adds a new compute module
  • changes defaults
  • I've tagged this PR to a milestone

@brtietz brtietz requested review from brtietz and cpaulgilman July 1, 2025 14:48

@brtietz brtietz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This works, thanks for fixing! I expected an issue with Detailed-PV Battery Wind in the hybrid models, but because that's AC connected it doesn't trip the code of concern here.

Also align and resize degradation widgets.

@cpaulgilman cpaulgilman left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. I made some changes to the widgets for consistency. Thanks!

@cpaulgilman cpaulgilman added the requires help revision Requires a Help revision before releasing public version label Jul 2, 2025
@brtietz brtietz merged commit 2388947 into patch Jul 8, 2025
8 checks passed
@cpaulgilman cpaulgilman added this to the SAM 2025 release patch 1 milestone Jul 21, 2025
@cpaulgilman cpaulgilman added the added to release notes PR and/or issue has been added to release notes for a public release label Jul 24, 2025
cpaulgilman added a commit that referenced this pull request Jun 3, 2026
Also fix broken references in Electricity Load topic.
@cpaulgilman cpaulgilman removed the requires help revision Requires a Help revision before releasing public version label Jun 3, 2026
cpaulgilman added a commit that referenced this pull request Jun 9, 2026
… 2026 release (#2207)

* Remove wind cost model descriptions for #2154

* Fix help build issues

* Revise PV sizing topics for new PV UI design for #2135

* Clean up battery dispatch Help topics for #2115

* Revise Help for PVWatts detailed battery for #2113

* Update Help build instructions

* Consolidate battery Help topics

* Add description of load day of week input for #2109

Also fix Belpe annual growth rate widget overlap

* Revise degradation save lifetime outputs in Help for #2087

Also fix broken references in Electricity Load topic.

* Emphasis SRW is obsolete and fix format of weather file Help topics

* Add description of calculation to capacity payment Help topic.

* Revise Help for solar resource UI updates in #2120

* Clean up misc headings and broken links in Help

* Revise Help build instructions

* Fix broken welcome page Help link

* Revise Help for IPH system control copy TOD factors for #2024

Also fix TOU output fractions widget label for IPH "turbine output" to "heat sink output".

* Custom generation Help revisions for NatLabRockies/ssc#1384

* Clean up Help rates and load topics for NatLabRockies/ssc#1352
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

added to release notes PR and/or issue has been added to release notes for a public release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants