legrego / homeassistant-elasticsearch

Publish Home-Assistant events to Elasticsearch
https://legrego.github.io/homeassistant-elasticsearch/
MIT License
143 stars 38 forks source link

Move publish_active to avoid race condition #302

Closed strawgate closed 2 weeks ago

strawgate commented 2 weeks ago

Tests pass, appears to be publishing documents

strawgate commented 2 weeks ago

Fixes https://github.com/legrego/homeassistant-elasticsearch/issues/301

github-actions[bot] commented 2 weeks ago

Coverage

Coverage Report
FileStmtsMissCoverMissing
__init__.py00100% 
elasticsearch
   __init__.py90297%208–209
   config_flow.py2522888%85, 124, 232, 314, 337, 351, 392–395, 397–398, 400, 402–404, 406–407, 421–422, 426, 466, 472, 512, 587, 596, 630–631
   const.py330100% 
   entity_details.py330100% 
   errors.py28389%51, 60, 67
   es_doc_creator.py1830100% 
   es_doc_publisher.py2601594%103, 245–246, 262–263, 366, 466–467, 469–470, 472–476
   es_gateway.py1001981%82–83, 102, 118–120, 122, 124–125, 127–131, 133–137
   es_index_manager.py123893%243–244, 261–262, 267–268, 297–298
   es_integration.py37294%43–44
   es_privilege_check.py550100% 
   es_serializer.py10190%17
   es_version.py300100% 
   logger.py20100% 
   system_info.py25196%37
   utils.py40100% 
TOTAL12657993% 

Tests Skipped Failures Errors Time
95 0 :zzz: 0 :x: 0 :fire: 7.403s :stopwatch:
strawgate commented 2 weeks ago

@legrego I'm not actually sure how to hotfix 0.7

We probably don't want to release main, do we make a 0.7 branch from the 0.7 tag, merge this PR into that, and then cut a new release?

If so can you make a branch I can backport into?

If not please advice or feel free to steal this change and do it the right way