sqlmath 2023.11.22 → 2024.1.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/CHANGELOG.md CHANGED
@@ -4,6 +4,13 @@
4
4
  - sqlmath - Add sqlite-extension for lightgbm.
5
5
  - none
6
6
 
7
+ # v2024.1.21
8
+ - sqlmath - Add function assertErrorThrownAsync().
9
+
10
+ # v2023.12.20
11
+ - chart - Improve ergonomics with import tsv.
12
+ - betadog - bugfix - Remove over-complicated prm ttt from table y_historical.
13
+
7
14
  # v2023.11.22
8
15
  - sqlmath - Add sql-functions normalizewithsquared(), squaredwithsign().
9
16
 
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
 
4
4
  # Status
5
- | Branch | [master<br>(v2023.11.22)](https://github.com/sqlmath/sqlmath/tree/master) | [beta<br>(Web Demo)](https://github.com/sqlmath/sqlmath/tree/beta) | [alpha<br>(Development)](https://github.com/sqlmath/sqlmath/tree/alpha) |
5
+ | Branch | [master<br>(v2024.1.21)](https://github.com/sqlmath/sqlmath/tree/master) | [beta<br>(Web Demo)](https://github.com/sqlmath/sqlmath/tree/beta) | [alpha<br>(Development)](https://github.com/sqlmath/sqlmath/tree/alpha) |
6
6
  |--:|:--:|:--:|:--:|
7
7
  | CI | [![ci](https://github.com/sqlmath/sqlmath/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/sqlmath/sqlmath/actions?query=branch%3Amaster) | [![ci](https://github.com/sqlmath/sqlmath/actions/workflows/ci.yml/badge.svg?branch=beta)](https://github.com/sqlmath/sqlmath/actions?query=branch%3Abeta) | [![ci](https://github.com/sqlmath/sqlmath/actions/workflows/ci.yml/badge.svg?branch=alpha)](https://github.com/sqlmath/sqlmath/actions?query=branch%3Aalpha) |
8
8
  | Coverage | [![coverage](https://sqlmath.github.io/sqlmath/branch-master/.artifact/coverage/coverage_badge.svg)](https://sqlmath.github.io/sqlmath/branch-master/.artifact/coverage/index.html) | [![coverage](https://sqlmath.github.io/sqlmath/branch-beta/.artifact/coverage/coverage_badge.svg)](https://sqlmath.github.io/sqlmath/branch-beta/.artifact/coverage/index.html) | [![coverage](https://sqlmath.github.io/sqlmath/branch-alpha/.artifact/coverage/coverage_badge.svg)](https://sqlmath.github.io/sqlmath/branch-alpha/.artifact/coverage/index.html) |
@@ -122,11 +122,11 @@ PORT=8080 sh jslint_ci.sh shHttpFileServer
122
122
  ```shell
123
123
  python -m build
124
124
  #
125
- twine upload --repository testpypi dist/sqlmath-2023.11.22*
126
- py -m pip install --index-url https://test.pypi.org/simple/ sqlmath==2023.11.22
125
+ twine upload --repository testpypi dist/sqlmath-2024.1.21*
126
+ py -m pip install --index-url https://test.pypi.org/simple/ sqlmath==2024.1.21
127
127
  #
128
- twine upload dist/sqlmath-2023.11.22*
129
- pip install sqlmath==2023.11.22
128
+ twine upload dist/sqlmath-2024.1.21*
129
+ pip install sqlmath==2024.1.21
130
130
  ```
131
131
 
132
132
 
package/package.json CHANGED
@@ -38,5 +38,5 @@
38
38
  },
39
39
  "shCiArtifactUpload": 1,
40
40
  "shCiPublishNpm": 1,
41
- "version": "2023.11.22"
41
+ "version": "2024.1.21"
42
42
  }
package/sqlmath.mjs CHANGED
@@ -104,7 +104,24 @@ let {
104
104
  let sqlMessageDict = {}; // dict of web-worker-callbacks
105
105
  let sqlMessageId = 0;
106
106
  let sqlWorker;
107
- let version = "v2023.11.22";
107
+ let version = "v2024.1.21";
108
+
109
+ async function assertErrorThrownAsync(asyncFunc, regexp) {
110
+
111
+ // This function will assert calling <asyncFunc> throws an error.
112
+
113
+ let err;
114
+ try {
115
+ await asyncFunc();
116
+ } catch (errCaught) {
117
+ err = errCaught;
118
+ }
119
+ assertOrThrow(err, "No error thrown.");
120
+ assertOrThrow(
121
+ !regexp || new RegExp(regexp).test(err.message),
122
+ err
123
+ );
124
+ }
108
125
 
109
126
  function assertInt64(val) {
110
127
  // This function will assert <val> is within range of c99-signed-long-long.
@@ -1368,6 +1385,7 @@ export {
1368
1385
  SQLITE_OPEN_TRANSIENT_DB,
1369
1386
  SQLITE_OPEN_URI,
1370
1387
  SQLITE_OPEN_WAL,
1388
+ assertErrorThrownAsync,
1371
1389
  assertInt64,
1372
1390
  assertJsonEqual,
1373
1391
  assertNumericalEqual,