iobroker.alpha-ess 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -11,6 +11,14 @@
11
11
 
12
12
  ## alpha-ess adapter for ioBroker
13
13
 
14
+ ---
15
+
16
+ ### Due to current circumstances, please take note!
17
+
18
+ [Interface restriction announcement](https://github.com/alphaess-developer/alphacloud_open_api/issues/54)
19
+
20
+ ---
21
+
14
22
  This adapter logs into the web API of [Alpha-ESS](https://www.alphaess.com/) and retrieves information for your Alpha-ESS equipment.\
15
23
  Depending on your Alpha-ESS product, it is possible to get realtime data and configuration data for your equipment. Which data points are returned by the API depends on your Alpha-ESS equipment.
16
24
 
@@ -46,6 +54,10 @@ How to find SN and Check code for registration is described here: https://github
46
54
  **All product and company names or logos are trademarks™ or registered® trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by them or any associated subsidiaries! This personal project is maintained in spare time and has no business goal.**
47
55
 
48
56
  ## Changelog
57
+ ### 2.0.1 (2024-01-03)
58
+
59
+ - (Gaspode) Adapted timeout to new API restrictions
60
+
49
61
  ### 2.0.0 (2023-12-02)
50
62
 
51
63
  - (Gaspode) Breaking Change: Removed support of Closed API
package/io-package.json CHANGED
@@ -1,8 +1,21 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "alpha-ess",
4
- "version": "2.0.0",
4
+ "version": "2.0.1",
5
5
  "news": {
6
+ "2.0.1": {
7
+ "en": "Adapted timeout to new API restrictions",
8
+ "de": "Timeout Werte an neue API-Beschränkungen angepasst",
9
+ "ru": "Адаптированное таймирование к новым ограничениям API",
10
+ "pt": "Timeout adaptado para novas restrições de API",
11
+ "nl": "Vertaling:",
12
+ "fr": "Timeout adapté aux nouvelles restrictions de l'API",
13
+ "it": "Adeguato timeout alle nuove restrizioni API",
14
+ "es": "Tiempo de adaptación a nuevas restricciones de API",
15
+ "pl": "Zastosowany czas do nowych ograniczeń API",
16
+ "uk": "Адаптивний час для нових обмежень API",
17
+ "zh-cn": "A. 取消新优惠制度限制的时间"
18
+ },
6
19
  "2.0.0": {
7
20
  "en": "Breaking Change: Removed support of Closed API",
8
21
  "de": "Breaking Change: Entfernte Unterstützung von Closed API",
package/main.js CHANGED
@@ -13,7 +13,7 @@ const axios = require('axios').default;
13
13
 
14
14
  const OA_BaseURI = 'https://openapi.alphaess.com/api';
15
15
 
16
- const ReadAfterWriteTimeoutIntervalInS = 2;
16
+ const ReadAfterWriteTimeoutIntervalInS = 6;
17
17
 
18
18
  const REQUEST_TIMEOUT = 10000;
19
19
  const WATCHDOG_TIMER = 60000;
@@ -872,7 +872,6 @@ class OpenAPI {
872
872
  * @param {string} group
873
873
  */
874
874
  async writeConfigInfo(group, _updState, _updStateInfo) {
875
- const nextReadTimeout = ReadAfterWriteTimeoutIntervalInS;
876
875
  try {
877
876
  this.adapter.stopGroupWriteTimeout(group);
878
877
  this.adapter.stopGroupTimeout(group);
@@ -918,7 +917,7 @@ class OpenAPI {
918
917
  this.adapter.log.error('Writing data for group ' + group + ': Exception occurred: ' + e);
919
918
  await this.handleError(this.emptyBody, group);
920
919
  }
921
- this.adapter.startGroupTimeout(nextReadTimeout, group);
920
+ this.adapter.startGroupTimeout(ReadAfterWriteTimeoutIntervalInS, group);
922
921
  }
923
922
 
924
923
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.alpha-ess",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "Read and write data from and to Alpha ESS systems.",
5
5
  "author": {
6
6
  "name": "Gaspode",
@@ -20,7 +20,7 @@
20
20
  },
21
21
  "dependencies": {
22
22
  "@iobroker/adapter-core": "^3.0.4",
23
- "axios": "^1.6.2"
23
+ "axios": "^1.6.3"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@alcalzone/release-script": "^3.6.0",
@@ -41,15 +41,15 @@
41
41
  "@types/sinon-chai": "^3.2.12",
42
42
  "chai": "^4.3.10",
43
43
  "chai-as-promised": "^7.1.1",
44
- "eslint": "^8.54.0",
45
- "eslint-config-prettier": "^9.0.0",
44
+ "eslint": "^8.56.0",
45
+ "eslint-config-prettier": "^9.1.0",
46
46
  "eslint-plugin-prettier": "^5.0.1",
47
47
  "mocha": "^10.2.0",
48
- "prettier": "^3.1.0",
48
+ "prettier": "^3.1.1",
49
49
  "proxyquire": "^2.1.3",
50
50
  "sinon": "^17.0.1",
51
51
  "sinon-chai": "^3.7.0",
52
- "typescript": "~5.3.2"
52
+ "typescript": "~5.3.3"
53
53
  },
54
54
  "main": "main.js",
55
55
  "files": [