iobroker.eos-admin 9.0.19 → 9.0.21
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/NEXOWATT_EOS_BUILD_INFO.json +4 -4
- package/README.md +7 -3
- package/START_HIER_9.0.20.md +65 -0
- package/adminWww/.vite/manifest.json +39 -39
- package/adminWww/NEXOWATT_EOS_FRONTEND_MANIFEST.json +110 -109
- package/adminWww/assets/{AdapterUpdateDialog-JOf2z4Vg.js → AdapterUpdateDialog-Dxl_b7Op.js} +1 -1
- package/adminWww/assets/{Adapters-C9fcSdWm.js → Adapters-CVKKhXmI.js} +1 -1
- package/adminWww/assets/{ConfigManager-BeeLlT6D.js → ConfigManager-Bf6nTAkL.js} +1 -1
- package/adminWww/assets/{Enums-FqnXWl8U.js → Enums-CJHVJY7t.js} +1 -1
- package/adminWww/assets/{Fields-DMgrt5Pi.js → Fields-DWHbZKvm.js} +1 -1
- package/adminWww/assets/{Files-CIHtt12g.js → Files-a6owMTXA.js} +1 -1
- package/adminWww/assets/{Hosts-fPLBzvTy.js → Hosts-LtEMeXpV.js} +1 -1
- package/adminWww/assets/{Instances-4XaVQlrT.js → Instances-DhChziA1.js} +1 -1
- package/adminWww/assets/{Intro-5TKriiLO.js → Intro-Cyq9gVDC.js} +1 -1
- package/adminWww/assets/{Logs-33zcIds-.js → Logs-wcramXsg.js} +1 -1
- package/adminWww/assets/{Objects-CNQPVbNG.js → Objects-DINVHd_e.js} +1 -1
- package/adminWww/assets/{Overview-BskXGOc8.js → Overview-DK4R41zR.js} +1 -1
- package/adminWww/assets/{State-C8SJ_Iqo.js → State-DcEACXzL.js} +1 -1
- package/adminWww/assets/{UsedResources-CgqRa9ei.js → UsedResources-C1LcM0Rb.js} +1 -1
- package/adminWww/assets/{Users-0JVYWR9u.js → Users-DvDdSyDY.js} +1 -1
- package/adminWww/assets/{bootstrap-D16lu6rd.js → bootstrap-Dbj_GbnP.js} +3 -3
- package/adminWww/assets/{hostInit-C8YZJuzi.js → hostInit-BNFIx0-f.js} +1 -1
- package/adminWww/assets/icons/nexowatt-180.png +0 -0
- package/adminWww/assets/{icons-material-CiNJ_6Ur.js → icons-material-DVbdXNgr.js} +1 -1
- package/adminWww/assets/{index-DA9Sphgh.js → index-CoKP1NSA.js} +2 -2
- package/adminWww/assets/{installSVGRenderer-DPdkRa_d.js → installSVGRenderer-CMvku1F1.js} +1 -1
- package/adminWww/assets/{mf-entry-bootstrap-0-a7ab91de.js → mf-entry-bootstrap-0-ac330bce.js} +2 -2
- package/adminWww/index.html +24 -24
- package/adminWww/mf-manifest.json +1 -1
- package/adminWww/mf-stats.json +1 -1
- package/adminWww/{remoteEntry-eos-9.0.19.js → remoteEntry-eos-9.0.21.js} +1 -1
- package/adminWww/remoteEntry.js +1 -1
- package/build/lib/eosCustomerUpdateHttp.js +203 -0
- package/build/lib/eosCustomerUpdateHttp.js.map +1 -0
- package/build/lib/eosCustomerUpdateTransport.js +472 -0
- package/build/lib/eosCustomerUpdateTransport.js.map +1 -0
- package/build/lib/eosCustomerUpdateWorker.js +567 -0
- package/build/lib/eosCustomerUpdateWorker.js.map +1 -0
- package/build/lib/eosCustomerUpdates.js +631 -0
- package/build/lib/eosCustomerUpdates.js.map +1 -0
- package/build/lib/eosDeviceEmsPlan.js +18 -5
- package/build/lib/eosDeviceEmsPlan.js.map +1 -1
- package/build/lib/eosDeviceEmsService.js +52 -2
- package/build/lib/eosDeviceEmsService.js.map +1 -1
- package/build/lib/eosLegacyMigration.js +26 -1
- package/build/lib/eosLegacyMigration.js.map +1 -1
- package/build/lib/eosModuleConfigStore.js +12 -1
- package/build/lib/eosModuleConfigStore.js.map +1 -1
- package/build/lib/eosModuleHost.js +81 -26
- package/build/lib/eosModuleHost.js.map +1 -1
- package/build/lib/eosModuleHttp.js +8 -2
- package/build/lib/eosModuleHttp.js.map +1 -1
- package/build/lib/eosStateSubscriptions.js +59 -2
- package/build/lib/eosStateSubscriptions.js.map +1 -1
- package/build/lib/eosUpdateSnapshot.js +290 -0
- package/build/lib/eosUpdateSnapshot.js.map +1 -0
- package/build/lib/eosUploadGuard.js +124 -81
- package/build/lib/eosUploadGuard.js.map +1 -1
- package/build/lib/web.js +83 -0
- package/build/lib/web.js.map +1 -1
- package/docs/reports/unified-9.0.20/ANFORDERUNGEN_UND_INBETRIEBNAHME.md +159 -0
- package/docs/reports/unified-9.0.20/DEVICE_COMMAND_DELIVERY_REVIEW.md +82 -0
- package/docs/reports/unified-9.0.20/DEVICE_LIFECYCLE_REVIEW.md +46 -0
- package/docs/reports/unified-9.0.20/DEVICE_PLAN_REVIEW.md +33 -0
- package/docs/reports/unified-9.0.20/DEVICE_POWER_CAPABILITY_REVIEW.md +25 -0
- package/docs/reports/unified-9.0.20/FARM_CONTROLLER_REVIEW.md +27 -0
- package/docs/reports/unified-9.0.20/FARM_DIAGNOSE_UI.md +81 -0
- package/docs/reports/unified-9.0.20/FARM_DISPATCH_REVIEW.md +47 -0
- package/docs/reports/unified-9.0.20/HISTORY_REVIEW.md +68 -0
- package/docs/reports/unified-9.0.20/INFLUXDB2_INSTALLER_UI.md +39 -0
- package/docs/reports/unified-9.0.20/INFLUX_CREDENTIAL_NETWORK_REVIEW.md +38 -0
- package/docs/reports/unified-9.0.20/INFLUX_DIRECT_UNABHAENGIGE_PRUEFUNG.md +64 -0
- package/docs/reports/unified-9.0.20/INFLUX_RUNTIME_INTEGRATION_REVIEW.md +53 -0
- package/docs/reports/unified-9.0.20/INFLUX_RUNTIME_UNABHAENGIGE_PRUEFUNG.md +34 -0
- package/docs/reports/unified-9.0.20/INFLUX_TRANSPORT_ABSCHLUSSPRUEFUNG.md +55 -0
- package/docs/reports/unified-9.0.20/LOGIN_WEBAPP_LOGO.md +29 -0
- package/docs/reports/unified-9.0.20/MIGRATION_REVIEW.md +35 -0
- package/docs/reports/unified-9.0.20/PRUEFBERICHT.md +54 -0
- package/docs/reports/unified-9.0.20/PWA_ANONYMOUS_HTTPS_REVIEW.md +28 -0
- package/docs/reports/unified-9.0.20/PWA_ICON_UNABHAENGIGE_PRUEFUNG.md +60 -0
- package/docs/reports/unified-9.0.20/SERIAL_LIFECYCLE_REVIEW.md +37 -0
- package/docs/reports/unified-9.0.20/SOLAX_READBACK_REVIEW.md +43 -0
- package/docs/reports/unified-9.0.20/SOLAX_READBACK_UNABHAENGIGE_PRUEFUNG.md +34 -0
- package/docs/reports/unified-9.0.20/STATIC_REVIEW_DE.md +175 -0
- package/docs/reports/unified-9.0.20/STORAGE_COMMAND_ACK_REVIEW.md +36 -0
- package/docs/reports/unified-9.0.20/TARIFF_REPORT_REVIEW.md +29 -0
- package/docs/reports/unified-9.0.20/VISUALISIERUNG.md +64 -0
- package/docs/reports/unified-9.0.20/history-setup-navigation-proxy.txt +26 -0
- package/docs/reports/unified-9.0.20/history-setup-navigation-ssr.txt +7 -0
- package/docs/reports/unified-9.0.20/history-setup-ui-lint.txt +0 -0
- package/docs/reports/unified-9.0.20/history-setup-ui-node22.txt +102 -0
- package/docs/reports/unified-9.0.20/history-setup-ui-node24.txt +23 -0
- package/docs/reports/unified-9.0.20/history-setup-ui-security.txt +0 -0
- package/docs/reports/unified-9.0.20/history-setup-ui-typecheck.txt +0 -0
- package/docs/reports/unified-9.0.20/login-pwa-branding-hashes.txt +9 -0
- package/docs/reports/unified-9.0.20/login-pwa-branding-node22.txt +42 -0
- package/docs/reports/unified-9.0.20/login-pwa-branding-node24.txt +13 -0
- package/docs/reports/unified-9.0.20/raw/INDEX.json +1913 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/baseline-node22.log +16 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/baseline-node24.log +14 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/lint-after.json +1 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/lint-before.json +1 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/modbus-stop-backoff.cjs +22 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node22-control-review.log +29 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node22-modbus-final.json +18 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node22-modbus-final.log +325 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node22-modbus-review.log +278 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node24-modbus-final.json +18 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node24-modbus-final.log +58 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/device/node24-modbus-review.log +51 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/api-gaps-before.log +64 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/api-negative-before.log +46 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/chart-gaps-before.log +127 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-after.log +67 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-before.log +61 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-eslint-js.log +0 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-eslint-ts.log +0 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-node22.log +442 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/device-command-subscriptions-node24.log +78 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/fix.py +73 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-eslint-final.json +7 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-final-node22.log +279 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-final-node24.log +52 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-followup-node22.log +223 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-followup-node24.log +43 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/history-own-cache.log +17 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/negative-pricing-before.log +96 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/node22-after.log +66 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/node22-repro.log +8 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/node24-after.log +17 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/node24-repro.log +8 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/history/repro.cjs +39 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/visuals/chromium-probe.log +3 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/visuals/patch-live.py +101 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/visuals/repro-live-display.cjs +26 -0
- package/docs/reports/unified-9.0.20/raw/additional-audit/visuals/repro-live-display.log +36 -0
- package/docs/reports/unified-9.0.20/raw/audit-full.log +345 -0
- package/docs/reports/unified-9.0.20/raw/audit-full.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/audit-runtime.log +23 -0
- package/docs/reports/unified-9.0.20/raw/audit-runtime.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/backend-final.log +5 -0
- package/docs/reports/unified-9.0.20/raw/backend-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/baseline-919-coverage-tests-node22.result.json +20 -0
- package/docs/reports/unified-9.0.20/raw/baseline-919-coverage-tests-node22.tap +721 -0
- package/docs/reports/unified-9.0.20/raw/baseline-919-coverage-tests-node24.result.json +20 -0
- package/docs/reports/unified-9.0.20/raw/baseline-919-coverage-tests-node24.tap +127 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-evidence.json +69 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-failed-init-drain-919-before.log +14 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-final-node22.log +882 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-final-node24.log +149 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-lint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-planner-919-before.log +70 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-retained-readiness-before.log +34 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-runtime-retry-919-before.log +46 -0
- package/docs/reports/unified-9.0.20/raw/commissioning-types-node24.log +0 -0
- package/docs/reports/unified-9.0.20/raw/device-farm-protocol/DEVICE_FARM_READONLY_REVIEW.md +66 -0
- package/docs/reports/unified-9.0.20/raw/device-farm-protocol/run-readback-tests.cjs +13 -0
- package/docs/reports/unified-9.0.20/raw/device-farm-protocol/solax-control-chain.test.cjs +58 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-baseline-node22.log +16 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-baseline-node24.log +14 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-evidence.json +55 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-lint-after.json +1 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-lint-before.json +1 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-modbus-stop-backoff.cjs +22 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node22-control-review.log +29 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node22-modbus-final.json +18 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node22-modbus-final.log +325 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node22-modbus-review.log +278 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node24-modbus-final.json +18 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node24-modbus-final.log +58 -0
- package/docs/reports/unified-9.0.20/raw/device-lifecycle-node24-modbus-review.log +51 -0
- package/docs/reports/unified-9.0.20/raw/devices-hosted-typecheck-node22.log +0 -0
- package/docs/reports/unified-9.0.20/raw/devices-hosted-typecheck-node22.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/devices-hosted-typecheck-node24.log +0 -0
- package/docs/reports/unified-9.0.20/raw/devices-hosted-typecheck-node24.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/farm-controller/controller-node22.log +110 -0
- package/docs/reports/unified-9.0.20/raw/farm-controller/controller-node24.log +24 -0
- package/docs/reports/unified-9.0.20/raw/farm-controller/evidence.json +33 -0
- package/docs/reports/unified-9.0.20/raw/farm-diagnostics-ui-lint.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/farm-diagnostics-ui-node22.txt +113 -0
- package/docs/reports/unified-9.0.20/raw/farm-diagnostics-ui-node24.txt +26 -0
- package/docs/reports/unified-9.0.20/raw/farm-diagnostics-ui-security.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/farm-diagnostics-ui-typecheck.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/allocator-baseline.jsonl +6 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-before.log +138 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-main-delta.patch +77 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-main-lint.json +7 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-node22.log +64 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-node22.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-node24.log +18 -0
- package/docs/reports/unified-9.0.20/raw/farm-dispatch/diagnostics-node24.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/final-ui-independent-review.json +194 -0
- package/docs/reports/unified-9.0.20/raw/frontend-build.log +152 -0
- package/docs/reports/unified-9.0.20/raw/frontend-build.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-after-node22.json +35 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-after-node22.result.json +17 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-after-node24.json +31 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-after-node24.result.json +17 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-before.json +31 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/parser-reproducer.cjs +9 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/transport-extra-node22.result.json +18 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/transport-extra-node22.tap +34 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/transport-extra-node24.result.json +18 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/transport-extra-node24.tap +11 -0
- package/docs/reports/unified-9.0.20/raw/independent-influx/transport-extra.test.cjs +9 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/node22-focused.log +165 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/node24-focused.log +35 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/review-receipt.json +57 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/split-response-after.log +1 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/split-response-before.log +1 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/split-response.cjs +16 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/stop-race-generation-guard.log +1 -0
- package/docs/reports/unified-9.0.20/raw/independent-solax/stop-race.cjs +13 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct/eslint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct/node22.log +112 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct/node24.log +24 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct/typecheck.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/hosted-module-history.test.cjs +85 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/independent-node22.json +12 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/independent-node22.log +100 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/independent-node24.json +12 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/independent-node24.log +21 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/runtime-after.test.cjs +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/runtime-loss-before.test.cjs +9 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/security-scan.cjs +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-direct-review/transport-extra.test.cjs +9 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/legacy-history-node22.log +227 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/legacy-history-node22.result.json +11 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/legacy-history-node24.log +44 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/legacy-history-node24.result.json +11 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/node22.log +112 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/node22.result.json +12 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/node24.log +23 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/node24.result.json +12 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/runtime-after.test.cjs +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-independent/transport-extra.test.cjs +9 -0
- package/docs/reports/unified-9.0.20/raw/influx-runtime/evidence.json +24 -0
- package/docs/reports/unified-9.0.20/raw/influx-runtime/final-node22.log +326 -0
- package/docs/reports/unified-9.0.20/raw/influx-runtime/final-node24.log +59 -0
- package/docs/reports/unified-9.0.20/raw/influx-runtime/runtime-node22.log +62 -0
- package/docs/reports/unified-9.0.20/raw/influx-runtime/runtime-node24.log +16 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-lint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-lint.result.json +17 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-node22.log +112 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-node22.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-node24.log +106 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-node24.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-typecheck.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/security-influx-typecheck.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-security/source-sha256.json +5 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-lint-final.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-lint-final.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-node22-final.log +124 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-node22-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-node24-final.log +26 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-node24-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-type-node22-final.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-type-node22-final.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-type-node24-final.log +0 -0
- package/docs/reports/unified-9.0.20/raw/influx-transport-final/influx-transport-type-node24-final.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/influx-ui-independent-review-final.json +285 -0
- package/docs/reports/unified-9.0.20/raw/influx-ui-independent-review-intermediate.json +285 -0
- package/docs/reports/unified-9.0.20/raw/installer-build.log +26 -0
- package/docs/reports/unified-9.0.20/raw/installer-build.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/isolation/INDEX.json +332 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-final.log +3 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-final.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-hosted.log +6 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-hosted.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-verified.log +1 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family-verified.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family.log +11 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-family.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-final.log +3 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-final.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-hosted.log +3 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-hosted.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-verified.log +1 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid-verified.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid.log +11 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-fenecon-hybrid.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-final-node22.log +296 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-final-node22.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-final-node24.log +56 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-final-node24.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-node24.log +54 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-node24.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-output-modes.log +1 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-output-modes.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-final-node22.log +332 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-final-node22.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-final-node24.log +62 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-final-node24.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-node22.log +342 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-node22.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-node24.log +72 -0
- package/docs/reports/unified-9.0.20/raw/isolation/command-ack-release-node24.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/isolation-node22.log +482 -0
- package/docs/reports/unified-9.0.20/raw/isolation/isolation-node22.result.json +19 -0
- package/docs/reports/unified-9.0.20/raw/isolation/isolation-node24.log +87 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-lint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-lint.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node22.log +330 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node22.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node24-before.log +72 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node24-before.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node24.log +60 -0
- package/docs/reports/unified-9.0.20/raw/isolation/migration-node24.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/isolation/repro-migration-start-budget.cjs +49 -0
- package/docs/reports/unified-9.0.20/raw/isolation/repro-serial-release.cjs +21 -0
- package/docs/reports/unified-9.0.20/raw/isolation/repro-sunspec-discovery.cjs +11 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-before-repro.log +1 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-before-repro.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-gates-node22.log +32 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-gates-node22.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-gates-node24.log +11 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-gates-node24.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-helper-typecheck-final.log +0 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-helper-typecheck-final.result.json +28 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-helper-typecheck.log +2 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-helper-typecheck.result.json +26 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-lint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-lint.result.json +18 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-node22.log +344 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-node22.result.json +17 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-node24.log +62 -0
- package/docs/reports/unified-9.0.20/raw/isolation/serial-node24.result.json +17 -0
- package/docs/reports/unified-9.0.20/raw/isolation/sunspec-review-after.log +3 -0
- package/docs/reports/unified-9.0.20/raw/isolation/sunspec-review-after.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/isolation/sunspec-review-before.log +3 -0
- package/docs/reports/unified-9.0.20/raw/isolation/sunspec-review-before.result.json +15 -0
- package/docs/reports/unified-9.0.20/raw/keygen-source.json +6 -0
- package/docs/reports/unified-9.0.20/raw/legacy-mirror-debt/check-919.log +70 -0
- package/docs/reports/unified-9.0.20/raw/legacy-mirror-debt/check-920.log +71 -0
- package/docs/reports/unified-9.0.20/raw/legacy-mirror-debt/diff.json +82 -0
- package/docs/reports/unified-9.0.20/raw/legacy-mirror-debt/receipt.json +48 -0
- package/docs/reports/unified-9.0.20/raw/lint-final.log +16 -0
- package/docs/reports/unified-9.0.20/raw/lint-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/main-individual-review-before-cache-boundary-fix.json +112 -0
- package/docs/reports/unified-9.0.20/raw/main-individual-review-before-capability-ack.json +103 -0
- package/docs/reports/unified-9.0.20/raw/main-individual-review-before-farm-diagnostics.json +102 -0
- package/docs/reports/unified-9.0.20/raw/main-individual-review-final.json +103 -0
- package/docs/reports/unified-9.0.20/raw/main-individual-review.json +93 -0
- package/docs/reports/unified-9.0.20/raw/modules-build.log +5 -0
- package/docs/reports/unified-9.0.20/raw/modules-build.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/node22-tests-final.log +12471 -0
- package/docs/reports/unified-9.0.20/raw/node22-tests-final.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/node22-typecheck-final.log +7 -0
- package/docs/reports/unified-9.0.20/raw/node22-typecheck-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/node22-version.log +1 -0
- package/docs/reports/unified-9.0.20/raw/node24-tests-final.log +2093 -0
- package/docs/reports/unified-9.0.20/raw/node24-tests-final.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/node24-typecheck-final.log +5 -0
- package/docs/reports/unified-9.0.20/raw/node24-typecheck-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/node24-version.log +1 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/evidence.json +69 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/power-capability-existing-regressions-node24.log +94 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/power-capability-lint.log +0 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/power-capability-node22.log +304 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/power-capability-node24.log +56 -0
- package/docs/reports/unified-9.0.20/raw/power-capability/power-capability-typecheck.log +0 -0
- package/docs/reports/unified-9.0.20/raw/pwa-https/evidence.json +45 -0
- package/docs/reports/unified-9.0.20/raw/pwa-https/node22-build.log +21 -0
- package/docs/reports/unified-9.0.20/raw/pwa-https/node22-source.log +23 -0
- package/docs/reports/unified-9.0.20/raw/pwa-https/node24-build.log +11 -0
- package/docs/reports/unified-9.0.20/raw/pwa-https/node24-source.log +11 -0
- package/docs/reports/unified-9.0.20/raw/pwa-independent/policy-boundaries.test.cjs +45 -0
- package/docs/reports/unified-9.0.20/raw/pwa-independent/policy-receipt.json +71 -0
- package/docs/reports/unified-9.0.20/raw/pwa-independent/policy-v22.23.4.tap +34 -0
- package/docs/reports/unified-9.0.20/raw/pwa-independent/policy-v24.22.3.tap +11 -0
- package/docs/reports/unified-9.0.20/raw/pwa-ui-independent-review-final.json +348 -0
- package/docs/reports/unified-9.0.20/raw/repro-failed-init-drain-before.cjs +15 -0
- package/docs/reports/unified-9.0.20/raw/repro-profile-replacement-after-unmapped.cjs +15 -0
- package/docs/reports/unified-9.0.20/raw/repro-runtime-retry-before.cjs +18 -0
- package/docs/reports/unified-9.0.20/raw/sbom-runtime.log +7 -0
- package/docs/reports/unified-9.0.20/raw/sbom-runtime.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/sbom-vendor-check.log +1 -0
- package/docs/reports/unified-9.0.20/raw/sbom-vendor-check.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/solax-readback-node22.json +30 -0
- package/docs/reports/unified-9.0.20/raw/solax-readback-node22.log +542 -0
- package/docs/reports/unified-9.0.20/raw/solax-readback-node24.json +30 -0
- package/docs/reports/unified-9.0.20/raw/solax-readback-node24.log +97 -0
- package/docs/reports/unified-9.0.20/raw/tariff-report-before.log +147 -0
- package/docs/reports/unified-9.0.20/raw/tariff-report-evidence.json +48 -0
- package/docs/reports/unified-9.0.20/raw/tariff-report-final-node22.log +151 -0
- package/docs/reports/unified-9.0.20/raw/tariff-report-final-node24.log +32 -0
- package/docs/reports/unified-9.0.20/raw/ui-docs-check.log +6 -0
- package/docs/reports/unified-9.0.20/raw/ui-docs-check.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-runtime-final.log +7 -0
- package/docs/reports/unified-9.0.20/raw/ui-runtime-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-runtime-sync.log +6 -0
- package/docs/reports/unified-9.0.20/raw/ui-runtime-sync.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-sbom-check.log +6 -0
- package/docs/reports/unified-9.0.20/raw/ui-sbom-check.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-sbom-final.log +6 -0
- package/docs/reports/unified-9.0.20/raw/ui-sbom-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-secret-final.log +6 -0
- package/docs/reports/unified-9.0.20/raw/ui-secret-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/ui-security-final.log +8 -0
- package/docs/reports/unified-9.0.20/raw/ui-security-final.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/visuals-baseline-919.txt +36 -0
- package/docs/reports/unified-9.0.20/raw/visuals-browser-limit.txt +3 -0
- package/docs/reports/unified-9.0.20/raw/visuals-lint.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/visuals-node22.txt +258 -0
- package/docs/reports/unified-9.0.20/raw/visuals-node24.txt +51 -0
- package/docs/reports/unified-9.0.20/raw/visuals-security.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/visuals-typecheck.txt +0 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-after.log +19 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-after.result.json +16 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-before.log +31 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-before.result.json +14 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-independent.result.json +13 -0
- package/docs/reports/unified-9.0.20/raw/wallet-freshness-independent.tap +10 -0
- package/io-package.json +12 -12
- package/modules/backup/admin/index.js +4 -1
- package/modules/devices/admin/host-bridge.js +5 -1
- package/modules/devices/lib/device-alias-semantics-v1.json +22 -1
- package/modules/devices/lib/deviceAliasFreshness.js +1 -0
- package/modules/devices/lib/deviceAliasSemantics.js +13 -3
- package/modules/devices/lib/deviceRuntime.js +106 -12
- package/modules/devices/lib/drivers/modbus.js +90 -21
- package/modules/devices/lib/drivers/modbusAsciiBus.js +47 -31
- package/modules/devices/lib/drivers/modbusRtuBus.js +33 -9
- package/modules/devices/lib/drivers/modbusSerialLease.js +29 -0
- package/modules/devices/lib/drivers/mqtt.js +204 -82
- package/modules/devices/lib/drivers/mqttPendingOperations.js +119 -0
- package/modules/devices/lib/modbusReadEvidence.js +29 -0
- package/modules/devices/test/deviceAliasFreshness.test.js +7 -2
- package/modules/devices/test/modbusConnectLifecycle.test.js +148 -0
- package/modules/devices/test/modbusSerialLifecycle.test.js +91 -0
- package/modules/devices/test/mqttCommandLifecycle.test.js +255 -0
- package/modules/devices/test/mqttResourceBounds.test.js +98 -0
- package/modules/devices/test/mqttRuntimeSession.test.js +109 -0
- package/modules/devices/test/serialOperationGate.test.js +3 -3
- package/modules/devices/test/solaxReadbackContext.test.js +472 -0
- package/modules/devices/tsconfig.alias-semantics.json +1 -1
- package/modules/devices/tsconfig.mqtt-lifecycle.json +20 -0
- package/modules/devices/tsconfig.serial-lifecycle.json +18 -0
- package/modules/eebus/admin/index.js +6 -3
- package/package.json +9 -7
- package/release-manifests/unified/build-environment.cdx.json +6 -6
- package/release-manifests/unified/files.json +848 -169
- package/release-manifests/unified/frontend.cdx.json +6 -6
- package/release-manifests/unified/installer.cdx.json +6 -6
- package/release-manifests/unified/obsolete-admin-assets.json +154 -6
- package/release-manifests/unified/runtime.cdx.json +25 -25
- package/release-manifests/unified/validation.json +15 -15
- package/tools/eos-release-check.cjs +2 -2
- package/tools/eos-release-manifest.cjs +3 -3
- package/ui/admin/react/assets/index-BJO3q7oe.js +13 -0
- package/ui/admin/react/assets/{index-CuquHlsY.css → index-ofLP_Y7y.css} +1 -1
- package/ui/admin/react/index.html +2 -2
- package/ui/docs/security/eslint-reviewed-findings.json +91 -35
- package/ui/ems/engine.js +14 -3
- package/ui/ems/modules/energy-wallet.js +9 -3
- package/ui/ems/modules/storage-control.js +60 -19
- package/ui/ems/modules/tariff-provider.js +34 -10
- package/ui/ems/services/tariff-provider-registry.js +18 -8
- package/ui/io-package.json +1 -1
- package/ui/lib/influx-config.js +204 -0
- package/ui/lib/influx-direct.js +527 -0
- package/ui/lib/influx-history-runtime.js +326 -0
- package/ui/lib/influx-network-policy.js +112 -0
- package/ui/lib/ui-access-policy.js +2 -2
- package/ui/main.js +614 -255
- package/ui/package.json +12 -6
- package/ui/www/app.js +152 -203
- package/ui/www/ems-apps.html +2 -1
- package/ui/www/ems-apps.js +8 -1
- package/ui/www/energy-ledger.html +1 -1
- package/ui/www/eos-updates.css +15 -0
- package/ui/www/eos-updates.js +351 -0
- package/ui/www/evcs.html +1 -1
- package/ui/www/history.html +1 -1
- package/ui/www/history.js +114 -74
- package/ui/www/index.html +4 -1
- package/ui/www/live-display.js +115 -0
- package/ui/www/logic.html +1 -1
- package/ui/www/login.css +1 -0
- package/ui/www/login.html +2 -1
- package/ui/www/manifest.webmanifest +3 -3
- package/ui/www/settings.html +36 -1
- package/ui/www/simulation.html +1 -1
- package/ui/www/smarthome-config.html +1 -1
- package/ui/www/smarthome.html +1 -1
- package/ui/www/storagefarm-dispatch.js +287 -0
- package/ui/www/storagefarm-summary.css +15 -0
- package/ui/www/storagefarm.html +15 -1
- package/ui/www/storagefarm.js +8 -26
- package/ui/www/tariff-report.js +43 -25
- package/ui/admin/react/assets/index-Bq5IupDw.js +0 -13
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"command": [
|
|
3
|
+
"node",
|
|
4
|
+
"--test",
|
|
5
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/runtime-after.test.cjs",
|
|
6
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/transport-extra.test.cjs",
|
|
7
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/hosted-module-history.test.cjs"
|
|
8
|
+
],
|
|
9
|
+
"start": "2026-11-24T20:40:00.026527+00:00",
|
|
10
|
+
"exitCode": 0,
|
|
11
|
+
"logSha256": "2a6ac9c75fe261cd0de7f55e437a073c3dc7245d06ef7c2f2cbb3f9ae577dc28"
|
|
12
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
✔ actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=false) (23.282452ms)
|
|
2
|
+
✔ actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=true) (7.409535ms)
|
|
3
|
+
✔ actual Para14a publication retains source timestamp; denied and failed state writes never reach Influx (3.778669ms)
|
|
4
|
+
✔ unregistered physical states remain outside direct historian scope (1.066115ms)
|
|
5
|
+
✔ bad string and oversized ID cannot poison a valid queued measurement (2.378661ms)
|
|
6
|
+
✔ eight pending real HTTP history queries retain writer capacity and original sample timestamp (24.946919ms)
|
|
7
|
+
✔ reconfiguration fences captured old writes and late active completions from new queue accounting (0.552883ms)
|
|
8
|
+
✔ normal drain flushes queued values, rejects late captures and commits, and closes once complete (0.526844ms)
|
|
9
|
+
✔ drain deadline is bounded and counts the unconfirmed active point without a fake success (19.376501ms)
|
|
10
|
+
✔ legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian (0.436947ms)
|
|
11
|
+
✔ truncated CSV response aborts instead of returning partial chart or fabricated values (21.033626ms)
|
|
12
|
+
✔ response byte budget aborts a real large stream and frees concurrent capacity (49.893956ms)
|
|
13
|
+
✔ explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros (5.180879ms)
|
|
14
|
+
ℹ tests 13
|
|
15
|
+
ℹ suites 0
|
|
16
|
+
ℹ pass 13
|
|
17
|
+
ℹ fail 0
|
|
18
|
+
ℹ cancelled 0
|
|
19
|
+
ℹ skipped 0
|
|
20
|
+
ℹ todo 0
|
|
21
|
+
ℹ duration_ms 299.383496
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const test=require('node:test'),assert=require('node:assert/strict'),http=require('node:http'),{createRequire}=require('node:module');
|
|
3
|
+
const req=createRequire('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/package.json');
|
|
4
|
+
const load=name=>req('tsx/cjs/api').require(`/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/ui/src-ts/runtime-executables/lib/${name}.ts`,__filename);
|
|
5
|
+
const {InfluxHistoryRuntime}=load('influx-history-runtime'),{influxLineProtocol}=load('influx-direct');
|
|
6
|
+
const config={url:'http://127.0.0.1:8086',organization:'org',bucket:'b',token:'synthetic-review'};
|
|
7
|
+
const deferred=()=>{let resolve;const promise=new Promise(done=>resolve=done);return {promise,resolve};};
|
|
8
|
+
const point=(runtime,val=123,ts=Date.now())=>runtime.capture('historie.good',{val,ack:true,ts});
|
|
9
|
+
const setup=(factory)=>{const runtime=new InfluxHistoryRuntime('eos-admin.0',factory);runtime.configure({provider:'influxdb2',influxdb2:config});runtime.register('historie.good');return runtime;};
|
|
10
|
+
test('bad string and oversized ID cannot poison a valid queued measurement',async()=>{const sent=[];const runtime=setup(()=>({query:async()=>({result:[]}),close(){},async write(points){sent.push(points);influxLineProtocol(points);}}));runtime.register('historie.text');assert.equal(runtime.register('x'.repeat(512)),false);const ts=Date.now();runtime.commit(point(runtime,123,ts));for(const val of ['line1\nline2','\u0000','\r'])assert.equal(runtime.capture('historie.text',{val,ack:true,ts}),null);await runtime.flush();assert.equal(sent.length,1);assert.deepEqual(sent[0],[{id:'eos-admin.0.historie.good',val:123,ts}]);assert.equal(runtime.status().droppedPoints,0);runtime.close();});
|
|
11
|
+
test('eight pending real HTTP history queries retain writer capacity and original sample timestamp',async t=>{let reads=0;const writes=[];const server=http.createServer(async(request,response)=>{if(request.url.startsWith('/api/v2/write')){let body='';for await(const data of request)body+=data;writes.push(body);response.statusCode=204;response.end();}else reads++;});await new Promise(done=>server.listen(0,'127.0.0.1',done));const runtime=new InfluxHistoryRuntime('eos-admin.0');runtime.configure({provider:'influxdb2',influxdb2:{...config,url:`http://127.0.0.1:${server.address().port}`}});t.after(async()=>{runtime.close();server.closeAllConnections();await new Promise(done=>server.close(done));});const pending=Promise.allSettled(Array.from({length:8},()=>runtime.query('eos-admin.0.historie.good',{start:1,end:1000})));runtime.register('historie.good');const ts=Date.now()-1234;runtime.commit(point(runtime,0,ts));await runtime.flush();assert.equal(writes[0],`eos-admin.0.historie.good value=0 ${ts}`);assert.ok(reads<=6);assert.equal(runtime.status().droppedPoints,0);assert.equal(runtime.status().writeVerified,true);runtime.close();await pending;});
|
|
12
|
+
test('reconfiguration fences captured old writes and late active completions from new queue accounting',async()=>{const old=deferred(),entered=deferred();let generation=0,closed=0;const calls=[];const runtime=setup(()=>{const current=++generation;return{close(){closed++;},query:async()=>({result:[]}),async write(points){calls.push({current,points});if(current===1){entered.resolve();await old.promise;}}};});const capture=point(runtime,1);runtime.commit(capture);const first=runtime.flush();await entered.promise;runtime.configure({provider:'influxdb2',influxdb2:{...config,bucket:'new'}});runtime.commit(capture);runtime.commit(point(runtime,2));await runtime.flush();const before=runtime.status();assert.equal(before.droppedPoints,1);assert.equal(before.queueDepth,0);old.resolve();await first;assert.deepEqual(runtime.status(),before);assert.equal(calls.length,2);assert.equal(calls[1].points[0].val,2);assert.equal(closed,1);runtime.close();});
|
|
13
|
+
test('normal drain flushes queued values, rejects late captures and commits, and closes once complete',async()=>{const pending=deferred(),entered=deferred();let close=0;const runtime=setup(()=>({close(){close++;},query:async()=>({result:[]}),async write(){entered.resolve();await pending.promise;}}));const captured=point(runtime);runtime.commit(captured);const flushing=runtime.flush();await entered.promise;const drain=runtime.drainAndClose(1000);assert.equal(runtime.capture('historie.good',{val:2,ack:true,ts:Date.now()}),null);runtime.commit(captured);assert.equal(runtime.status().queueDepth,1);pending.resolve();await Promise.all([flushing,drain]);assert.equal(close,1);assert.equal(runtime.status().state,'closed');assert.equal(runtime.status().droppedPoints,0);});
|
|
14
|
+
test('drain deadline is bounded and counts the unconfirmed active point without a fake success',async()=>{let close=0;const entered=deferred();const runtime=setup(()=>({close(){close++;},query:async()=>({result:[]}),async write(){entered.resolve();await new Promise(()=>{});}}));runtime.commit(point(runtime));void runtime.flush();await entered.promise;await runtime.drainAndClose(20);assert.equal(close,1);assert.equal(runtime.status().state,'closed');assert.equal(runtime.status().droppedPoints,1);assert.equal(runtime.status().writeVerified,false);});
|
|
15
|
+
test('legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian',async()=>{let made=0;const runtime=new InfluxHistoryRuntime('eos-admin.0',()=>{made++;return{close(){},query:async()=>({result:[]}),write:async()=>{}}});runtime.register('historie.good');runtime.configure(undefined);assert.equal(made,0);assert.equal(runtime.status().provider,'adapter');assert.equal(point(runtime),null);runtime.configure({provider:'influxdb2',influxdb2:config});for(const state of [{val:null,ack:true},{val:NaN,ack:true},{val:1,ack:false},{val:1,ack:true,q:64}])assert.equal(runtime.capture('historie.good',{ts:Date.now(),...state}),null);runtime.close();});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const test=require('node:test'),assert=require('node:assert/strict'),http=require('node:http'),{createRequire}=require('node:module');
|
|
3
|
+
const req=createRequire('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/package.json');
|
|
4
|
+
const load=name=>req('tsx/cjs/api').require(`/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/ui/src-ts/runtime-executables/lib/${name}.ts`,__filename);
|
|
5
|
+
const {InfluxHistoryRuntime}=load('influx-history-runtime');
|
|
6
|
+
const {influxLineProtocol}=load('influx-direct');
|
|
7
|
+
const config={url:'http://127.0.0.1:8086',organization:'org',bucket:'b',token:'synthetic-review'};
|
|
8
|
+
test('before: malformed registered string poisons valid numeric point in same batch',async()=>{const sent=[];const runtime=new InfluxHistoryRuntime('eos-admin.0',()=>({query:async()=>({result:[]}),close(){},async write(points){sent.push(points);influxLineProtocol(points);}}));runtime.configure({provider:'influxdb2',influxdb2:config});runtime.register('historie.good');runtime.register('historie.text');const ts=Date.now();runtime.commit(runtime.capture('historie.good',{val:123,ack:true,ts}));runtime.commit(runtime.capture('historie.text',{val:'line1\nline2',ack:true,ts}));await runtime.flush();console.log('mixedBatch',JSON.stringify({attempts:sent.length,status:runtime.status()}));assert.equal(runtime.status().droppedPoints,2);runtime.close();});
|
|
9
|
+
test('before: actual eight HTTP queries make both immediate write retries BUSY and lose a valid point',async t=>{const open=[];const server=http.createServer((req,res)=>{open.push(res);});await new Promise(done=>server.listen(0,'127.0.0.1',done));const runtime=new InfluxHistoryRuntime('eos-admin.0');runtime.configure({provider:'influxdb2',influxdb2:{...config,url:`http://127.0.0.1:${server.address().port}`}});t.after(async()=>{runtime.close();server.closeAllConnections();await new Promise(done=>server.close(done));});const pending=Promise.allSettled(Array.from({length:8},()=>runtime.query('eos-admin.0.historie.good',{start:1,end:1000})));runtime.register('historie.good');runtime.commit(runtime.capture('historie.good',{val:123,ack:true,ts:Date.now()}));await runtime.flush();console.log('busyBatch',JSON.stringify(runtime.status()));assert.equal(runtime.status().lastError,'EOS_INFLUX_BUSY');assert.equal(runtime.status().droppedPoints,1);runtime.close();await pending;});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const fs=require('node:fs'),path=require('node:path'),crypto=require('node:crypto'),{createRequire}=require('node:module');
|
|
3
|
+
const root='/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin';
|
|
4
|
+
const helperPath=path.join(root,'ui/scripts/verify-eslint-security.cjs');const req=createRequire(helperPath);const {ESLint}=req('eslint');const h=req(helperPath);
|
|
5
|
+
(async()=>{
|
|
6
|
+
const start=new Date().toISOString();const baseline=req(path.join(root,'ui/docs/security/eslint-legacy-baseline.json')).findings;const reviewed=req(path.join(root,'ui/docs/security/eslint-reviewed-findings.json')).findings;
|
|
7
|
+
const files=h.sourceFiles();const before=new Map(files.map(f=>[f,crypto.createHash('sha256').update(fs.readFileSync(f)).digest('hex')]));
|
|
8
|
+
const findings=await h.collect(new ESLint({cwd:h.ROOT}),files);const result=h.evaluate(findings,baseline,reviewed);
|
|
9
|
+
const keys=['src-ts/runtime-executables/main.ts','src-ts/runtime-executables/www/ems-apps.ts','src-ts/runtime-executables/ems/modules/storage-control.ts','src-ts/runtime-executables/www/storagefarm-dispatch.ts','src-ts/runtime-executables/lib/influx-direct.ts','src-ts/runtime-executables/lib/influx-config.ts','src-ts/runtime-executables/lib/influx-network-policy.ts','src-ts/runtime-executables/lib/influx-history-runtime.ts','src-admin-tab/src/lib/adminConnection.ts','src-admin-tab/src/lib/historySetup.ts','src-admin-tab/src/pages/HistorySetupPage.tsx'];
|
|
10
|
+
const scopes=keys.map(file=>{const full=path.join(h.ROOT,file),source=fs.readFileSync(full,'utf8');const actual=findings.filter(f=>f.file===file);const rev=reviewed.filter(f=>f.file===file);const inv=h.inventory(actual);const r=h.evaluate(actual,baseline.filter(f=>f.file===file),rev);return {file,rawSha256:crypto.createHash('sha256').update(source).digest('hex'),sourceCodeSha256:h.codeSha256(file,source),current:actual.length,historicalOpen:r.legacyCarried,reviewedOccurrences:r.individuallyReviewed,newBlocked:r.introduced,absent:r.absent,reviewedMatches:rev.map(old=>({fingerprint:old.fingerprint,rule:old.rule,expectedCount:old.count,actualCount:inv.find(f=>f.fingerprint===old.fingerprint&&f.rule===old.rule)?.count||0,line:inv.find(f=>f.fingerprint===old.fingerprint&&f.rule===old.rule)?.line||0,reason:old.reason,oldCodeSha256:old.sourceCodeSha256}))};});
|
|
11
|
+
const changedDuring=files.filter(f=>before.get(f)!==crypto.createHash('sha256').update(fs.readFileSync(f)).digest('hex')).map(f=>path.relative(h.ROOT,f));
|
|
12
|
+
const bindingHashDrift=reviewed.filter(f=>h.codeSha256(f.file,fs.readFileSync(path.join(h.ROOT,f.file),'utf8'))!==f.sourceCodeSha256).map(f=>({file:f.file,fingerprint:f.fingerprint}));
|
|
13
|
+
const report={startedAt:start,finishedAt:new Date().toISOString(),eslintVersion:ESLint.version,files:files.length,currentFindings:findings.length,unresolvedCarriedFindings:result.legacyCarried,individuallyReviewedFindings:result.individuallyReviewed,newlyBlockedFindings:result.introduced.length,baselineFindingsAbsent:result.absent,blocked:result.introduced,changedDuring,bindingHashDrift,scopes,limitation:'Fingerprint regression scan and individually reviewed fixed boundaries, not a blanket resolution of carried findings or CRA/ASVS certification.'};
|
|
14
|
+
const dest=path.join(root,'docs/reports/unified-9.0.20/raw/influx-ui-independent-review-final.json');fs.writeFileSync(dest,JSON.stringify(report,null,2)+'\n');console.log(JSON.stringify({files:report.files,currentFindings:report.currentFindings,historical:report.unresolvedCarriedFindings,reviewed:report.individuallyReviewedFindings,blocked:report.blocked,changedDuring:report.changedDuring,bindingHashDrift:report.bindingHashDrift},null,2));process.exitCode=(result.introduced.length||changedDuring.length||scopes.some(s=>s.reviewedMatches.some(m=>m.actualCount!==m.expectedCount)))?1:0;
|
|
15
|
+
})().catch(e=>{console.error(e);process.exitCode=1;});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const test=require('node:test'),assert=require('node:assert/strict'),http=require('node:http');
|
|
3
|
+
const {createRequire}=require('node:module');
|
|
4
|
+
const req=createRequire('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/package.json');
|
|
5
|
+
const {InfluxDirectClient}=req('tsx/cjs/api').require('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/ui/src-ts/runtime-executables/lib/influx-direct.ts',__filename);
|
|
6
|
+
async function fixture(t,listener){const server=http.createServer(listener);await new Promise(done=>server.listen(0,'127.0.0.1',done));const client=new InfluxDirectClient({url:`http://127.0.0.1:${server.address().port}/influx/`,organization:'org',bucket:'bucket',token:'synthetic-review'});t.after(async()=>{client.close();server.closeAllConnections();await new Promise(done=>server.close(done));});return client;}
|
|
7
|
+
test('truncated CSV response aborts instead of returning partial chart or fabricated values',async t=>{const client=await fixture(t,(_req,res)=>{res.writeHead(200,{'Content-Length':'900'});res.write('#datatype,string,long,dateTime:RFC3339,double\n,result,table,_time,_value\n,,0,2026-11-24T00:00:00Z,1\n');setImmediate(()=>res.destroy());});await assert.rejects(client.query('state',{start:1,end:1000}),/EOS_INFLUX_RESPONSE_INVALID|EOS_INFLUX_CONNECTION_FAILED/);});
|
|
8
|
+
test('response byte budget aborts a real large stream and frees concurrent capacity',async t=>{let calls=0;const client=await fixture(t,(request,res)=>{assert.equal(request.url,'/influx/api/v2/query?org=org');calls++;if(calls===1){res.writeHead(200);res.end(Buffer.alloc(8*1024*1024+1,120));}else res.end('');});await assert.rejects(client.query('state',{start:1,end:1000}),/EOS_INFLUX_RESPONSE_LIMIT/);assert.deepEqual(await client.query('state',{start:1,end:1000}),{result:[]});});
|
|
9
|
+
test('explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros',async t=>{const requests=[];const client=await fixture(t,async(request,res)=>{let body='';for await(const data of request)body+=data;requests.push({url:request.url,body});res.statusCode=requests.length===1?503:204;res.end();});const points=[{id:'eos-admin.0.historie.power',val:0,ts:1795478400123}];await assert.rejects(client.write(points),/EOS_INFLUX_REQUEST_FAILED/);await client.write(points);assert.deepEqual(requests[0],requests[1]);assert.match(requests[0].body,/value=0 1795478400123$/);});
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
TAP version 13
|
|
2
|
+
# (node:63) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
3
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
4
|
+
# Subtest: periodic canonical samples stop holding through outages; legacy sparse mappings still hold
|
|
5
|
+
ok 1 - periodic canonical samples stop holding through outages; legacy sparse mappings still hold
|
|
6
|
+
---
|
|
7
|
+
duration_ms: 7.29902
|
|
8
|
+
type: 'test'
|
|
9
|
+
...
|
|
10
|
+
# Subtest: canonical hold follows configured export cadence rather than an arbitrary device TTL
|
|
11
|
+
ok 2 - canonical hold follows configured export cadence rather than an arbitrary device TTL
|
|
12
|
+
---
|
|
13
|
+
duration_ms: 1.553989
|
|
14
|
+
type: 'test'
|
|
15
|
+
...
|
|
16
|
+
# Subtest: charge-point sum retains an outage when any configured member has no periodic sample
|
|
17
|
+
ok 3 - charge-point sum retains an outage when any configured member has no periodic sample
|
|
18
|
+
---
|
|
19
|
+
duration_ms: 2.49697
|
|
20
|
+
type: 'test'
|
|
21
|
+
...
|
|
22
|
+
# Subtest: History API retains signed canonical EUR prices, fixed fee split and genuine zero
|
|
23
|
+
ok 4 - History API retains signed canonical EUR prices, fixed fee split and genuine zero
|
|
24
|
+
---
|
|
25
|
+
duration_ms: 6.682552
|
|
26
|
+
type: 'test'
|
|
27
|
+
...
|
|
28
|
+
# Subtest: missing and invalid manual prices are not synthesized into free History quotes
|
|
29
|
+
ok 5 - missing and invalid manual prices are not synthesized into free History quotes
|
|
30
|
+
---
|
|
31
|
+
duration_ms: 6.928312
|
|
32
|
+
type: 'test'
|
|
33
|
+
...
|
|
34
|
+
# Subtest: asynchronous malformed History payloads cannot throw out of the callback
|
|
35
|
+
ok 6 - asynchronous malformed History payloads cannot throw out of the callback
|
|
36
|
+
---
|
|
37
|
+
duration_ms: 9.041373
|
|
38
|
+
type: 'test'
|
|
39
|
+
...
|
|
40
|
+
# Subtest: valid numeric zero stays zero, null does not create measured zero, supported envelopes agree
|
|
41
|
+
ok 7 - valid numeric zero stays zero, null does not create measured zero, supported envelopes agree
|
|
42
|
+
---
|
|
43
|
+
duration_ms: 34.771624
|
|
44
|
+
type: 'test'
|
|
45
|
+
...
|
|
46
|
+
# Subtest: one five-second deadline includes fallback rounds and ignores late responses
|
|
47
|
+
ok 8 - one five-second deadline includes fallback rounds and ignores late responses
|
|
48
|
+
---
|
|
49
|
+
duration_ms: 5.11507
|
|
50
|
+
type: 'test'
|
|
51
|
+
...
|
|
52
|
+
# Subtest: shutdown cancels History reads and new reads fail without starting transports
|
|
53
|
+
ok 9 - shutdown cancels History reads and new reads fail without starting transports
|
|
54
|
+
---
|
|
55
|
+
duration_ms: 3.016682
|
|
56
|
+
type: 'test'
|
|
57
|
+
...
|
|
58
|
+
# Subtest: thrown and rejected transports become bounded API errors with sibling cleanup
|
|
59
|
+
ok 10 - thrown and rejected transports become bounded API errors with sibling cleanup
|
|
60
|
+
---
|
|
61
|
+
duration_ms: 3.009642
|
|
62
|
+
type: 'test'
|
|
63
|
+
...
|
|
64
|
+
# Subtest: oversized raw response stops processing and cleans all pending branches
|
|
65
|
+
ok 11 - oversized raw response stops processing and cleans all pending branches
|
|
66
|
+
---
|
|
67
|
+
duration_ms: 1.276191
|
|
68
|
+
type: 'test'
|
|
69
|
+
...
|
|
70
|
+
# Subtest: invalid and allocation-amplifying ranges are rejected before provider work
|
|
71
|
+
ok 12 - invalid and allocation-amplifying ranges are rejected before provider work
|
|
72
|
+
---
|
|
73
|
+
duration_ms: 5.141462
|
|
74
|
+
type: 'test'
|
|
75
|
+
...
|
|
76
|
+
# Subtest: day, week, month, leap-year and six-hour annual-report presets preserve finite output bounds
|
|
77
|
+
ok 13 - day, week, month, leap-year and six-hour annual-report presets preserve finite output bounds
|
|
78
|
+
---
|
|
79
|
+
duration_ms: 16.21888
|
|
80
|
+
type: 'test'
|
|
81
|
+
...
|
|
82
|
+
# Subtest: identical requests share work; a fifth distinct computation gets backpressure
|
|
83
|
+
ok 14 - identical requests share work; a fifth distinct computation gets backpressure
|
|
84
|
+
---
|
|
85
|
+
duration_ms: 3.125546
|
|
86
|
+
type: 'test'
|
|
87
|
+
...
|
|
88
|
+
# Subtest: completed payload cache retains at most four requests and expires old responses
|
|
89
|
+
ok 15 - completed payload cache retains at most four requests and expires old responses
|
|
90
|
+
---
|
|
91
|
+
duration_ms: 45.101987
|
|
92
|
+
type: 'test'
|
|
93
|
+
...
|
|
94
|
+
# Subtest: current counter reads share History deadline instead of leaving request hanging
|
|
95
|
+
ok 16 - current counter reads share History deadline instead of leaving request hanging
|
|
96
|
+
---
|
|
97
|
+
duration_ms: 5.609907
|
|
98
|
+
type: 'test'
|
|
99
|
+
...
|
|
100
|
+
# Subtest: 200-charge-point fallback uses at most eight simultaneous reads and retains correct sums
|
|
101
|
+
ok 17 - 200-charge-point fallback uses at most eight simultaneous reads and retains correct sums
|
|
102
|
+
---
|
|
103
|
+
duration_ms: 22.533297
|
|
104
|
+
type: 'test'
|
|
105
|
+
...
|
|
106
|
+
# Subtest: four maximum-range payloads stay within measured row and serialized-size budgets
|
|
107
|
+
ok 18 - four maximum-range payloads stay within measured row and serialized-size budgets
|
|
108
|
+
---
|
|
109
|
+
duration_ms: 528.541633
|
|
110
|
+
type: 'test'
|
|
111
|
+
...
|
|
112
|
+
# {"profile":"History-only controlled provider; not customer RSS","gcAvailable":false,"cacheEntries":4,"rowsPerPayload":106496,"largestPayloadBytes":1919024,"heapDeltaBytes":37427464}
|
|
113
|
+
# Subtest: leading missing buckets stay unknown in complete-period energy totals; measured zero remains zero
|
|
114
|
+
ok 19 - leading missing buckets stay unknown in complete-period energy totals; measured zero remains zero
|
|
115
|
+
---
|
|
116
|
+
duration_ms: 14.928208
|
|
117
|
+
type: 'test'
|
|
118
|
+
...
|
|
119
|
+
# Subtest: exact-energy EV fallback is also bounded and cannot swallow its timeout as a complete result
|
|
120
|
+
ok 20 - exact-energy EV fallback is also bounded and cannot swallow its timeout as a complete result
|
|
121
|
+
---
|
|
122
|
+
duration_ms: 3.183574
|
|
123
|
+
type: 'test'
|
|
124
|
+
...
|
|
125
|
+
# Subtest: optimized price lookup retains exact last-value and duplicate-timestamp semantics
|
|
126
|
+
ok 21 - optimized price lookup retains exact last-value and duplicate-timestamp semantics
|
|
127
|
+
---
|
|
128
|
+
duration_ms: 40.749831
|
|
129
|
+
type: 'test'
|
|
130
|
+
...
|
|
131
|
+
# Subtest: annual report still requests all ten years with two concurrent requests and original order
|
|
132
|
+
ok 22 - annual report still requests all ten years with two concurrent requests and original order
|
|
133
|
+
---
|
|
134
|
+
duration_ms: 11.549019
|
|
135
|
+
type: 'test'
|
|
136
|
+
...
|
|
137
|
+
# (node:64) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
138
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
139
|
+
# Subtest: missing getHistory callback rejects within five seconds and discards late or repeated replies
|
|
140
|
+
ok 23 - missing getHistory callback rejects within five seconds and discards late or repeated replies
|
|
141
|
+
---
|
|
142
|
+
duration_ms: 3.361841
|
|
143
|
+
type: 'test'
|
|
144
|
+
...
|
|
145
|
+
# Subtest: timely history remains unchanged and clears its deadline timer
|
|
146
|
+
ok 24 - timely history remains unchanged and clears its deadline timer
|
|
147
|
+
---
|
|
148
|
+
duration_ms: 1.373018
|
|
149
|
+
type: 'test'
|
|
150
|
+
...
|
|
151
|
+
# Subtest: candidate fallback shares one monotonic five-second budget instead of multiplying it
|
|
152
|
+
ok 25 - candidate fallback shares one monotonic five-second budget instead of multiplying it
|
|
153
|
+
---
|
|
154
|
+
duration_ms: 1.676634
|
|
155
|
+
type: 'test'
|
|
156
|
+
...
|
|
157
|
+
# Subtest: shutdown cancels all pending history work, releases timers and rejects new requests
|
|
158
|
+
ok 26 - shutdown cancels all pending history work, releases timers and rejects new requests
|
|
159
|
+
---
|
|
160
|
+
duration_ms: 1.271835
|
|
161
|
+
type: 'test'
|
|
162
|
+
...
|
|
163
|
+
# Subtest: startup energy totals finish after failed history without publishing zeros or refreshing old CO2
|
|
164
|
+
ok 27 - startup energy totals finish after failed history without publishing zeros or refreshing old CO2
|
|
165
|
+
---
|
|
166
|
+
duration_ms: 2.918164
|
|
167
|
+
type: 'test'
|
|
168
|
+
...
|
|
169
|
+
# Subtest: empty or invalid history and missing candidate mappings preserve old measurements
|
|
170
|
+
ok 28 - empty or invalid history and missing candidate mappings preserve old measurements
|
|
171
|
+
---
|
|
172
|
+
duration_ms: 3.622304
|
|
173
|
+
type: 'test'
|
|
174
|
+
...
|
|
175
|
+
# Subtest: valid zero-power samples remain legitimate measurements and nonzero energy integration remains unchanged
|
|
176
|
+
ok 29 - valid zero-power samples remain legitimate measurements and nonzero energy integration remains unchanged
|
|
177
|
+
---
|
|
178
|
+
duration_ms: 2.982821
|
|
179
|
+
type: 'test'
|
|
180
|
+
...
|
|
181
|
+
# Subtest: a reply after a stalled event loop cannot beat the deadline callback or extend the hard cap
|
|
182
|
+
ok 30 - a reply after a stalled event loop cannot beat the deadline callback or extend the hard cap
|
|
183
|
+
---
|
|
184
|
+
duration_ms: 2.460805
|
|
185
|
+
type: 'test'
|
|
186
|
+
...
|
|
187
|
+
# Subtest: a failed history branch preserves its old value and CO2 while other genuine measurements may update
|
|
188
|
+
ok 31 - a failed history branch preserves its old value and CO2 while other genuine measurements may update
|
|
189
|
+
---
|
|
190
|
+
duration_ms: 2.130698
|
|
191
|
+
type: 'test'
|
|
192
|
+
...
|
|
193
|
+
# Subtest: mapped but absent energy values are not converted to freshly published zero CO2
|
|
194
|
+
ok 32 - mapped but absent energy values are not converted to freshly published zero CO2
|
|
195
|
+
---
|
|
196
|
+
duration_ms: 1.68685
|
|
197
|
+
type: 'test'
|
|
198
|
+
...
|
|
199
|
+
# Subtest: real normalizer rejects null, boolean, blank and nonfinite values without synthesizing zero measurements
|
|
200
|
+
ok 33 - real normalizer rejects null, boolean, blank and nonfinite values without synthesizing zero measurements
|
|
201
|
+
---
|
|
202
|
+
duration_ms: 15.675692
|
|
203
|
+
type: 'test'
|
|
204
|
+
...
|
|
205
|
+
# Subtest: real normalizer rejects malformed rows/timestamps and retains finite Influx samples and timestamps
|
|
206
|
+
ok 34 - real normalizer rejects malformed rows/timestamps and retains finite Influx samples and timestamps
|
|
207
|
+
---
|
|
208
|
+
duration_ms: 2.227343
|
|
209
|
+
type: 'test'
|
|
210
|
+
...
|
|
211
|
+
# Subtest: history timeout diagnostics are constant, once per cycle and throttled for five monotonic minutes
|
|
212
|
+
ok 35 - history timeout diagnostics are constant, once per cycle and throttled for five monotonic minutes
|
|
213
|
+
---
|
|
214
|
+
duration_ms: 4.653917
|
|
215
|
+
type: 'test'
|
|
216
|
+
...
|
|
217
|
+
1..35
|
|
218
|
+
# tests 35
|
|
219
|
+
# suites 0
|
|
220
|
+
# pass 35
|
|
221
|
+
# fail 0
|
|
222
|
+
# cancelled 0
|
|
223
|
+
# skipped 0
|
|
224
|
+
# todo 0
|
|
225
|
+
# duration_ms 1599.10289
|
|
226
|
+
(node:56) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
227
|
+
(Use `node --trace-warnings ...` to show where the warning was created)
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"command": [
|
|
3
|
+
"/workspace/scratch/741f792566ea/node22-runtime/package/bin/node",
|
|
4
|
+
"--test",
|
|
5
|
+
"test/eos-history-api-stability.test.cjs",
|
|
6
|
+
"test/eos-history-deadline.test.cjs"
|
|
7
|
+
],
|
|
8
|
+
"start": "2026-11-24T20:48:37.962832+00:00",
|
|
9
|
+
"exitCode": 0,
|
|
10
|
+
"logSha256": "631f8dacd114e5e938c877d06e2c92c21360eee5845fd89986e8765fc06ce22d"
|
|
11
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
✔ periodic canonical samples stop holding through outages; legacy sparse mappings still hold (6.322309ms)
|
|
2
|
+
✔ canonical hold follows configured export cadence rather than an arbitrary device TTL (1.083541ms)
|
|
3
|
+
✔ charge-point sum retains an outage when any configured member has no periodic sample (2.239933ms)
|
|
4
|
+
✔ History API retains signed canonical EUR prices, fixed fee split and genuine zero (5.808657ms)
|
|
5
|
+
✔ missing and invalid manual prices are not synthesized into free History quotes (4.43659ms)
|
|
6
|
+
✔ asynchronous malformed History payloads cannot throw out of the callback (5.238528ms)
|
|
7
|
+
✔ valid numeric zero stays zero, null does not create measured zero, supported envelopes agree (32.900991ms)
|
|
8
|
+
✔ one five-second deadline includes fallback rounds and ignores late responses (2.708868ms)
|
|
9
|
+
✔ shutdown cancels History reads and new reads fail without starting transports (1.691637ms)
|
|
10
|
+
✔ thrown and rejected transports become bounded API errors with sibling cleanup (2.598182ms)
|
|
11
|
+
✔ oversized raw response stops processing and cleans all pending branches (4.170339ms)
|
|
12
|
+
✔ invalid and allocation-amplifying ranges are rejected before provider work (16.346243ms)
|
|
13
|
+
✔ day, week, month, leap-year and six-hour annual-report presets preserve finite output bounds (104.365548ms)
|
|
14
|
+
✔ identical requests share work; a fifth distinct computation gets backpressure (10.945781ms)
|
|
15
|
+
✔ completed payload cache retains at most four requests and expires old responses (50.58698ms)
|
|
16
|
+
✔ current counter reads share History deadline instead of leaving request hanging (5.127711ms)
|
|
17
|
+
✔ 200-charge-point fallback uses at most eight simultaneous reads and retains correct sums (36.429764ms)
|
|
18
|
+
✔ four maximum-range payloads stay within measured row and serialized-size budgets (369.515135ms)
|
|
19
|
+
ℹ {"profile":"History-only controlled provider; not customer RSS","gcAvailable":false,"cacheEntries":4,"rowsPerPayload":106496,"largestPayloadBytes":1919024,"heapDeltaBytes":33194096}
|
|
20
|
+
✔ leading missing buckets stay unknown in complete-period energy totals; measured zero remains zero (7.201233ms)
|
|
21
|
+
✔ exact-energy EV fallback is also bounded and cannot swallow its timeout as a complete result (2.148835ms)
|
|
22
|
+
✔ optimized price lookup retains exact last-value and duplicate-timestamp semantics (33.299648ms)
|
|
23
|
+
✔ annual report still requests all ten years with two concurrent requests and original order (11.075736ms)
|
|
24
|
+
✔ missing getHistory callback rejects within five seconds and discards late or repeated replies (3.976888ms)
|
|
25
|
+
✔ timely history remains unchanged and clears its deadline timer (1.408571ms)
|
|
26
|
+
✔ candidate fallback shares one monotonic five-second budget instead of multiplying it (2.230359ms)
|
|
27
|
+
✔ shutdown cancels all pending history work, releases timers and rejects new requests (1.561952ms)
|
|
28
|
+
✔ startup energy totals finish after failed history without publishing zeros or refreshing old CO2 (3.104494ms)
|
|
29
|
+
✔ empty or invalid history and missing candidate mappings preserve old measurements (4.178431ms)
|
|
30
|
+
✔ valid zero-power samples remain legitimate measurements and nonzero energy integration remains unchanged (3.116993ms)
|
|
31
|
+
✔ a reply after a stalled event loop cannot beat the deadline callback or extend the hard cap (2.535618ms)
|
|
32
|
+
✔ a failed history branch preserves its old value and CO2 while other genuine measurements may update (1.95234ms)
|
|
33
|
+
✔ mapped but absent energy values are not converted to freshly published zero CO2 (1.514451ms)
|
|
34
|
+
✔ real normalizer rejects null, boolean, blank and nonfinite values without synthesizing zero measurements (12.933554ms)
|
|
35
|
+
✔ real normalizer rejects malformed rows/timestamps and retains finite Influx samples and timestamps (2.476089ms)
|
|
36
|
+
✔ history timeout diagnostics are constant, once per cycle and throttled for five monotonic minutes (3.590316ms)
|
|
37
|
+
ℹ tests 35
|
|
38
|
+
ℹ suites 0
|
|
39
|
+
ℹ pass 35
|
|
40
|
+
ℹ fail 0
|
|
41
|
+
ℹ cancelled 0
|
|
42
|
+
ℹ skipped 0
|
|
43
|
+
ℹ todo 0
|
|
44
|
+
ℹ duration_ms 1695.853848
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"command": [
|
|
3
|
+
"node",
|
|
4
|
+
"--test",
|
|
5
|
+
"test/eos-history-api-stability.test.cjs",
|
|
6
|
+
"test/eos-history-deadline.test.cjs"
|
|
7
|
+
],
|
|
8
|
+
"start": "2026-11-24T20:48:36.180796+00:00",
|
|
9
|
+
"exitCode": 0,
|
|
10
|
+
"logSha256": "9ca726445afa978f3af9d5b696fbb768c1459cfe561c807957c20f12c6a7aa01"
|
|
11
|
+
}
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
TAP version 13
|
|
2
|
+
# (node:70) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
3
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
4
|
+
# Subtest: bad string and oversized ID cannot poison a valid queued measurement
|
|
5
|
+
ok 1 - bad string and oversized ID cannot poison a valid queued measurement
|
|
6
|
+
---
|
|
7
|
+
duration_ms: 1.998589
|
|
8
|
+
type: 'test'
|
|
9
|
+
...
|
|
10
|
+
# (node:70) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
11
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
12
|
+
# Subtest: eight pending real HTTP history queries retain writer capacity and original sample timestamp
|
|
13
|
+
ok 2 - eight pending real HTTP history queries retain writer capacity and original sample timestamp
|
|
14
|
+
---
|
|
15
|
+
duration_ms: 34.007011
|
|
16
|
+
type: 'test'
|
|
17
|
+
...
|
|
18
|
+
# Subtest: reconfiguration fences captured old writes and late active completions from new queue accounting
|
|
19
|
+
ok 3 - reconfiguration fences captured old writes and late active completions from new queue accounting
|
|
20
|
+
---
|
|
21
|
+
duration_ms: 0.565942
|
|
22
|
+
type: 'test'
|
|
23
|
+
...
|
|
24
|
+
# Subtest: normal drain flushes queued values, rejects late captures and commits, and closes once complete
|
|
25
|
+
ok 4 - normal drain flushes queued values, rejects late captures and commits, and closes once complete
|
|
26
|
+
---
|
|
27
|
+
duration_ms: 0.465701
|
|
28
|
+
type: 'test'
|
|
29
|
+
...
|
|
30
|
+
# Subtest: drain deadline is bounded and counts the unconfirmed active point without a fake success
|
|
31
|
+
ok 5 - drain deadline is bounded and counts the unconfirmed active point without a fake success
|
|
32
|
+
---
|
|
33
|
+
duration_ms: 19.644367
|
|
34
|
+
type: 'test'
|
|
35
|
+
...
|
|
36
|
+
# Subtest: legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian
|
|
37
|
+
ok 6 - legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian
|
|
38
|
+
---
|
|
39
|
+
duration_ms: 0.697511
|
|
40
|
+
type: 'test'
|
|
41
|
+
...
|
|
42
|
+
# (node:71) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
43
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
44
|
+
# (node:71) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
45
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
46
|
+
# Subtest: truncated CSV response aborts instead of returning partial chart or fabricated values
|
|
47
|
+
ok 7 - truncated CSV response aborts instead of returning partial chart or fabricated values
|
|
48
|
+
---
|
|
49
|
+
duration_ms: 43.217328
|
|
50
|
+
type: 'test'
|
|
51
|
+
...
|
|
52
|
+
# Subtest: response byte budget aborts a real large stream and frees concurrent capacity
|
|
53
|
+
ok 8 - response byte budget aborts a real large stream and frees concurrent capacity
|
|
54
|
+
---
|
|
55
|
+
duration_ms: 36.534137
|
|
56
|
+
type: 'test'
|
|
57
|
+
...
|
|
58
|
+
# Subtest: explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros
|
|
59
|
+
ok 9 - explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros
|
|
60
|
+
---
|
|
61
|
+
duration_ms: 9.771752
|
|
62
|
+
type: 'test'
|
|
63
|
+
...
|
|
64
|
+
# (node:72) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
65
|
+
# (Use `node --trace-warnings ...` to show where the warning was created)
|
|
66
|
+
# Subtest: actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=false)
|
|
67
|
+
ok 10 - actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=false)
|
|
68
|
+
---
|
|
69
|
+
duration_ms: 39.748696
|
|
70
|
+
type: 'test'
|
|
71
|
+
...
|
|
72
|
+
# Subtest: actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=true)
|
|
73
|
+
ok 11 - actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=true)
|
|
74
|
+
---
|
|
75
|
+
duration_ms: 10.491956
|
|
76
|
+
type: 'test'
|
|
77
|
+
...
|
|
78
|
+
# Subtest: actual Para14a publication retains source timestamp; denied and failed state writes never reach Influx
|
|
79
|
+
ok 12 - actual Para14a publication retains source timestamp; denied and failed state writes never reach Influx
|
|
80
|
+
---
|
|
81
|
+
duration_ms: 3.700071
|
|
82
|
+
type: 'test'
|
|
83
|
+
...
|
|
84
|
+
# Subtest: unregistered physical states remain outside direct historian scope
|
|
85
|
+
ok 13 - unregistered physical states remain outside direct historian scope
|
|
86
|
+
---
|
|
87
|
+
duration_ms: 0.823571
|
|
88
|
+
type: 'test'
|
|
89
|
+
...
|
|
90
|
+
# Subtest: actual SmartHome history route → main dispatch → Influx minmax preserves number values
|
|
91
|
+
ok 14 - actual SmartHome history route → main dispatch → Influx minmax preserves number values
|
|
92
|
+
---
|
|
93
|
+
duration_ms: 23.859312
|
|
94
|
+
type: 'test'
|
|
95
|
+
...
|
|
96
|
+
# Subtest: actual SmartHome history route → main dispatch → Influx minmax preserves boolean values
|
|
97
|
+
ok 15 - actual SmartHome history route → main dispatch → Influx minmax preserves boolean values
|
|
98
|
+
---
|
|
99
|
+
duration_ms: 9.07279
|
|
100
|
+
type: 'test'
|
|
101
|
+
...
|
|
102
|
+
1..15
|
|
103
|
+
# tests 15
|
|
104
|
+
# suites 0
|
|
105
|
+
# pass 15
|
|
106
|
+
# fail 0
|
|
107
|
+
# cancelled 0
|
|
108
|
+
# skipped 0
|
|
109
|
+
# todo 0
|
|
110
|
+
# duration_ms 556.284533
|
|
111
|
+
(node:63) [UNDICI-EHPA] Warning: EnvHttpProxyAgent is experimental, expect them to change at any time.
|
|
112
|
+
(Use `node --trace-warnings ...` to show where the warning was created)
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"command": [
|
|
3
|
+
"/workspace/scratch/741f792566ea/node22-runtime/package/bin/node",
|
|
4
|
+
"--test",
|
|
5
|
+
"test/eos-influx-hosted-module-history.test.cjs",
|
|
6
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/runtime-after.test.cjs",
|
|
7
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/transport-extra.test.cjs"
|
|
8
|
+
],
|
|
9
|
+
"start": "2026-11-24T20:45:53.977520+00:00",
|
|
10
|
+
"exitCode": 0,
|
|
11
|
+
"logSha256": "68f28e36da5854cac631f557dbc282c366524362c5dfeb727685ad6ff32e29cb"
|
|
12
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
✔ bad string and oversized ID cannot poison a valid queued measurement (6.298553ms)
|
|
2
|
+
✔ eight pending real HTTP history queries retain writer capacity and original sample timestamp (39.352739ms)
|
|
3
|
+
✔ reconfiguration fences captured old writes and late active completions from new queue accounting (0.679653ms)
|
|
4
|
+
✔ normal drain flushes queued values, rejects late captures and commits, and closes once complete (0.486523ms)
|
|
5
|
+
✔ drain deadline is bounded and counts the unconfirmed active point without a fake success (19.764388ms)
|
|
6
|
+
✔ legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian (0.651221ms)
|
|
7
|
+
✔ truncated CSV response aborts instead of returning partial chart or fabricated values (48.316601ms)
|
|
8
|
+
✔ response byte budget aborts a real large stream and frees concurrent capacity (76.727491ms)
|
|
9
|
+
✔ explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros (5.195973ms)
|
|
10
|
+
✔ actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=false) (32.815257ms)
|
|
11
|
+
✔ actual TarifVis → hosted adapter → HTTP history preserves negative price and namespace (migration=true) (14.590448ms)
|
|
12
|
+
✔ actual Para14a publication retains source timestamp; denied and failed state writes never reach Influx (4.614157ms)
|
|
13
|
+
✔ unregistered physical states remain outside direct historian scope (13.572013ms)
|
|
14
|
+
✔ actual SmartHome history route → main dispatch → Influx minmax preserves number values (44.150944ms)
|
|
15
|
+
✔ actual SmartHome history route → main dispatch → Influx minmax preserves boolean values (14.948266ms)
|
|
16
|
+
ℹ tests 15
|
|
17
|
+
ℹ suites 0
|
|
18
|
+
ℹ pass 15
|
|
19
|
+
ℹ fail 0
|
|
20
|
+
ℹ cancelled 0
|
|
21
|
+
ℹ skipped 0
|
|
22
|
+
ℹ todo 0
|
|
23
|
+
ℹ duration_ms 689.183555
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"command": [
|
|
3
|
+
"node",
|
|
4
|
+
"--test",
|
|
5
|
+
"test/eos-influx-hosted-module-history.test.cjs",
|
|
6
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/runtime-after.test.cjs",
|
|
7
|
+
"/workspace/scratch/741f792566ea/audit-920/influx-review/transport-extra.test.cjs"
|
|
8
|
+
],
|
|
9
|
+
"start": "2026-11-24T20:45:53.207041+00:00",
|
|
10
|
+
"exitCode": 0,
|
|
11
|
+
"logSha256": "6c219deead94d11b2c3c694efa6eda187c0661f273ff45b7b38e1a4152cbf777"
|
|
12
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const test=require('node:test'),assert=require('node:assert/strict'),http=require('node:http'),{createRequire}=require('node:module');
|
|
3
|
+
const req=createRequire('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/package.json');
|
|
4
|
+
const load=name=>req('tsx/cjs/api').require(`/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/ui/src-ts/runtime-executables/lib/${name}.ts`,__filename);
|
|
5
|
+
const {InfluxHistoryRuntime}=load('influx-history-runtime'),{influxLineProtocol}=load('influx-direct');
|
|
6
|
+
const config={url:'http://127.0.0.1:8086',organization:'org',bucket:'b',token:'synthetic-review'};
|
|
7
|
+
const deferred=()=>{let resolve;const promise=new Promise(done=>resolve=done);return {promise,resolve};};
|
|
8
|
+
const point=(runtime,val=123,ts=Date.now())=>runtime.capture('historie.good',{val,ack:true,ts});
|
|
9
|
+
const setup=(factory)=>{const runtime=new InfluxHistoryRuntime('eos-admin.0',factory);runtime.configure({provider:'influxdb2',influxdb2:config});runtime.register('historie.good');return runtime;};
|
|
10
|
+
test('bad string and oversized ID cannot poison a valid queued measurement',async()=>{const sent=[];const runtime=setup(()=>({query:async()=>({result:[]}),close(){},async write(points){sent.push(points);influxLineProtocol(points);}}));runtime.register('historie.text');assert.equal(runtime.register('x'.repeat(512)),false);const ts=Date.now();runtime.commit(point(runtime,123,ts));for(const val of ['line1\nline2','\u0000','\r'])assert.equal(runtime.capture('historie.text',{val,ack:true,ts}),null);await runtime.flush();assert.equal(sent.length,1);assert.deepEqual(sent[0],[{id:'eos-admin.0.historie.good',val:123,ts}]);assert.equal(runtime.status().droppedPoints,0);runtime.close();});
|
|
11
|
+
test('eight pending real HTTP history queries retain writer capacity and original sample timestamp',async t=>{let reads=0;const writes=[];const server=http.createServer(async(request,response)=>{if(request.url.startsWith('/api/v2/write')){let body='';for await(const data of request)body+=data;writes.push(body);response.statusCode=204;response.end();}else reads++;});await new Promise(done=>server.listen(0,'127.0.0.1',done));const runtime=new InfluxHistoryRuntime('eos-admin.0');runtime.configure({provider:'influxdb2',influxdb2:{...config,url:`http://127.0.0.1:${server.address().port}`}});t.after(async()=>{runtime.close();server.closeAllConnections();await new Promise(done=>server.close(done));});const pending=Promise.allSettled(Array.from({length:8},()=>runtime.query('eos-admin.0.historie.good',{start:1,end:1000})));runtime.register('historie.good');const ts=Date.now()-1234;runtime.commit(point(runtime,0,ts));await runtime.flush();assert.equal(writes[0],`eos-admin.0.historie.good value=0 ${ts}`);assert.ok(reads<=6);assert.equal(runtime.status().droppedPoints,0);assert.equal(runtime.status().writeVerified,true);runtime.close();await pending;});
|
|
12
|
+
test('reconfiguration fences captured old writes and late active completions from new queue accounting',async()=>{const old=deferred(),entered=deferred();let generation=0,closed=0;const calls=[];const runtime=setup(()=>{const current=++generation;return{close(){closed++;},query:async()=>({result:[]}),async write(points){calls.push({current,points});if(current===1){entered.resolve();await old.promise;}}};});const capture=point(runtime,1);runtime.commit(capture);const first=runtime.flush();await entered.promise;runtime.configure({provider:'influxdb2',influxdb2:{...config,bucket:'new'}});runtime.commit(capture);runtime.commit(point(runtime,2));await runtime.flush();const before=runtime.status();assert.equal(before.droppedPoints,1);assert.equal(before.queueDepth,0);old.resolve();await first;assert.deepEqual(runtime.status(),before);assert.equal(calls.length,2);assert.equal(calls[1].points[0].val,2);assert.equal(closed,1);runtime.close();});
|
|
13
|
+
test('normal drain flushes queued values, rejects late captures and commits, and closes once complete',async()=>{const pending=deferred(),entered=deferred();let close=0;const runtime=setup(()=>({close(){close++;},query:async()=>({result:[]}),async write(){entered.resolve();await pending.promise;}}));const captured=point(runtime);runtime.commit(captured);const flushing=runtime.flush();await entered.promise;const drain=runtime.drainAndClose(1000);assert.equal(runtime.capture('historie.good',{val:2,ack:true,ts:Date.now()}),null);runtime.commit(captured);assert.equal(runtime.status().queueDepth,1);pending.resolve();await Promise.all([flushing,drain]);assert.equal(close,1);assert.equal(runtime.status().state,'closed');assert.equal(runtime.status().droppedPoints,0);});
|
|
14
|
+
test('drain deadline is bounded and counts the unconfirmed active point without a fake success',async()=>{let close=0;const entered=deferred();const runtime=setup(()=>({close(){close++;},query:async()=>({result:[]}),async write(){entered.resolve();await new Promise(()=>{});}}));runtime.commit(point(runtime));void runtime.flush();await entered.promise;await runtime.drainAndClose(20);assert.equal(close,1);assert.equal(runtime.status().state,'closed');assert.equal(runtime.status().droppedPoints,1);assert.equal(runtime.status().writeVerified,false);});
|
|
15
|
+
test('legacy default remains inert; bad quality, ackfalse, null and NaN never enter the historian',async()=>{let made=0;const runtime=new InfluxHistoryRuntime('eos-admin.0',()=>{made++;return{close(){},query:async()=>({result:[]}),write:async()=>{}}});runtime.register('historie.good');runtime.configure(undefined);assert.equal(made,0);assert.equal(runtime.status().provider,'adapter');assert.equal(point(runtime),null);runtime.configure({provider:'influxdb2',influxdb2:config});for(const state of [{val:null,ack:true},{val:NaN,ack:true},{val:1,ack:false},{val:1,ack:true,q:64}])assert.equal(runtime.capture('historie.good',{ts:Date.now(),...state}),null);runtime.close();});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const test=require('node:test'),assert=require('node:assert/strict'),http=require('node:http');
|
|
3
|
+
const {createRequire}=require('node:module');
|
|
4
|
+
const req=createRequire('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/package.json');
|
|
5
|
+
const {InfluxDirectClient}=req('tsx/cjs/api').require('/workspace/scratch/741f792566ea/source-920/iobroker.eos-admin/ui/src-ts/runtime-executables/lib/influx-direct.ts',__filename);
|
|
6
|
+
async function fixture(t,listener){const server=http.createServer(listener);await new Promise(done=>server.listen(0,'127.0.0.1',done));const client=new InfluxDirectClient({url:`http://127.0.0.1:${server.address().port}/influx/`,organization:'org',bucket:'bucket',token:'synthetic-review'});t.after(async()=>{client.close();server.closeAllConnections();await new Promise(done=>server.close(done));});return client;}
|
|
7
|
+
test('truncated CSV response aborts instead of returning partial chart or fabricated values',async t=>{const client=await fixture(t,(_req,res)=>{res.writeHead(200,{'Content-Length':'900'});res.write('#datatype,string,long,dateTime:RFC3339,double\n,result,table,_time,_value\n,,0,2026-11-24T00:00:00Z,1\n');setImmediate(()=>res.destroy());});await assert.rejects(client.query('state',{start:1,end:1000}),/EOS_INFLUX_RESPONSE_INVALID|EOS_INFLUX_CONNECTION_FAILED/);});
|
|
8
|
+
test('response byte budget aborts a real large stream and frees concurrent capacity',async t=>{let calls=0;const client=await fixture(t,(request,res)=>{assert.equal(request.url,'/influx/api/v2/query?org=org');calls++;if(calls===1){res.writeHead(200);res.end(Buffer.alloc(8*1024*1024+1,120));}else res.end('');});await assert.rejects(client.query('state',{start:1,end:1000}),/EOS_INFLUX_RESPONSE_LIMIT/);assert.deepEqual(await client.query('state',{start:1,end:1000}),{result:[]});});
|
|
9
|
+
test('explicit same-timestamp write retry sends byte-identical idempotent points and retains genuine zeros',async t=>{const requests=[];const client=await fixture(t,async(request,res)=>{let body='';for await(const data of request)body+=data;requests.push({url:request.url,body});res.statusCode=requests.length===1?503:204;res.end();});const points=[{id:'eos-admin.0.historie.power',val:0,ts:1795478400123}];await assert.rejects(client.write(points),/EOS_INFLUX_REQUEST_FAILED/);await client.write(points);assert.deepEqual(requests[0],requests[1]);assert.match(requests[0].body,/value=0 1795478400123$/);});
|