MatterMiners / tardis

Transparent Adaptive Resource Dynamic Integration System
https://cobald-tardis.readthedocs.io
MIT License
15 stars 20 forks source link

Ensure meaningful default for resource_status on new drones #301

Closed giffels closed 11 months ago

giffels commented 11 months ago

On newly created drones, the resource_status attribute is missing in the resource_attributes AttributeDict. This pull request adds the missing attribute, explicitly if the state is none, which means newly created drone. Therefore the attribute is set in https://github.com/MatterMiners/tardis/blob/0df932c86aa64b4e58f4db5c58c9322650810421/tardis/resources/drone.py#L125

Fixes #297

codecov-commenter commented 11 months ago

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.04 :tada:

Comparison is base (7b96d0e) 98.80% compared to head (5d29f0d) 98.84%.

:exclamation: Current head 5d29f0d differs from pull request most recent head 4104ee9. Consider uploading reports for the commit 4104ee9 to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #301 +/- ## ========================================== + Coverage 98.80% 98.84% +0.04% ========================================== Files 56 56 Lines 2344 2345 +1 ========================================== + Hits 2316 2318 +2 + Misses 28 27 -1 ``` | [Impacted Files](https://app.codecov.io/gh/MatterMiners/tardis/pull/301?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=MatterMiners) | Coverage Δ | | |---|---|---| | [tardis/resources/drone.py](https://app.codecov.io/gh/MatterMiners/tardis/pull/301?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=MatterMiners#diff-dGFyZGlzL3Jlc291cmNlcy9kcm9uZS5weQ==) | `100.00% <100.00%> (+1.03%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

giffels commented 11 months ago

Please, ignore broken docker build due to #302 .

giffels commented 11 months ago

Please, ignore broken docker build due to #302 .

Broken docker builds are fixed again.