Releases: dieselrabbit/screenlogicpy
Releases · dieselrabbit/screenlogicpy
v0.10.1
Fixes:
- Fixed super chlorination stopping if any SCG settings were changed.
- Super chlorination would be turned off if any SCG setting(s) were set without also explicitly defining the super chlorinate setting.
- SCG settings now use existing super chlorinate setting instead of defaulting to
0
.
v0.10.0
Breaking Changes:
- Require python 3.10+
- Portions of codebase now use union type hints
- Refactor exception handling
- Methods that lead to making a request to the protocol adapter will no longer return a
bool
indicating success. Instead an appropriate exception will be raised if an error is encountered. - Add more granular
ScreenLogicException
:ScreenLogicCommunicationError
- Base class for all communication errors.ScreenLogicLoginError
- The login was explicitly rejected.ScreenLogicConnectionError
- Connection to the protocol adapter was lost.ScreenLogicRequestError
- Protocol adapter indicated an unknown or malformed request.ScreenLogicResponseError
- Protocol adapter returned an unexpected response.
- Methods that lead to making a request to the protocol adapter will no longer return a
Changes:
- Make set_scg_config and set_chem_data kwargs only.
- Supports needing to only supply the changed value(s), not all values set with pool command.
- Refactor unit/integration testing.
- Make actual unit tests for many functions.
- Add support for pulling testing data from .json files.
- Support testing against multiple data sets.
- Support for creating data sets from HA diagnostic exports.
Added:
- Add support for getting and setting pool controller date/time.
- Support for syncing pool controller date/time to the host's date/time.
- Support getting/setting Super Chlorination settings.
- CLI support for:
- Setting user-set IntelliChem values:
- Calcium Hardness
- Cyanuric Acid
- Total Alkalinity
- Salt/TDS
- Setting super chlorinate values:
- Enabled (On/Off)
- Run Time Hours
- Getting and setting pool controller date and/or time.
- Exporting a testing data set.
- Setting user-set IntelliChem values:
v0.9.4
Fixes:
- Reset colors list on each config update
- This fixes unintended internal data growth each time a gateway reconnects to a protocol adapter.
Changes:
- Cancel/cleanup outstanding requests (futures) on connection loss
- Add additional debug logging.
- Client ID on gateway subscription
- Any errors when attempting to create connection
v0.9.3
Changes:
- Change SCG setpoint
step
value for pool and spa to 1
v0.9.2
Changes:
- Filter Chlorinator state to low bit (0x01) in data.
- Limits Chlorinator state to 1 or 0.
v0.9.1
Changes:
- Don't exclude any data keys regardless of equipment config
- Decisions on what data to include in the data
dict
based on equipment config or seemingly 'invalid' values will no longer be made withinscreenlogicpy
. Any calling application will be responsible for filtering irrelevant information from their user.
- Decisions on what data to include in the data
- Don't attempt to reconnect during ping or remove_client requests.
- These requests are not critical and can interrupt or block the desired connection sequence.
- Don't retry a failed request if no longer connected to the protocol adapter.
v0.9.0
Breaking Changes:
- Python 3.8 is no longer supported as of this release. Minimum supported Python version is now 3.9.
Future note: Support for Python 3.9 will be deprecated after the 0.9.x release series, after which Python 3.10 will be the minimum supported version.- Updated types to python 3.9 generics typing
- Major data refactor
This release contains a major reorganization of the internal datadict
, and in-turn the resulting json output. Changes include:- Data reorganized by device and common group.
- Flags values get their own group.
- Multiple data keys renamed for correctness, clarity, or newly discovered functionality.
You can check out the new json format here.
- Data reorganized by device and common group.
Changes:
- Use constants for all data dict keys.
- Use Enums for flags and int values
Added:
ScreenLogicGateway.get_data()
now supports returning subsets of data or individual values.get_data()
accepts a "path" in the form of multiple parameters of keys to the desired data, and will return only that data.- Shortcut methods
get_name()
andget_value()
have also been added. These will return the value of the "name" or "value" key that exists - if it exists - within the data specified by the data "path". - By default
get_data()
,get_name()
, andget_value()
will returnNone
if the specified path or key is not found. Keyword argstrict=True
can be specified to raiseKeyError
exception if the path or key is not found.
- Shortcut methods
v0.8.2
Breaking Change:
ScreenLogicWarning
is no longer raised on request or connection errors. See Changes below for details on what is raised when.
Changes:
- Reconnect on request failure
- screenlogicpy will now attempt to reconnect to the protocol adapter once after a failure to complete a request (for any reason), after retrying the set number of times. If reconnected, screenlogicpy will attempt the request once again.
- If reconnection or the second full request attempt fails, screenlogicpy will raise a full
ScreenLogicError
exception. This supports Home Assistant handling the communication failure accordingly. ScreenLogicRequestError
is raised for failure in making a request to the protocol adapter.- A full
ScreenLogicError
is raised immediately on any failure to connection to the protocol adapter.
Added:
- New exception classes
ScreenLogicException
Base exception class for screenlogicpyScreenLogicRequestError
raised specifically for failing to complete a request due to:- Communication timeout
- Any error response from the protocol adapter
v0.8.1
Fixes:
- Fixed crash when attempting to keep a client connection alive by pinging the protocol adapter
Changes:
- Updated testing support code
v0.8.0
Breaking Change:
- Passing host connection parameters to the
ScreenLogicGateway
constructor was deprecated in v0.7.0 and has now been removed. Consuming code should useasync_connect()
instead.
Changes:
- Support for Python 3.8 and 3.9 is being phased out.
- Home Assistant - this library's target audience - only supports that last two major releases of Python and has already removed support for Python 3.8 and 3.9. It is expected that support for Python 3.10 in Home Assistant will also be deprecated when Python 3.12 releases.
- The next "major"(minor in semantic versioning) release of screenlogicpy (v0.9.0) will remove support for Python 3.8, with 3.9 to follow the next "major" release after that.
.requests.utility.getString()
will now return a decoded and trimmedstr
value. Anyone usinggetString()
in their own code (ie. custom message decoding) no longer need to call.decode("utf-8").strip("\0")
themselves on the return.- Color update message decoding was moved into
requests\lights.py
- Order of release notes will now list breaking changes first, followed by general changes, then additions.
- Various cleanup, typing, code improvements
- Documentation updates
Added:
- Added support for retrying requests in the event of a timeout (no response within 5 seconds) or if the protocol adapter returns an error code (too many requests at once seems to be able to cause the protocol adapter to return error code 31).
- The number of times screenlogicpy with attempt to send or resend a message defaults to
2
. This can be changed by:- Passing a new value in the
max_retries
parameter during gateway instantiation - By using
gateway.set_max_retries(new_value)
- Passing a new value in the
- The new value can be
None
or 1-5. Callingset_max_retries()
with no value will reset to the default of 2.
- The number of times screenlogicpy with attempt to send or resend a message defaults to
- Support for a unique
client_id
per instance of screenlogicpy.- A random id will be used or the
client_id
parameter can be specified at gateway creation to use a custom one.
- A random id will be used or the