Refactor battery partitions to be able to generically add above/below partitions#179
Draft
TrentHouliston wants to merge 13 commits intomainfrom
Draft
Refactor battery partitions to be able to generically add above/below partitions#179TrentHouliston wants to merge 13 commits intomainfrom
TrentHouliston wants to merge 13 commits intomainfrom
Conversation
- Model layer: battery.md → energy-storage.md - Model layer: battery-balance-connection.md → energy-balance-connection.md - Device layer: battery_section.md → energy_storage.md - User guide: battery_section.md → energy_storage.md - Update all cross-references to use new filenames - Update terminology from 'section' to 'partition' throughout - Update mkdocs.yml navigation
- Add PartitionConfigSchema and PartitionConfigData TypedDicts - Support both new partition-based and legacy percentage-based configs - Refactor adapter to use _create_legacy_elements method - Add stub for _create_partition_based_elements method - Make min/max_charge_percentage optional with defaults for legacy support - Update __init__.py to export new partition types
- Add _create_partition_based_elements method - Support greedy bottom-up initial charge allocation - Create energy storage elements for each partition - Create internal node and connections with costs - Create balance connections between adjacent partitions - Apply early charge incentives on main connection
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
- Fix EnergyBalanceConnection to use reactive pattern (@constraint, @output, @cost) - Update Network.add() to validate and set partition references - Fix TimeSeriesLoader API calls (load -> load_intervals) - Fix grid translations (remove _mode suffix from field names) - Fix battery adapter partition loading (load_boundaries/load_intervals) - Fix ElementAdapter protocol (create_model_elements -> model_elements) - Update tests for reactive API - Fix linting issues (line length, dict comprehensions, __all__ sorting) - Update snapshots for scenarios
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.