Closed Ludy87 closed 5 months ago
Added Annotations for Improved Code Clarity Typing annotations were added to functions and variables in various files. These annotations indicate the type of data that a function should receive or that a variable can hold. This contributes to code clarity, improving the developers' understanding of how the functions and variables should be used.
Variable Renaming for Better Consistency
Certain variables in binary_sensor.py
were renamed (e.g., ATTR_LATITUDE
to CONF_LATITUDE
) to make the variable names more consistent and intuitive across different files.
Typos Fixed in Several Files
Typos present in mulitple files, including config_flow.py
, const.py
, coordinator.py
, geocoder.py
, and manifest.json
were corrected. This helps prevent any potential confusions or coding errors that could result from these mistakes.
Cleaned Up Code for Efficiency Unused import statements were removed, along with minor code formatting changes made throughout, for the sake of code efficiency and readability.
More precise Type Definitions in 'Switch.py' The 'switch.py' file saw extensive improvements, with the type annotation for variables and function parameters being made more specific. For example, variables like 'entities' and 'ward' now have their types explicitly defined, aiding in readability and potentially reducing the risk of type-related errors.
Enriched Language Support via New Files
Two new files providing translations (es.json
for Spanish, and fr.json
for French) have been added, broadening the program's accessibility to non-English speaking users.
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Fix: https://github.com/Ludy87/xplora_watch/issues/347, https://github.com/Ludy87/xplora_watch/issues/328