edfcore 0.4.424 → 0.4.426

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.
@@ -109,5 +109,5 @@ export declare const SIGNAL_FIELD_BLOCK_OFFSETS: {
109
109
  readonly reserved: 224;
110
110
  };
111
111
  /** Published package version. Kept in sync with package.json by a test. */
112
- export declare const VERSION = "0.4.424";
112
+ export declare const VERSION = "0.4.426";
113
113
  //# sourceMappingURL=constants.d.ts.map
package/dist/constants.js CHANGED
@@ -79,5 +79,5 @@ export const SIGNAL_FIELD_BLOCK_OFFSETS = {
79
79
  reserved: 224,
80
80
  };
81
81
  /** Published package version. Kept in sync with package.json by a test. */
82
- export const VERSION = '0.4.424';
82
+ export const VERSION = '0.4.426';
83
83
  //# sourceMappingURL=constants.js.map
package/docs/CHANGELOG.md CHANGED
@@ -6,6 +6,44 @@ alone does not tell you whether you were affected.
6
6
  edfcore is pre-1.0. Patch releases have carried behaviour changes where the old behaviour was a
7
7
  defect; those are called out below.
8
8
 
9
+ ## 0.4.426
10
+
11
+ - **Added** a property test that the cache is invisible at every size it can be configured to.
12
+ `api-sources.md` describes `cachedSource` as "removed by deleting one wrapper from the expression
13
+ that built the source", which is the property a caller relies on when they add it: the reads get
14
+ cheaper and nothing else changes.
15
+ - The existing demonstration is one script of six reads at the default block size, where the 1 MiB
16
+ block swallows the fixture whole — so it demonstrates a cache that never evicts, never stitches
17
+ and never splits. The interesting sizes are the other ones: a block smaller than a read makes
18
+ every answer a stitch, a budget smaller than a few blocks makes the cache evict mid-sequence, and
19
+ a read wider than the budget bypasses the cache entirely. All three are reachable from an
20
+ ordinary configuration — blocks sized to a record, a budget sized to a phone.
21
+ - The failure is not a crash. Stitching arithmetic off by a block start returns the right number of
22
+ bytes from the right file, taken from the wrong offset: a header that parses, samples that plot,
23
+ and a recording quietly shifted.
24
+ - The copy rule is scoped rather than assumed. It is asserted for reads the cache actually serves;
25
+ a read wider than the whole budget returns the wrapped source's own array by design, because
26
+ nothing is retained on that path, and `cached.ts` says so. Each property builds its fixture
27
+ fresh, since a test that writes into a result would otherwise edit the bytes it compares against
28
+ and pass on the damage.
29
+
30
+ ## 0.4.425
31
+
32
+ - **Added** tests for the one sentence `api-reading.md` gives about the shape of `signalIndices`:
33
+ "Duplicates are dropped; the order you give is the order of `chunk.signals`." It was prose, in
34
+ the options table every reader consults before their first read.
35
+ - Both halves are reached by ordinary code. A repeated index comes from a multi-select that appends
36
+ on click, a "select all" over a list that already had one checked, or `[...montage, ...extras]`
37
+ where the two overlap. The order comes from wherever the indices were built, and a caller drawing
38
+ `chunk.signals[0]` as the top trace is trusting it.
39
+ - They fail differently and both quietly. A duplicate that is not dropped costs a second decode and
40
+ returns an array with one more entry than the caller's legend has rows, so every trace below the
41
+ repeat is drawn with the wrong label. An order that is not preserved swaps two traces outright,
42
+ and on a montage two channels of EEG look like two channels of EEG.
43
+ - `readRecords`, `readWindow` and `streamRecords` are all checked. They share one resolver today —
44
+ `stream.ts` says it must produce the byte-identical refusal `readWindow` does — but that is a
45
+ fact about the code and the promise is about the API.
46
+
9
47
  ## 0.4.424
10
48
 
11
49
  - **Added** a property test that reading a stretch in pieces and joining them is reading it whole.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "edfcore",
3
- "version": "0.4.424",
3
+ "version": "0.4.426",
4
4
  "description": "Modern, typed, zero-dependency reader for EDF, EDF+, BDF and BDF+ biosignal files. Works in browsers and Node with true random access.",
5
5
  "keywords": [
6
6
  "edf",
package/src/constants.ts CHANGED
@@ -93,4 +93,4 @@ export const SIGNAL_FIELD_BLOCK_OFFSETS = {
93
93
  } as const;
94
94
 
95
95
  /** Published package version. Kept in sync with package.json by a test. */
96
- export const VERSION = '0.4.424';
96
+ export const VERSION = '0.4.426';