• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

FlexMeasures / flexmeasures / 40558496530
87%

Build:
DEFAULT BRANCH: main
Ran 27 Oct 2026 06:29PM UTC
Jobs 1
Files 194
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

27 Oct 2026 06:16PM UTC coverage: 86.956% (+0.03%) from 86.924%
40558496530

push

github

web-flow
Keep a deleted sensor's references, with their sensor unset (#2726)

* fix: prune sensor references that carry a default or bounds when their sensor is deleted

A flex-config entry is a sensor reference if it has the sensor key and no key beyond those of SensorReferenceSchema. The pruning code listed only the sensor key and the four source filters, so an entry with a default, lower, upper or snap was kept when its sensor was deleted. Take the keys from the schema, so a key added there is also recognised here.

Refs #2558

Signed-off-by: charanteja25 <charanteja.teja25@gmail.com>

* docs: add changelog entry for the pruning fix

Signed-off-by: charanteja25 <charanteja.teja25@gmail.com>

* docs: move the changelog entry to the Bugfixes list

Signed-off-by: charanteja25 <charanteja.teja25@gmail.com>

* Keep a deleted sensor's references, with their sensor unset

Deleting a sensor now unsets the sensor of each flex-model and flex-context reference to it,
keeping its default, bounds and source filters for when a new sensor is picked for the field.
A reference with nothing besides its sensor is still removed,
and so is an entry in a list of references, as it has nothing to read without a sensor.
The keys a reference may carry come from sensor_reference_keys, which landed on main in #2656.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: F.N. Claessen <claessen@seita.nl>

* Refuse a sensor reference without a sensor in the API

Only sensor deletion leaves a reference with "sensor": null behind, in a stored flex-config.
The API refuses one with a message saying so, which also blocks saving that flex-config until a sensor is picked.
The permission loader skips a null sensor, as there is no sensor to check, rather than failing the request with a 500.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: F.N. Claessen <claessen@seita.nl>

* Schedule on a deleted sensor's default, or let an ancestor's value apply

A stored... (continued)

58 of 58 new or added lines in 5 files covered. (100.0%)

2 existing lines in 1 file now uncovered.

22405 of 25766 relevant lines covered (86.96%)

0.87 hits per line

Coverage Regressions

Lines Coverage ∆ File
2
89.83
-0.06% flexmeasures/data/services/sensors.py
Jobs
ID Job ID Ran Files Coverage
1 40558496530.1 27 Oct 2026 06:29PM UTC 194
86.96
GitHub Action Run
Source Files on build 40558496530
  • Tree
  • List 194
  • Changed 6
  • Source Changed 5
  • Coverage Changed 6
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #40558496530
  • c699aa81 on github
  • Prev Build on main (#40472169101)
  • Next Build on main (#40597763833)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc