@toa.io/boot 1.0.0-alpha.303 → 1.0.0-alpha.305

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
@@ -3,6 +3,21 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [1.0.0-alpha.305](https://github.com/toa-io/toa/compare/v1.0.0-alpha.304...v1.0.0-alpha.305) (2026-09-13)
7
+
8
+ ### Features
9
+
10
+ * **core:** refuse a call that writes, made under a request that only reads ([92951d0](https://github.com/toa-io/toa/commit/92951d0f7b95bd5b838097dd6a42db5586968d0b))
11
+
12
+
13
+ # [1.0.0-alpha.304](https://github.com/toa-io/toa/compare/v1.0.0-alpha.303...v1.0.0-alpha.304) (2026-09-13)
14
+
15
+ **Note:** Version bump only for package @toa.io/boot
16
+
17
+
18
+
19
+
20
+
6
21
  # [1.0.0-alpha.303](https://github.com/toa-io/toa/compare/v1.0.0-alpha.302...v1.0.0-alpha.303) (2026-09-12)
7
22
 
8
23
  **Note:** Version bump only for package @toa.io/boot
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toa.io/boot",
3
- "version": "1.0.0-alpha.303",
3
+ "version": "1.0.0-alpha.305",
4
4
  "type": "module",
5
5
  "description": "Toa Boot",
6
6
  "author": "temich <tema.gurtovoy@gmail.com>",
@@ -21,15 +21,15 @@
21
21
  "test": "echo \"Error: run tests from root\" && exit 1"
22
22
  },
23
23
  "dependencies": {
24
- "@toa.io/atomicity": "1.0.0-alpha.303",
25
- "@toa.io/core": "1.0.0-alpha.303",
26
- "@toa.io/definitions": "1.0.0-alpha.303",
27
- "@toa.io/generic": "1.0.0-alpha.301",
28
- "@toa.io/norm": "1.0.0-alpha.303",
29
- "@toa.io/schemas": "1.0.0-alpha.301",
24
+ "@toa.io/atomicity": "1.0.0-alpha.305",
25
+ "@toa.io/core": "1.0.0-alpha.305",
26
+ "@toa.io/definitions": "1.0.0-alpha.305",
27
+ "@toa.io/generic": "1.0.0-alpha.304",
28
+ "@toa.io/norm": "1.0.0-alpha.305",
29
+ "@toa.io/schemas": "1.0.0-alpha.304",
30
30
  "clone-deep": "4.0.1",
31
31
  "dotenv": "17.4.2",
32
- "openspan": "1.0.0-alpha.303"
32
+ "openspan": "1.0.0-alpha.305"
33
33
  },
34
- "gitHead": "b8e9dd89f6d49756944687a95dfc786f12947286"
34
+ "gitHead": "6a28476303826e2484cc2ea6306efee6f19fb594"
35
35
  }
package/src/call.js CHANGED
@@ -1,4 +1,4 @@
1
- import { Call, Transmission } from '@toa.io/core'
1
+ import { Call, safe, Transmission } from '@toa.io/core'
2
2
 
3
3
  import * as boot from './index.js'
4
4
 
@@ -10,5 +10,19 @@ export const call = async (locator, endpoint, definition, entity, source) => {
10
10
 
11
11
  const stateful = definition.stateful === true
12
12
 
13
- return new Call(transmission, contract, `${locator.id}.${endpoint}`, source, stateful)
13
+ /*
14
+ * An endpoint beginning with `.` is the runtime's own rather than an operation — a lookup, an
15
+ * exposition — so the safety of operations has nothing to say about it. `Component.invoke`
16
+ * counts it as no hop in a call chain for the same reason.
17
+ */
18
+ const readable = endpoint[0] === '.' || safe(definition.type)
19
+
20
+ return new Call(
21
+ transmission,
22
+ contract,
23
+ `${locator.id}.${endpoint}`,
24
+ source,
25
+ stateful,
26
+ readable
27
+ )
14
28
  }