Skip to content

Conversation

@FBumann
Copy link
Member

@FBumann FBumann commented Jan 5, 2026

  • sel() → use transform.sel()
  • isel() → use transform.isel()
  • resample() → use transform.resample()
  • plot_network() → use topology.plot()
  • start_network_app() → use topology.start_app()
  • stop_network_app() → use topology.stop_app()
  • network_infos() → use topology.infos()
  • _dataset_sel(), _dataset_isel(), _dataset_resample(), _resample_by_dimension_groups() → use TransformAccessor class methods

Parameters removed:

  • normalize_weights from create_model(), build_model(), optimize()

Files updated:

  • flixopt/flow_system.py - removed deprecated methods
  • flixopt/optimize_accessor.py - removed normalize_weights parameter
  • flixopt/optimization.py - removed normalize_weights from Optimization classes
  • tests/test_*.py - updated to use new APIs
  • CHANGELOG.md - documented removals

Still deprecated (for v7.0.0):

  • Optimization, SegmentedOptimization, Results, SegmentedResults classes - these are kept as they don't affect loading old solutions/flow_systems

Description

Brief description of the changes in this PR.

Type of Change

  • Bug fix
  • New feature
  • Documentation update
  • Code refactoring

Related Issues

Closes #(issue number)

Testing

  • I have tested my changes
  • Existing tests still pass

Checklist

  • My code follows the project style
  • I have updated documentation if needed
  • I have added tests for new functionality (if applicable)

  - sel() → use transform.sel()
  - isel() → use transform.isel()
  - resample() → use transform.resample()
  - plot_network() → use topology.plot()
  - start_network_app() → use topology.start_app()
  - stop_network_app() → use topology.stop_app()
  - network_infos() → use topology.infos()
  - _dataset_sel(), _dataset_isel(), _dataset_resample(), _resample_by_dimension_groups() → use TransformAccessor class methods

  Parameters removed:

  - normalize_weights from create_model(), build_model(), optimize()

  Files updated:

  - flixopt/flow_system.py - removed deprecated methods
  - flixopt/optimize_accessor.py - removed normalize_weights parameter
  - flixopt/optimization.py - removed normalize_weights from Optimization classes
  - tests/test_*.py - updated to use new APIs
  - CHANGELOG.md - documented removals

  Still deprecated (for v7.0.0):

  - Optimization, SegmentedOptimization, Results, SegmentedResults classes - these are kept as they don't affect loading old solutions/flow_systems
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 5, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

  - tests/deprecated/test_flow_system_resample.py
  - tests/deprecated/test_resample_equivalence.py
  - tests/deprecated/examples/ folder

  Fixed files:
  - flixopt/optimization.py - SegmentedOptimization now uses transform.sel()
  - tests/deprecated/test_scenarios.py - updated to use transform.sel()
  - tests/deprecated/test_network_app.py - updated to use topology.start_app()/stop_app()
  - tests/deprecated/test_results_io.py - updated to use topology.plot()
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