python-luxtronik icon indicating copy to clipboard operation
python-luxtronik copied to clipboard

Throw a KeyError exception if obsolete names are used

Open Guzz-T opened this issue 1 year ago • 2 comments

Unlike #187, this version no longer supports obsolete names. Instead, it returns an exception, compelling the user to switch to the latest version.

The names are passed directly to the constructor, eliminating the need for additional files or constants. This allows for the identification of names from previous versions without the need to execute the code.

Fixes #168. Replaces #171 and #187.

Guzz-T avatar Nov 20 '24 18:11 Guzz-T

Coverage

Coverage Report
FileStmtsMissCoverMissing
luxtronik
   __init__.py1841194%42–43, 46–51, 257–258, 263
   __main__.py21210%3–49
   datatypes.py322199%110
   discover.py58198%62
luxtronik/scripts
   dump_changes.py43430%7–85
   dump_luxtronik.py26260%6–52
luxtronik/shi
   definitions.py204399%113, 425–426
   modbus.py105199%320
TOTAL114410791% 

Tests Skipped Failures Errors Time
237 0 :zzz: 0 :x: 0 :fire: 15.676s :stopwatch:

github-actions[bot] avatar Nov 20 '24 18:11 github-actions[bot]

@Bouni, @gerw How do you like this proposed solution?

Guzz-T avatar Dec 06 '24 17:12 Guzz-T

For me this seems reasonable and since its configurable, it should make everyone happy. Anyone against merging this, since it has been lying around for quite a while?

kbabioch avatar Oct 21 '25 19:10 kbabioch

LGTM

@kbabioch Feel free to merge this one

Bouni avatar Oct 24 '25 11:10 Bouni

I've rebased it on top current master and self-approved it, since this was a trivial change. Hopefully no one feels offended by this, wanted to proceed with this one, since @Bouni told us that we may proceed in this previous comment.

kbabioch avatar Oct 24 '25 15:10 kbabioch