Skip to content

Fix formatting JSON export via PVSystem.payload_to_file - #45

Merged
iantsednv merged 15 commits into
mainfrom
bugfix/fix-formatting-json-export-via-PVSystem
Oct 19, 2026
Merged

iantsednv merged 15 commits into
mainfrom
bugfix/fix-formatting-json-export-via-PVSystem

Conversation

@javlor

@javlor javlor commented Oct 13, 2026

Copy link
Copy Markdown
Collaborator

Fix formatting of JSON export via PVSystem.payload_to_file() to have the correct multi-line formatting and indentation.

@javlor
javlor requested a review from iantsednv October 13, 2026 14:31
iantsednv and others added 12 commits October 16, 2026 12:46
Always rebuild the payload from current plant configuration, avoiding stale payloads after edits. Store the last built or sent JSON for inspection, but omit it from saved configurations.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep unset derived inputs as None and resolve them from final plant settings on a copy during payload construction and description. This makes the documented assign-after-construction workflow order-independent and prevents design calculations from overwriting the user's capacities or GCR.

Reduce __setattr__ to enum coercion and remove hidden auto-fill tracking.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Document case-insensitive enum inputs, build-time derived defaults, and output-only payload behavior. Widen the enum field annotations to include string inputs and record the compatibility changes in the changelog.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Fix inverter efficiency formatting in set_inverter_from_rcl error

* Add regression test for set_inverter_from_rcl efficiency formatting

Cover the "Narrow your search" ValueError raised when multiple inverters
match, asserting efficMax is listed as a percentage (eff=98.6%) rather
than scaled by 100.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

* Add changelog entry for set_inverter_from_rcl efficiency fix

Also strips a trailing space on an existing 0.7.0 entry, as enforced by
the trailing-whitespace pre-commit hook.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Ian Tse <ian.tse@dnv.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…data-types-naming

Feature/allow flexibility data types naming
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@iantsednv
iantsednv merged commit 605471e into main Oct 19, 2026
14 checks passed
@javlor
javlor deleted the bugfix/fix-formatting-json-export-via-PVSystem branch October 21, 2026 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants