@integraledger/lcp-binding-stellar 0.9.0 → 0.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @integraledger/lcp-binding-stellar
2
2
 
3
+ ## 0.10.1
4
+
5
+ **0.10.0 was staged and withdrawn before approval; this is that release, re-cut.** The conformance corpus
6
+ was re-sealed after 0.10.0 was staged — its root moved `32fa90a6…` → `28bbf4ef…` when the vector tree was
7
+ brought inside the prose gates — so the staged `lcp-conformance` tarball carried a seal that no longer
8
+ matched the repository. The seal is what proves corpus authenticity to an independent implementer, and a
9
+ published version cannot be replaced, so the whole set was rejected and re-cut rather than shipping one
10
+ package that disagreed with its own source. No version 0.10.0 exists on the registry.
11
+
12
+ ### Minor Changes
13
+
14
+ - f1c531c: **Breaking:** `USDC_DECIMALS` is renamed to `HEDERA_USDC_DECIMALS`, `SOLANA_USDC_DECIMALS`,
15
+ `STELLAR_USDC_DECIMALS` and `SUI_USDC_DECIMALS`.
16
+
17
+ All four packages exported the same name and they did not all mean the same number — Stellar assets carry
18
+ seven decimals where the other three carry six. Each value was correct for its own chain, so no package had
19
+ a defect and every package's own test passed; the hazard lived only in importing one rail's constant and
20
+ applying it on another, which is a ten-fold error in an amount and surfaces at settlement rather than at
21
+ compile time. The rail prefix makes that import impossible to make by accident.
22
+
23
+ `minor` rather than `major` because every package here is pre-1.0, where a minor is the breaking increment
24
+ under semver. Migration is a rename at the import site; the values are unchanged.
25
+
3
26
  ## 0.9.0
4
27
 
5
28
  First public release.
@@ -42,6 +42,15 @@ export declare const PUBNET_PASSPHRASE = "Public Global Stellar Network ; Septem
42
42
  /** The constants for one network. Both are usable — the CAP-67 muxed id is a ledger primitive, so nothing
43
43
  * has to be deployed first. */
44
44
  export declare function getStellarConfig(network: StellarNetwork): StellarNetworkConfig;
45
- /** USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units. */
46
- export declare const USDC_DECIMALS = 7;
45
+ /**
46
+ * USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units.
47
+ *
48
+ * RAIL-QUALIFIED ON PURPOSE. Four bindings publish a USDC decimal count and they are NOT all the same —
49
+ * Stellar's is 7 where Hedera's, Solana's and Sui's are 6. A bare `USDC_DECIMALS` exported four times
50
+ * from four packages is one name with two meanings, and the way that fails is silent: a consumer who reads
51
+ * it from one rail and applies it on another is off by a factor of ten in an amount, at settlement rather
52
+ * than at compile time. Each value is correct for its own chain, which is why no per-package test can
53
+ * catch the clash; the prefix is what makes it impossible to import the wrong one by accident.
54
+ */
55
+ export declare const STELLAR_USDC_DECIMALS = 7;
47
56
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH;;;8GAG8G;AAC9G,eAAO,MAAM,UAAU,EAAG,kBAA2B,CAAC;AAEtD,8DAA8D;AAC9D,eAAO,MAAM,YAAY,IAAI,CAAC;AAE9B,mGAAmG;AACnG,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,QAAQ,CAAC;AAElD;;;wFAGwF;AACxF,MAAM,WAAW,oBAAoB;IACnC,OAAO,EAAE,cAAc,CAAC;IACxB,kEAAkE;IAClE,iBAAiB,EAAE,MAAM,CAAC;IAC1B,6BAA6B;IAC7B,UAAU,EAAE,MAAM,CAAC;IACnB,uBAAuB;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,oEAAoE;IACpE,iBAAiB,EAAE,MAAM,CAAC;CAC3B;AAED,yGAAyG;AACzG,eAAO,MAAM,kBAAkB,sCAAsC,CAAC;AACtE;;gCAEgC;AAChC,eAAO,MAAM,iBAAiB,mDACoB,CAAC;AAkBnD;gCACgC;AAChC,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE,cAAc,GACtB,oBAAoB,CAEtB;AAED,uEAAuE;AACvE,eAAO,MAAM,aAAa,IAAI,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH;;;8GAG8G;AAC9G,eAAO,MAAM,UAAU,EAAG,kBAA2B,CAAC;AAEtD,8DAA8D;AAC9D,eAAO,MAAM,YAAY,IAAI,CAAC;AAE9B,mGAAmG;AACnG,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,QAAQ,CAAC;AAElD;;;wFAGwF;AACxF,MAAM,WAAW,oBAAoB;IACnC,OAAO,EAAE,cAAc,CAAC;IACxB,kEAAkE;IAClE,iBAAiB,EAAE,MAAM,CAAC;IAC1B,6BAA6B;IAC7B,UAAU,EAAE,MAAM,CAAC;IACnB,uBAAuB;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,oEAAoE;IACpE,iBAAiB,EAAE,MAAM,CAAC;CAC3B;AAED,yGAAyG;AACzG,eAAO,MAAM,kBAAkB,sCAAsC,CAAC;AACtE;;gCAEgC;AAChC,eAAO,MAAM,iBAAiB,mDACoB,CAAC;AAkBnD;gCACgC;AAChC,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE,cAAc,GACtB,oBAAoB,CAEtB;AAED;;;;;;;;;GASG;AACH,eAAO,MAAM,qBAAqB,IAAI,CAAC"}
package/dist/constants.js CHANGED
@@ -41,6 +41,15 @@ const PUBNET = {
41
41
  export function getStellarConfig(network) {
42
42
  return network === "testnet" ? TESTNET : PUBNET;
43
43
  }
44
- /** USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units. */
45
- export const USDC_DECIMALS = 7;
44
+ /**
45
+ * USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units.
46
+ *
47
+ * RAIL-QUALIFIED ON PURPOSE. Four bindings publish a USDC decimal count and they are NOT all the same —
48
+ * Stellar's is 7 where Hedera's, Solana's and Sui's are 6. A bare `USDC_DECIMALS` exported four times
49
+ * from four packages is one name with two meanings, and the way that fails is silent: a consumer who reads
50
+ * it from one rail and applies it on another is off by a factor of ten in an amount, at settlement rather
51
+ * than at compile time. Each value is correct for its own chain, which is why no per-package test can
52
+ * catch the clash; the prefix is what makes it impossible to import the wrong one by accident.
53
+ */
54
+ export const STELLAR_USDC_DECIMALS = 7;
46
55
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH;;;8GAG8G;AAC9G,MAAM,CAAC,MAAM,UAAU,GAAG,kBAA2B,CAAC;AAEtD,8DAA8D;AAC9D,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAC;AAqB9B,yGAAyG;AACzG,MAAM,CAAC,MAAM,kBAAkB,GAAG,mCAAmC,CAAC;AACtE;;gCAEgC;AAChC,MAAM,CAAC,MAAM,iBAAiB,GAC5B,gDAAgD,CAAC;AAEnD,MAAM,OAAO,GAAyB;IACpC,OAAO,EAAE,SAAS;IAClB,iBAAiB,EAAE,kBAAkB;IACrC,UAAU,EAAE,qCAAqC;IACjD,aAAa,EAAE,qCAAqC;IACpD,iBAAiB,EAAE,0DAA0D;CAC9E,CAAC;AAEF,MAAM,MAAM,GAAyB;IACnC,OAAO,EAAE,QAAQ;IACjB,iBAAiB,EAAE,iBAAiB;IACpC,UAAU,EAAE,6BAA6B;IACzC,aAAa,EAAE,gCAAgC;IAC/C,iBAAiB,EAAE,0DAA0D;CAC9E,CAAC;AAEF;gCACgC;AAChC,MAAM,UAAU,gBAAgB,CAC9B,OAAuB;IAEvB,OAAO,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;AAClD,CAAC;AAED,uEAAuE;AACvE,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,CAAC"}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH;;;8GAG8G;AAC9G,MAAM,CAAC,MAAM,UAAU,GAAG,kBAA2B,CAAC;AAEtD,8DAA8D;AAC9D,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAC;AAqB9B,yGAAyG;AACzG,MAAM,CAAC,MAAM,kBAAkB,GAAG,mCAAmC,CAAC;AACtE;;gCAEgC;AAChC,MAAM,CAAC,MAAM,iBAAiB,GAC5B,gDAAgD,CAAC;AAEnD,MAAM,OAAO,GAAyB;IACpC,OAAO,EAAE,SAAS;IAClB,iBAAiB,EAAE,kBAAkB;IACrC,UAAU,EAAE,qCAAqC;IACjD,aAAa,EAAE,qCAAqC;IACpD,iBAAiB,EAAE,0DAA0D;CAC9E,CAAC;AAEF,MAAM,MAAM,GAAyB;IACnC,OAAO,EAAE,QAAQ;IACjB,iBAAiB,EAAE,iBAAiB;IACpC,UAAU,EAAE,6BAA6B;IACzC,aAAa,EAAE,gCAAgC;IAC/C,iBAAiB,EAAE,0DAA0D;CAC9E,CAAC;AAEF;gCACgC;AAChC,MAAM,UAAU,gBAAgB,CAC9B,OAAuB;IAEvB,OAAO,OAAO,KAAK,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;AAClD,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export { buildMuxedDestination, createStellarAdapter, isSettledSuccessfully, STELLAR_PREFIX_NOTE, type StellarAdapter, type StellarMuxConfirmation, type StellarMuxPrefixRecovery, type StellarReader, type StellarSettlementRef, type StellarSettlementView, } from "./adapter.js";
2
- export { getStellarConfig, MUX_ID_BYTES, MUX_SCHEME, PUBNET_PASSPHRASE, type StellarNetwork, type StellarNetworkConfig, TESTNET_PASSPHRASE, USDC_DECIMALS, } from "./constants.js";
2
+ export { getStellarConfig, MUX_ID_BYTES, MUX_SCHEME, PUBNET_PASSPHRASE, STELLAR_USDC_DECIMALS, type StellarNetwork, type StellarNetworkConfig, TESTNET_PASSPHRASE, } from "./constants.js";
3
3
  export { STELLAR_MANIFEST } from "./manifest.js";
4
4
  export { type DecodedMuxedAddress, decodeMuxedAddress, deriveMuxId, encodeMuxedAddress, recoverMuxIdPrefix8, verifyMuxedBinding, } from "./mux.js";
5
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,aAAa,EAClB,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,GAC3B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,KAAK,cAAc,EACnB,KAAK,oBAAoB,EACzB,kBAAkB,EAClB,aAAa,GACd,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EACL,KAAK,mBAAmB,EACxB,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,GACnB,MAAM,UAAU,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC3B,KAAK,wBAAwB,EAC7B,KAAK,aAAa,EAClB,KAAK,oBAAoB,EACzB,KAAK,qBAAqB,GAC3B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,qBAAqB,EACrB,KAAK,cAAc,EACnB,KAAK,oBAAoB,EACzB,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EACL,KAAK,mBAAmB,EACxB,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,GACnB,MAAM,UAAU,CAAC"}
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  export { buildMuxedDestination, createStellarAdapter, isSettledSuccessfully, STELLAR_PREFIX_NOTE, } from "./adapter.js";
2
- export { getStellarConfig, MUX_ID_BYTES, MUX_SCHEME, PUBNET_PASSPHRASE, TESTNET_PASSPHRASE, USDC_DECIMALS, } from "./constants.js";
2
+ export { getStellarConfig, MUX_ID_BYTES, MUX_SCHEME, PUBNET_PASSPHRASE, STELLAR_USDC_DECIMALS, TESTNET_PASSPHRASE, } from "./constants.js";
3
3
  export { STELLAR_MANIFEST } from "./manifest.js";
4
4
  export { decodeMuxedAddress, deriveMuxId, encodeMuxedAddress, recoverMuxIdPrefix8, verifyMuxedBinding, } from "./mux.js";
5
5
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,GAOpB,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EAGjB,kBAAkB,EAClB,aAAa,GACd,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAEL,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,GACnB,MAAM,UAAU,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,qBAAqB,EACrB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,GAOpB,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,gBAAgB,EAChB,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,qBAAqB,EAGrB,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAEL,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,GACnB,MAAM,UAAU,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@integraledger/lcp-binding-stellar",
3
- "version": "0.9.0",
3
+ "version": "0.10.1",
4
4
  "description": "Welds an ATR hash into a Stellar payment.",
5
5
  "keywords": [
6
6
  "lcp",
@@ -42,8 +42,8 @@
42
42
  "homepage": "https://github.com/IntegraLedger/integra-protocol/tree/main/packages/binding-stellar#readme",
43
43
  "dependencies": {
44
44
  "@stellar/stellar-sdk": "16.2.0",
45
- "@integraledger/lcp-binding-core": "0.9.0",
46
- "@integraledger/lcp-kernel": "0.9.0"
45
+ "@integraledger/lcp-binding-core": "0.10.1",
46
+ "@integraledger/lcp-kernel": "0.10.1"
47
47
  },
48
48
  "devDependencies": {
49
49
  "@types/json-schema": "7.0.15",
package/src/constants.ts CHANGED
@@ -70,5 +70,14 @@ export function getStellarConfig(
70
70
  return network === "testnet" ? TESTNET : PUBNET;
71
71
  }
72
72
 
73
- /** USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units. */
74
- export const USDC_DECIMALS = 7;
73
+ /**
74
+ * USDC on Stellar has 7 decimals — 1 USDC = 10_000_000 base units.
75
+ *
76
+ * RAIL-QUALIFIED ON PURPOSE. Four bindings publish a USDC decimal count and they are NOT all the same —
77
+ * Stellar's is 7 where Hedera's, Solana's and Sui's are 6. A bare `USDC_DECIMALS` exported four times
78
+ * from four packages is one name with two meanings, and the way that fails is silent: a consumer who reads
79
+ * it from one rail and applies it on another is off by a factor of ten in an amount, at settlement rather
80
+ * than at compile time. Each value is correct for its own chain, which is why no per-package test can
81
+ * catch the clash; the prefix is what makes it impossible to import the wrong one by accident.
82
+ */
83
+ export const STELLAR_USDC_DECIMALS = 7;
package/src/index.ts CHANGED
@@ -15,10 +15,10 @@ export {
15
15
  MUX_ID_BYTES,
16
16
  MUX_SCHEME,
17
17
  PUBNET_PASSPHRASE,
18
+ STELLAR_USDC_DECIMALS,
18
19
  type StellarNetwork,
19
20
  type StellarNetworkConfig,
20
21
  TESTNET_PASSPHRASE,
21
- USDC_DECIMALS,
22
22
  } from "./constants.js";
23
23
  export { STELLAR_MANIFEST } from "./manifest.js";
24
24
  export {