**********************
FlexMeasures Changelog
**********************
v0.25.0 | February XX, 2025
============================
New features
-------------
Infrastructure / Support
----------------------
Bugfixes
-----------
v0.24.0 | January 7, 2025
============================
.. note:: Read more on these features on `the FlexMeasures blog `_.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
New features
-------------
* The data chart on the asset page splits up its color-coded sensor legend when showing more than 7 sensors, becoming a legend per subplot [see `PR #1176 `_ and `PR #1193 `_]
* Speed up loading the users page, by making the pagination backend-based and adding support for that in the API [see `PR #1160 `_]
* X-axis labels in CLI plots show datetime values in a readable and informative format [see `PR #1172 `_]
* Enhanced API for listing sensors: Added filtering and pagination on sensor index endpoint and created new endpoint to get all sensors under an asset [see `PR #1191 `_ and `PR #1219 `_]
* Speed up loading the accounts page by making the pagination backend-based and adding support for that in the API [see `PR #1196 `_]
* Speed up loading the account detail page by by switching to server-side pagination for assets, replacing client-side pagination [see `PR #1202 `_]
* Added form to edit an asset's sensors_to_show data directly from the UI [see `PR #1212 `_]
* Speed up loading on audit log tables page by switching to server-side pagination, replacing client-side pagination [see `PR #1274 `_ and `PR #1272 `_]
* Simplify and globalize UI messages, using Toast [see `PR #1207 `_]
* Power sensors created through the CLI no longer require a capacity attribute to be set [see `PR #1234 `_]
Infrastructure / Support
----------------------
* The breadcrumbs on asset and sensor pages can now be customized [see `PR #1257 `_]
* The monitoring command to check for users who have been absent too long now can be used to keep data volume low and be more effective [see `PR #1268 `_]
* Speed up status page by choosing for a faster query (only latest belief needed) [see `PR #1142 `_]
* Speed up user page (for users with many assets) [see `PR #1286 `_]
* For MacOS developers, install HiGHS solver automatically [see `PR #1187 `_]
* Migrate data for the ``sensors_to_show`` asset attribute to a dedicated column in the database table for assets [see `PR #1200 `_ and `PR #1282 `_]
* Add support for installing FlexMeasures under Python 3.12 [see `PR #1233 `_]
* Better error handling in UI, for example, in case of a forgotten ``flexmeasures db upgrade`` [see `PR #1302 `_]
* Add dedicated ``sensors_to_show`` field to asset model and logic to migrate data from parent source(attributes field) [see `PR #1200 `_]
Bugfixes
-----------
* Fix table sorting on the assets, accounts and users page (regression from `PR #988 `_) [see `PR #1239 `_, `PR #1242 `_, `PR #1248 `_, `PR #1247 `_ and `PR #1272 `_]
* Fix ``flexmeasures delete measurements`` and ``flexmeasures delete prognoses`` which had an error in counting affected rows after SQLAlchemy2.0 upgrade [see `PR #1095 `_ and `PR #1303 `_]
* Fix asset count on the user page, which showed 0 assets after (de)activating a user or resetting their password [see `PR #1251 `_]
* The UI footer now stays at the bottom even on pages with little content [see `PR #1204 `_]
* Correct stroke dash (based on source type) for forecasts made by forecasters included in FlexMeasures [see `PR #1211 `_]
* Show the correct :abbr:`UTC (Coordinated Universal Time)` offset for the data's time span as shown under sensor stats in the UI [see `PR #1213 `_]
* Fixed issue where audit log buttons are visible to users without the necessary permissions. [see `PR #1228 `_]
* Fix issue with displaying ``deactivate user`` and ``reset password`` buttons for non admin users [see `PR #1220 `_]
v0.23.2 | December 16, 2024
============================
Bugfixes
-----------
* Correct source filters on reporter input, and support piping additional transformations in the ``PandasReporter`` [see `PR #1284 `_]
v0.23.1 | November 12, 2024
============================
Bugfixes
-----------
* Correct unit conversion of reporter output to output sensor [see `PR #1238 `_]
v0.23.0 | September 18, 2024
============================
.. note:: Read more on these features on `the FlexMeasures blog `_.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
New features
-------------
* New chart type on sensor page: histogram [see `PR #1143 `_]
* Add basic sensor info to sensor page [see `PR #1115 `_]
* Add `Statistics` table on the sensor page and also add `api/v3_0/sensors//stats` endpoint to get sensor statistics [see `PR #1116 `_]
* Support adding custom titles to the graphs on the asset page, by extending the ``sensors_to_show`` format [see `PR #1125 `_ and `PR #1177 `_]
* Support zoom-in action on the asset and sensor charts [see `PR #1130 `_]
* Speed up loading the assets page, by making the pagination backend-based and adding support for that in the API, and by enabling to query all accounts one can see in a single call (for admins and consultants) [see `PR #988 `_]
* Added Primary and Secondary colors to account for white-labelled UI themes [see `PR #1137 `_]
* Added Logo URL to account for white-labelled UI themes [see `PR #1145 `_]
* Added PopUp form to edit account details [see `PR #1152 `_]
* When listing past jobs on the `Tasks` page, show the most recent jobs first [see `PR #1163 `_]
* Introduce the ``VariableQuantityField`` to allow three ways of passing a variable quantity in most of the ``flex-model`` and ``flex-context`` fields [see `PR #1127 `_ and `PR #1138 `_]
* Support directly passing a fixed price in the ``flex-context`` using the new fields ``consumption-price`` and ``production-price``, which are meant to replace the ``consumption-price-sensor`` and ``production-price-sensor`` fields, respectively [see `PR #1028 `_]
Infrastructure / Support
----------------------
* Save beliefs faster by bulk saving [see `PR #1159 `_]
* Support new single-belief fast track (looking up only one belief) [see `PR #1067 `_]
* Add new annotation types: ``"error"`` and ``"warning"`` [see `PR #1131 `_ and `PR #1150 `_]
* When deleting a sensor, asset or account, delete any annotations that belong to them [see `PR #1151 `_]
* Removed deprecated ``app.schedulers`` and ``app.forecasters`` (use ``app.data_generators["scheduler"]`` and ``app.data_generators["forecaster"]`` instead) [see `PR #1098 `_]
* Save beliefs faster by bulk saving [see `PR #1159 `_]
* Introduced dynamic, JavaScript-generated toast notifications. [see `PR #1152 `_]
Bugfixes
-----------
* Fix string length exceeding the 255-character limit in the `event` field of `AssetAuditLog` by truncating long updates and logging each field or attribute change individually. [see `PR #1162 `_]
* Fix image carousel on the login page [see `PR #1154 `_]
* Fix styling for User and Documentation menu items [see `PR #1140 `_]
* Fix styling of sensor page, especially the graph chart dropdown [see `PR #1148 `_]
* Fix posting a single instantaneous belief [see `PR #1129 `_]
* Allow reassigning a public asset to private ownership using the ``flexmeasures edit transfer-ownership`` CLI command [see `PR #1123 `_]
* Fix missing value on spring :abbr:`DST (Daylight Saving Time)` transition for ``PandasReporter`` using daily sensor as input [see `PR #1122 `_]
* Fix date range persistence on session across different pages [see `PR #1165 `_]
* Fix issue with account creation failing when the ``--logo-url`` option is omitted. [see related PRs `PR #1167 `_ and `PR #1145 `_]
* Fix ordering of audit logs (asset, account) and job list on status page [see `PR #1179 _` and `PR #1183 `_]
v0.22.0 | June 29, 2024
============================
.. note:: Read more on these features on `the FlexMeasures blog `_.
New features
-------------
* Add `asset//auditlog` to view asset related actions [see `PR #1067 `_]
* On the `/sensor/id` page, allow to link to it with a date range and to copy current view as URL [see `PR #1094 `_]
* Flex-context (price sensors and inflexible device sensors) can now be set on the asset page (and are part of GenericAsset model) [see `PR #1059 `_]
* On the asset page's default view, facilitate comparison by showing the two default sensors together if they record the same unit [see `PR #1066 `_]
* Add flex-context sensors to status page [see `PR #1102 `_]
* Show tooltips on (mobile) touch screen [see `PR #1062 `_]
Infrastructure / Support
----------------------
* Add MailHog to docker-compose stack for testing email functionality [see `PR #1112 `_]
* Allow installing dependencies in docker-compose worker [see `PR #1057 `_]
* Add unit conversion to the input and output data of the ``PandasReporter`` [see `PR #1044 `_]
* Add option ``droplevels`` to the ``PandasReporter`` to drop all the levels except the ``event_start`` and ``event_value`` [see `PR #1043 `_]
* ``PandasReporter`` accepts the parameter ``use_latest_version_only`` to filter input data [see `PR #1045 `_]
* ``flexmeasures show beliefs`` uses the entity path (`/../`) in case of duplicated sensors [see `PR #1026 `_]
* Add ``--resolution`` option to ``flexmeasures show chart`` to produce charts in different time resolutions [see `PR #1007 `_]
* Add ``FLEXMEASURES_JSON_COMPACT`` config setting and deprecate ``JSONIFY_PRETTYPRINT_REGULAR`` setting [see `PR #1090 `_]
Bugfixes
-----------
* Fix ordering of jobs on the asset status page [see `PR #1106 `_]
* Relax max staleness for status page using 2 * event_resolution as default instead of immediate staleness [see `PR #1108 `_]
v0.21.0 | May 16, 2024
============================
.. note:: Read more on these features on `the FlexMeasures blog `_.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
New features
-------------
* Add `asset//status` page to view asset statuses [see `PR #941 `_ and `PR #1035 `_]
* Add `account//auditlog` and `user//auditlog` to view user and account related actions [see `PR #1042 `_]
* Support ``start_date`` and ``end_date`` query parameters for the asset page [see `PR #1030 `_]
* In plots, add the asset name to the title of the tooltip to improve the identification of the lines [see `PR #1054 `_]
* On asset page, show sensor IDs in sensor table [see `PR #1053 `_]
Bugfixes
-----------
* Prevent the time window in the UI from moving to the latest data when refreshing the asset page [see `PR #1046 `_ and `PR #1056 `_]
Infrastructure / Support
----------------------
* Include started, deferred and scheduled jobs in the overview printed by the CLI command ``flexmeasures jobs show-queues`` [see `PR #1036 `_]
* Make it as convenient to clear deferred or scheduled jobs from a queue as it was to clear failed jobs from a queue [see `PR #1037 `_]
v0.20.1 | May 7, 2024
============================
Bugfixes
-----------
* Prevent **p**\ lay/**p**\ ause/**s**\ top of replays when editing a text field in the UI [see `PR #1024 `_]
* Skip unit conversion of :abbr:`SoC (state of charge)` related fields that are defined as sensors in a ``flex-model`` (specifically, ``soc-maxima``, ``soc-minima`` and ``soc-targets`` [see `PR #1047 `_]
v0.20.0 | March 26, 2024
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
.. warning:: From this version on, the config setting ``FLEXMEASURES_FORCE_HTTPS`` decides whether to enforce HTTPS on requests - and it defaults to ``False``. Previously, this was governed by ``FLASK_ENV`` or ``FLEXMEASURES_ENV`` being set to something else than ``"documentation"`` or ``"development"``. This new way is more clear, but you might be in need of using this setting before upgrading.
New features
-------------
* Add command ``flexmeasures edit transfer-ownership`` to transfer the ownership of an asset and its children from one account to another [see `PR #983 `_]
* Support defining the ``site-power-capacity``, ``site-consumption-capacity`` and ``site-production-capacity`` as a sensor in the API and CLI [see `PR #985 `_]
* Support defining the ``soc-minima``, ``soc-maxima`` and ``soc-targets`` as sensors in the API [see `PR #996 `_]
* Support defining inflexible power sensors with arbitrary power and energy units [see `PR #1007 `_]
* Support saving beliefs with a ``belief_horizon`` in the ``PandasReporter`` [see `PR #1013 `_]
* Skip the check of the output event resolution in any ``Reporter`` with the field ``check_output_resolution`` [see `PR #1009 `_]
Bugfixes
-----------
* Use minimum event resolution of the input (instead of the output) sensors for the belief search parameters [see `PR #1010 `_]
Infrastructure / Support
----------------------
* Align map layers with custom asset types in the UI's dashboard, also facilitating capturing asset types defined within FlexMeasures plugins [see `PR #1017 `_]
* Improve processing time for deleting beliefs via CLI [see `PR #1005 `_]
* Support deleting beliefs via CLI for all offspring assets at once [see `PR #1003 `_]
* Add setting ``FLEXMEASURES_FORCE_HTTPS`` to explicitly toggle if HTTPS should be used for all requests [see `PR #1008 `_]
* Make flexmeasures installable locally on macOS [see `PR #1000 `_]
* Align API endpoint policy w.r.t. trailing slash [see `PR #1014 `_]
v0.19.2 | March 1, 2024
============================
.. note:: Optionally, run ``flexmeasures db upgrade`` after upgrading to this version for enhanced database performance on time series queries.
* Upgrade timely-beliefs to enhance our main time series query and fix a database index on time series data, leading to significantly better performance [see `PR #992 `_]
* Fix server error on loading the asset page for a public asset, due to a bug in the breadcrumb's sibling navigation [see `PR #991 `_]
* Restore compatibility with the `flexmeasures-openweathermap plugin `_ by fixing the query for the closest weather sensor to a given asset [see `PR #997 `_]
v0.19.1 | February 26, 2024
============================
* Support defining the ``power-capacity`` as a sensor in the API and CLI [see `PR #987 `_]
v0.19.0 | February 18, 2024
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
.. warning:: This version replaces ``FLASK_ENV`` with ``FLEXMEASURES_ENV`` (``FLASK_ENV`` will still be used as a fallback).
New features
-------------
* List child assets on the asset page [see `PR #967 `_]
* Expand the UI's breadcrumb functionality with the ability to navigate directly to sibling assets and sensors using their child-parent relationship [see `PR #977 `_]
* Enable the use of QuantityOrSensor fields for the ``flexmeasures add schedule for-storage`` CLI command [see `PR #966 `_]
* CLI support for showing/savings time series data for a given type of source only, with the new ``--source-type`` option of ``flexmeasures show beliefs``, which let's you filter out schedules, forecasts, or data POSTed by users (through the API), which each have a different source type [see `PR #976 `_]
* New CLI command ``flexmeasures delete beliefs`` to delete all beliefs on a given sensor (or multiple sensors) or on sensors of a given asset (or multiple assets) [see `PR #975 `_]
* Support for defining the storage efficiency as a sensor or quantity for the ``StorageScheduler`` [see `PR #965 `_]
* Support a less verbose way of setting the same :abbr:`SoC (state of charge)` constraint for a given time window [see `PR #899 `_]
Infrastructure / Support
----------------------
* Deprecate use of flask's ``FLASK_ENV`` variable and replace it with ``FLEXMEASURES_ENV`` [see `PR #907 `_]
* Streamline CLI option naming by favoring ``--`` over ``---id`` [see `PR #946 `_]
* Documentation: improve index page, installation overview, feature overview incl. flex-model overview and UI screenshots [see `PR #953 `_]
* Faster database queries of time series data by upgrading SQLAlchemy and timely-beliefs [see `PR #938 `_]
v0.18.2 | February 26, 2024
============================
* Convert unit of the power capacities to ``MW`` instead of that of the storage power sensor [see `PR #979 `_]
* Automatically update table navigation in the UI without requiring users to hard refresh their browser [see `PR #961 `_]
* Updated documentation to enhance clarity for integrating plugins within the FlexMeasures Docker container [see `PR #958 `_]
* Support defining the ``power-capacity`` as a sensor in the API [see `PR #987 `_]
v0.18.1 | January 15, 2024
============================
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
Bugfixes
-----------
* Fix database migrations meant to clean up deprecated tables [see `PR #960 `_]
* Allow showing beliefs (plot and file export) via the CLI for sensors with non-unique names [see `PR #947 `_]
* Added Redis credentials to the Docker Compose configuration for the web server to ensure proper interaction with the Redis queue [see `PR #945 `_]
* Fix API version listing (GET /api/v3_0) for hosts running on Python 3.8 [see `PR #917 `_ and `PR #950 `_]
* Fix the validation of the option ``--parent-asset`` of command ``flexmeasures add asset`` [see `PR #959 `_]
v0.18.0 | December 23, 2023
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``). If this fails, update to ``flexmeasures==0.18.1`` first (and then run ``flexmeasures db upgrade``).
New features
-------------
* Better navigation experience through listings (sensors / assets / users / accounts) in the :abbr:`UI (user interface)`, by heading to the selected entity upon a click (or CTRL + click) anywhere within a row [see `PR #923 `_]
* Introduce a breadcrumb to navigate through assets and sensor pages using its child-parent relationship [see `PR #930 `_]
* Define device-level power constraints as sensors to create schedules with changing power limits [see `PR #897 `_]
* Allow to provide external storage usage or gain components using the ``soc-usage`` and ``soc-gain`` fields of the ``flex-model`` [see `PR #906 `_]
* Define time-varying charging and discharging efficiencies as sensors or as constant values which allows to define the :abbr:`COP (coefficient of performance)` [see `PR #933 `_]
Infrastructure / Support
----------------------
* Align database and models of ``annotations``, ``data_sources``, and ``timed_belief`` [see `PR #929 `_]
* New documentation section on constructing a flex model for :abbr:`V2G (vehicle-to-grid)` [see `PR #885 `_]
* Allow charts in plugins to show currency codes (such as EUR) as currency symbols (€) [see `PR #922 `_]
* Remove obsolete database tables ``price``, ``power``, ``market``, ``market_type``, ``weather``, ``asset``, and ``weather_sensor`` [see `PR #921 `_]
* New flexmeasures configuration setting ``FLEXMEASURES_ENFORCE_SECURE_CONTENT_POLICY`` for upgrading insecure `http` requests to secured requests `https` [see `PR #920 `_]
Bugfixes
-----------
* Give ``admin-reader`` role access to the RQ Scheduler dashboard [see `PR #901 `_]
* Assets without a geographical position (i.e. no lat/lng coordinates) can be edited through the UI [see `PR #924 `_]
v0.17.1 | December 7, 2023
============================
Bugfixes
-----------
* Show `Assets`, `Users`, `Tasks` and `Accounts` pages in the navigation bar for the ``admin-reader`` role [see `PR #900 `_]
* Reduce worker logs when datetime exceeds the end of the schedule [see `PR #918 `_]
* Fix infeasible problem due to incorrect estimation of the big-M value [see `PR #905 `_]
* [Incomplete fix; full fix in v0.18.1] Fix API version listing (GET /api/v3_0) for hosts running on Python 3.8 [see `PR #917 `_]
v0.17.0 | November 8, 2023
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
New features
-------------
- Different site-level production and consumption limits can be defined for the storage scheduler via the API (``flex-context``) or via asset attributes [see `PR #884 `_]
- Scheduling data better distinguishes (e.g. in chart tooltips) when a schedule was the result of a fallback mechanism, by splitting off the fallback mechanism from the main scheduler (as a separate job) [see `PR #846 `_]
- New accounts can set a consultancy relationship with another account to give read access to external consultants [see `PR #877 `_ and `PR #892 `_]
Infrastructure / Support
----------------------
- Introduce a new one-to-many relation between assets, allowing the definition of an asset's parent (which is also an asset), which leads to a hierarchical relationship that enables assets to be related in a structured manner [see `PR #855 `_ and `PR #874 `_]
- Introduce a new format for the output of ``Scheduler`` to prepare for multiple outputs [see `PR #879 `_]
v0.16.1 | October 2, 2023
============================
Bugfixes
-----------
* Fix infeasible problem due to incorrect parsing of soc units of the ``soc-minima`` and ``soc-maxima`` fields within the ``flex-model`` field [see `PR #864 `_]
v0.16.0 | September 27, 2023
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
New features
-------------
* Introduce new reporter to compute profit/loss due to electricity flows: ``ProfitOrLossReporter`` [see `PR #808 `_ and `PR #844 `_]
* Charts visible in the UI can be exported to PNG or SVG formats in a more automated fashion, using the new CLI command flexmeasures show chart [see `PR #833 `_]
* Chart data visible in the UI can be exported to CSV format [see `PR #849 `_]
* Sensor charts showing instantaneous observations can be interpolated by setting the ``interpolate`` sensor attribute to one of the `supported Vega-Lite interpolation methods `_ [see `PR #851 `_]
* API users can ask for a schedule to take into account an explicit ``power-capacity`` (flex-model) and/or ``site-power-capacity`` (flex-context), thereby overriding any existing defaults for their asset [see `PR #850 `_]
* API users (and hosts) are warned in case a fallback scheduling policy has been used to create their schedule (as part of the the `/sensors//schedules/` (GET) response message) [see `PR #859 `_]
Infrastructure / Support
----------------------
* Allow additional datetime conversions to quantitative time units, specifically, from timezone-naive and/or dayfirst datetimes, which can be useful when importing data [see `PR #831 `_]
* Add a new tutorial to explain the use of the ``AggregatorReporter`` to compute the headroom and the ``ProfitOrLossReporter`` to compute the cost of running a process [see `PR #825 `_ and `PR #856 `_]
* Updated admin dashboard for inspecting asynchronous tasks (scheduling, forecasting, reporting, etc.), and improved performance and security of the server by upgrading Flask and Flask extensions [see `PR #838 `_]
* Script to update dependencies across supported Python versions [see `PR #843 `_]
* Test all supported Python versions in our CI pipeline (GitHub Actions) [see `PR #847 `_]
* Have our CI pipeline (GitHub Actions) build the Docker image and make a schedule [see `PR #800 `_]
* Updated documentation on the consequences of setting the ``FLEXMEASURES_MODE`` config setting [see `PR #857 `_]
* Implement cache-busting to avoid the need for users to hard refresh the browser when new JavaScript functionality is added to the :abbr:`UI (user interface)` in a new FlexMeasures version [see `PR #860 `_]
v0.15.2 | October 2, 2023
============================
Bugfixes
-----------
* Fix infeasible problem due to incorrect parsing of soc units of the ``soc-minima`` and ``soc-maxima`` fields within the ``flex-model`` field [see `PR #864 `_]
v0.15.1 | August 28, 2023
============================
Bugfixes
-----------
* Fix infeasible problem due to floating point error in :abbr:`SoC (state of charge)` targets [see `PR #832 `_]
* Use the ``source`` to filter beliefs in the ``AggregatorReporter`` and fix the case of having multiple sources [see `PR #819 `_]
* Disable HiGHS logs on the standard output when ``LOGGING_LEVEL=INFO`` [see `PR #824 `_ and `PR #826 `_]
* Fix showing sensor data on the asset page of public assets, and searching for annotations on public assets [see `PR #830 `_]
* Make the command ``flexmeasures add schedule for-storage`` to pass the soc-target timestamp to the flex model as strings instead of ``pd.Timestamp`` [see `PR #834 `_]
v0.15.0 | August 9, 2023
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
.. warning:: Upgrading to this version requires installing the LP/MILP solver HiGHS using ``pip install highspy``.
.. warning:: If your server is running in play mode (``FLEXMEASURES_MODE = "play"``), users will be able to see sensor data from any account [see `PR #740 `_].
New features
-------------
* Add ``ProcessScheduler`` class to optimize the starting time of processes one of the policies developed (``INFLEXIBLE``, ``SHIFTABLE`` and ``BREAKABLE``), accessible via the CLI command ``flexmeasures add schedule for-process`` [see `PR #729 `_ and `PR #768 `_]
* Users can select a new chart type (daily heatmap) on the sensor page of the UI, showing how sensor values are distributed over the time of day [see `PR #715 `_]
* Added API endpoints `/sensors/` (GET) for fetching a single sensor, `/sensors` (POST) for adding a sensor, `/sensors/` (PATCH) for updating a sensor and `/sensors/` (DELETE) for deleting a sensor [see `PR #759 `_] and [see `PR #767 `_] and [see `PR #773 `_] and [see `PR #784 `_]
* Users are warned in the UI on when the data they are seeing includes one or more :abbr:`DST (Daylight Saving Time)` transitions, and heatmaps (see previous feature) visualize these transitions intuitively [see `PR #723 `_]
* Allow deleting multiple sensors with a single call to ``flexmeasures delete sensor`` by passing the ``--id`` option multiple times [see `PR #734 `_]
* Make it a lot easier to read off the color legend on the asset page, especially when showing many sensors, as they will now be ordered from top to bottom in the same order as they appear in the chart (as defined in the ``sensors_to_show`` attribute), rather than alphabetically [see `PR #742 `_]
* Users on FlexMeasures servers in play mode (``FLEXMEASURES_MODE = "play"``) can use the ``sensors_to_show`` attribute to show any sensor on their asset pages, rather than only sensors registered to assets in their own account or to public assets [see `PR #740 `_]
* Having percentages within the [0, 100] domain is such a common use case that we now always include it in sensor charts with % units, making it easier to read off individual charts and also to compare across charts [see `PR #739 `_]
* The ``DataSource`` table now allows storing arbitrary attributes as a JSON (without content validation), similar to the ``Sensor`` and ``GenericAsset`` tables [see `PR #750 `_]
* Users will be able to see (e.g. in the UI) exactly which reporter created the report (saved as sensor data), and hosts will be able to identify exactly which configuration was used to create a given report [see `PR #751 `_ and `PR #788 `_]
* The CLI ``flexmeasures add report`` now allows passing ``config`` and ``parameters`` in YAML format as files or editable via the system's default editor [see `PR #752 `_ and `PR #788 `_]
* The CLI now allows to set lists and dicts as asset & sensor attributes (formerly only single values) [see `PR #762 `_]
Bugfixes
-----------
* Add binary constraint to avoid energy leakages during periods with negative prices [see `PR #770 `_]
Infrastructure / Support
----------------------
* Add support for profiling Flask API calls using ``pyinstrument`` (if installed). Can be enabled by setting the environment variable ``FLEXMEASURES_PROFILE_REQUESTS`` to ``True`` [see `PR #722 `_]
* The endpoint `[POST] /health/ready `_ returns the status of the Redis connection, if configured [see `PR #699 `_]
* Document the ``device_scheduler`` linear program [see `PR #764 `_]
* Add support for `HiGHS `_ solver [see `PR #766 `_]
* Add support for installing FlexMeasures under Python 3.11 [see `PR #771 `_]
* Start keeping sets of pinned requirements per supported Python version, which also fixes recent Docker build problem [see `PR #776 `_]
* Removed obsolete code dealing with deprecated data models (e.g. assets, markets and weather sensors), and sunset the fm0 scheme for entity addresses [see `PR #695 `_ and `project 11 `_]
v0.14.3 | October 2, 2023
============================
Bugfixes
-----------
* Fix infeasible problem due to incorrect parsing of soc units of the ``soc-minima`` and ``soc-maxima`` fields within the ``flex-model`` field [see `PR #864 `_]
v0.14.2 | July 25, 2023
============================
Bugfixes
-----------
* The error handling for infeasible constraints in ``storage.py`` was given too many arguments, which caused the response from the API to be unhelpful when a schedule was requested with infeasible constraints [see `PR #758 `_]
v0.14.1 | June 26, 2023
============================
Bugfixes
-----------
* Relax constraint validation of ``StorageScheduler`` to accommodate violations caused by floating point precision [see `PR #731 `_]
* Avoid saving any :abbr:`NaN (not a number)` values to the database, when calling ``flexmeasures add report`` [see `PR #735 `_]
* Fix browser console error when loading asset or sensor page with only a single data point [see `PR #732 `_]
* Fix showing multiple sensors with bare 3-letter currency code as their units (e.g. EUR) in one chart [see `PR #738 `_]
* Fix defaults for the ``--start-offset`` and ``--end-offset`` options to ``flexmeasures add report``, which weren't being interpreted in the local timezone of the reporting sensor [see `PR #744 `_]
* Relax constraint for overlaying plot traces for sensors with various resolutions, making it possible to show e.g. two price sensors in one chart, where one of them records hourly prices and the other records quarter-hourly prices [see `PR #743 `_]
* Resolve bug where different page loads would potentially influence the time axis of each other's charts, by avoiding mutation of shared field definitions [see `PR #746 `_]
v0.14.0 | June 15, 2023
============================
.. note:: Read more on these features on `the FlexMeasures blog `__.
New features
-------------
* Allow setting a storage efficiency using the new ``storage-efficiency`` field when calling `/sensors//schedules/trigger` (POST) through the API (within the ``flex-model`` field), or when calling ``flexmeasures add schedule for-storage`` through the CLI [see `PR #679 `_]
* Allow setting multiple :abbr:`SoC (state of charge)` maxima and minima constraints for the ``StorageScheduler``, using the new ``soc-minima`` and ``soc-maxima`` fields when calling `/sensors//schedules/trigger` (POST) through the API (within the ``flex-model`` field) [see `PR #680 `_]
* New CLI command ``flexmeasures add report`` to calculate a custom report from sensor data and save the results to the database, with the option to export them to a CSV or Excel file [see `PR #659 `_]
* New CLI commands ``flexmeasures show reporters`` and ``flexmeasures show schedulers`` to list available reporters and schedulers, respectively, including any defined in registered plugins [see `PR #686 `_ and `PR #708 `_]
* Allow creating public assets through the CLI, which are available to all users [see `PR #727 `_]
Bugfixes
-----------
* Fix charts not always loading over https in secured scenarios [see `PR #716 `_]
Infrastructure / Support
----------------------
* Introduction of the classes ``Reporter``, ``PandasReporter`` and ``AggregatorReporter`` to help customize your own reporter functions (experimental) [see `PR #641 `_ and `PR #712 `_]
* The setting ``FLEXMEASURES_PLUGINS`` can be set as environment variable now (as a comma-separated list) [see `PR #660 `_]
* Packaging was modernized to stop calling setup.py directly [see `PR #671 `_]
* Remove API versions 1.0, 1.1, 1.2, 1.3 and 2.0, while making sure that sunset endpoints keep returning ``HTTP status 410 (Gone)`` responses [see `PR #667 `_ and `PR #717 `_]
* Support Pandas 2 [see `PR #673 `_]
* Add code documentation from package structure and docstrings to official docs [see `PR #698 `_]
.. warning:: The setting `FLEXMEASURES_PLUGIN_PATHS` has been deprecated since v0.7. It has now been sunset. Please replace it with :ref:`plugin-config`.
v0.13.3 | June 10, 2023
=======================
Bugfixes
---------
* Fix forwarding arguments in deprecated util function [see `PR #719 `_]
v0.13.2 | June 9, 2023
=======================
Bugfixes
---------
* Fix failing to save results of scheduling and reporting on subsequent calls for the same time period [see `PR #709 `_]
v0.13.1 | May 12, 2023
=======================
Bugfixes
---------
* ``@deprecated`` not returning the output of the decorated function [see `PR #678 `_]
v0.13.0 | May 1, 2023
============================
.. warning:: Sunset notice for API versions 1.0, 1.1, 1.2, 1.3 and 2.0: after upgrading to ``flexmeasures==0.13``, users of these API versions may receive ``HTTP status 410 (Gone)`` responses.
See the `documentation for deprecation and sunset `_.
The relevant endpoints have been deprecated since ``flexmeasures==0.12``.
.. warning:: The API endpoint (`[POST] /sensors/(id)/schedules/trigger `_) to make new schedules sunsets the deprecated (since v0.12) storage flexibility parameters (they move to the ``flex-model`` parameter group), as well as the parameters describing other sensors (they move to ``flex-context``).
.. warning:: Upgrading to this version requires running ``flexmeasures db upgrade`` (you can create a backup first with ``flexmeasures db-ops dump``).
.. note:: Read more on these features on `the FlexMeasures blog `__.
New features
-------------
* Keyboard control over replay [see `PR #562 `_]
* Overlay charts (e.g. power profiles) on the asset page using the ``sensors_to_show`` attribute, and distinguish plots by source (different trace), sensor (different color) and source type (different stroke dash) [see `PR #534