@smartledger/bsv 9.1.0 → 9.1.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 +27 -0
- package/README.md +19 -19
- package/bsv-gdaf.min.js +34 -34
- package/bsv-smartcontract.min.js +1 -1
- package/bsv.bundle.js +34 -34
- package/bsv.min.js +34 -34
- package/docs/MODULE_REFERENCE_COMPLETE.md +27 -27
- package/docs/advanced/UTXO_MANAGER_GUIDE.md +1 -1
- package/docs/getting-started/INSTALLATION.md +23 -23
- package/docs/getting-started/QUICK_START.md +7 -7
- package/docs/migration/FROM_BSV_1_5_6.md +5 -5
- package/lib/block/merkleblock.js +34 -4
- package/package.json +1 -1
- package/version.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,33 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [9.1.1] - 2026-08-24
|
|
11
|
+
|
|
12
|
+
### Fixed — MerkleBlock shared mutable state with its caller
|
|
13
|
+
|
|
14
|
+
The constructor stored `arg.hashes` and `arg.flags` directly, and `toObject()` handed
|
|
15
|
+
the same arrays back out. A MerkleBlock and the object it was built from — or the
|
|
16
|
+
object it produced — were therefore the same arrays, and mutating either changed the
|
|
17
|
+
other at a distance:
|
|
18
|
+
|
|
19
|
+
```js
|
|
20
|
+
const mb = new MerkleBlock(obj)
|
|
21
|
+
mb.hashes.push(x) // obj.hashes grew too
|
|
22
|
+
const out = mb.toObject()
|
|
23
|
+
out.flags.pop() // mb.flags shrank too
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
Both directions now copy. Contents, round-trips and validation are unchanged; a
|
|
27
|
+
non-array is still passed through rather than coerced, since the constructor never
|
|
28
|
+
validated these fields and 9.x does not turn a tolerated input into a throw.
|
|
29
|
+
|
|
30
|
+
Found as order-dependence in this library's own suite — tests that mutate a block
|
|
31
|
+
built from the shared `data.JSON[0]` corrupted that fixture for every test after them,
|
|
32
|
+
so a new test passed alone and failed in the full run. Measured before and after: the
|
|
33
|
+
fixture does not survive `test/block/merkleblock.js` on 9.1.0, and does now. The tests
|
|
34
|
+
were the messenger; the aliasing is the defect, and a caller building a MerkleBlock
|
|
35
|
+
from their own object hits it the same way.
|
|
36
|
+
|
|
10
37
|
## [9.1.0] - 2026-08-23
|
|
11
38
|
|
|
12
39
|
Nothing in this release breaks a caller. That is the release.
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Bitcoin SV library with an interpreter-verified script engine.
|
|
4
4
|
|
|
5
|
-
[](https://www.npmjs.com/package/@smartledger/bsv)
|
|
6
6
|
[](LICENSE)
|
|
7
7
|
[](STABILITY.md)
|
|
8
8
|
|
|
@@ -155,44 +155,44 @@ const bsv = require('@smartledger/bsv') // 128 modules
|
|
|
155
155
|
### **Core Modules**
|
|
156
156
|
| Module | Size | Use Case | CDN |
|
|
157
157
|
|--------|------|----------|-----|
|
|
158
|
-
| **bsv.min.js** | 1041KB | Core BSV + SmartContract | `unpkg.com/@smartledger/bsv@9.1.
|
|
159
|
-
| **bsv.bundle.js** | 1041KB | Everything in one file | `unpkg.com/@smartledger/bsv@9.1.
|
|
158
|
+
| **bsv.min.js** | 1041KB | Core BSV + SmartContract | `unpkg.com/@smartledger/bsv@9.1.1/bsv.min.js` |
|
|
159
|
+
| **bsv.bundle.js** | 1041KB | Everything in one file | `unpkg.com/@smartledger/bsv@9.1.1/bsv.bundle.js` |
|
|
160
160
|
|
|
161
161
|
### **W3C Verifiable Credentials**
|
|
162
162
|
| Module | Size | Use Case | CDN |
|
|
163
163
|
|--------|------|----------|-----|
|
|
164
|
-
| **🟢 bsv-didweb.min.js** | 166KB | **DID:web generation** | `unpkg.com/@smartledger/bsv@9.1.
|
|
165
|
-
| **🟢 bsv-vcjwt.min.js** | 166KB | **VC-JWT issue/verify** | `unpkg.com/@smartledger/bsv@9.1.
|
|
166
|
-
| **🟢 bsv-statuslist.min.js** | 256KB | **StatusList2021 revocation** | `unpkg.com/@smartledger/bsv@9.1.
|
|
167
|
-
| **🟢 bsv-anchor.min.js** | 164KB | **BSV anchoring (hash-only)** | `unpkg.com/@smartledger/bsv@9.1.
|
|
164
|
+
| **🟢 bsv-didweb.min.js** | 166KB | **DID:web generation** | `unpkg.com/@smartledger/bsv@9.1.1/bsv-didweb.min.js` |
|
|
165
|
+
| **🟢 bsv-vcjwt.min.js** | 166KB | **VC-JWT issue/verify** | `unpkg.com/@smartledger/bsv@9.1.1/bsv-vcjwt.min.js` |
|
|
166
|
+
| **🟢 bsv-statuslist.min.js** | 256KB | **StatusList2021 revocation** | `unpkg.com/@smartledger/bsv@9.1.1/bsv-statuslist.min.js` |
|
|
167
|
+
| **🟢 bsv-anchor.min.js** | 164KB | **BSV anchoring (hash-only)** | `unpkg.com/@smartledger/bsv@9.1.1/bsv-anchor.min.js` |
|
|
168
168
|
|
|
169
169
|
### **Smart Contract & Development**
|
|
170
170
|
| Module | Size | Use Case | CDN |
|
|
171
171
|
|--------|------|----------|-----|
|
|
172
|
-
| **bsv-smartcontract.min.js** | 140KB | Complete covenant framework | `unpkg.com/@smartledger/bsv@9.1.
|
|
173
|
-
| **bsv-covenant.min.js** | 35KB | Covenant operations | `unpkg.com/@smartledger/bsv@9.1.
|
|
174
|
-
| **bsv-script-helper.min.js** | 33KB | Custom script tools | `unpkg.com/@smartledger/bsv@9.1.
|
|
175
|
-
| **bsv-security.min.js** | 32KB | Security enhancements | `unpkg.com/@smartledger/bsv@9.1.
|
|
172
|
+
| **bsv-smartcontract.min.js** | 140KB | Complete covenant framework | `unpkg.com/@smartledger/bsv@9.1.1/bsv-smartcontract.min.js` |
|
|
173
|
+
| **bsv-covenant.min.js** | 35KB | Covenant operations | `unpkg.com/@smartledger/bsv@9.1.1/bsv-covenant.min.js` |
|
|
174
|
+
| **bsv-script-helper.min.js** | 33KB | Custom script tools | `unpkg.com/@smartledger/bsv@9.1.1/bsv-script-helper.min.js` |
|
|
175
|
+
| **bsv-security.min.js** | 32KB | Security enhancements | `unpkg.com/@smartledger/bsv@9.1.1/bsv-security.min.js` |
|
|
176
176
|
|
|
177
177
|
### **Legal & Compliance**
|
|
178
178
|
| Module | Size | Use Case | CDN |
|
|
179
179
|
|--------|------|----------|-----|
|
|
180
|
-
| **bsv-ltp.min.js** | 535KB | Legal Token Protocol | `unpkg.com/@smartledger/bsv@9.1.
|
|
181
|
-
| **bsv-gdaf.min.js** | 1041KB | Digital Identity & Attestation | `unpkg.com/@smartledger/bsv@9.1.
|
|
180
|
+
| **bsv-ltp.min.js** | 535KB | Legal Token Protocol | `unpkg.com/@smartledger/bsv@9.1.1/bsv-ltp.min.js` |
|
|
181
|
+
| **bsv-gdaf.min.js** | 1041KB | Digital Identity & Attestation | `unpkg.com/@smartledger/bsv@9.1.1/bsv-gdaf.min.js` |
|
|
182
182
|
|
|
183
183
|
### **Advanced Cryptography**
|
|
184
184
|
| Module | Size | Use Case | CDN |
|
|
185
185
|
|--------|------|----------|-----|
|
|
186
|
-
| **bsv-shamir.min.js** | 177KB | Threshold Cryptography | `unpkg.com/@smartledger/bsv@9.1.
|
|
186
|
+
| **bsv-shamir.min.js** | 177KB | Threshold Cryptography | `unpkg.com/@smartledger/bsv@9.1.1/bsv-shamir.min.js` |
|
|
187
187
|
|
|
188
188
|
### **Utilities**
|
|
189
189
|
| Module | Size | Use Case | CDN |
|
|
190
190
|
|--------|------|----------|-----|
|
|
191
|
-
| **bsv-ecies.min.js** | 137KB | Encryption | `unpkg.com/@smartledger/bsv@9.1.
|
|
192
|
-
| **bsv-message.min.js** | 34KB | Message signing | `unpkg.com/@smartledger/bsv@9.1.
|
|
193
|
-
| **bsv-mnemonic.min.js** | 320KB | HD wallets | `unpkg.com/@smartledger/bsv@9.1.
|
|
191
|
+
| **bsv-ecies.min.js** | 137KB | Encryption | `unpkg.com/@smartledger/bsv@9.1.1/bsv-ecies.min.js` |
|
|
192
|
+
| **bsv-message.min.js** | 34KB | Message signing | `unpkg.com/@smartledger/bsv@9.1.1/bsv-message.min.js` |
|
|
193
|
+
| **bsv-mnemonic.min.js** | 320KB | HD wallets | `unpkg.com/@smartledger/bsv@9.1.1/bsv-mnemonic.min.js` |
|
|
194
194
|
```html
|
|
195
|
-
<script src="https://unpkg.com/@smartledger/bsv@9.1.
|
|
195
|
+
<script src="https://unpkg.com/@smartledger/bsv@9.1.1/bsv.min.js"></script>
|
|
196
196
|
<script>
|
|
197
197
|
const key = bsv.PrivateKey.fromRandom()
|
|
198
198
|
</script>
|
|
@@ -240,4 +240,4 @@ MIT
|
|
|
240
240
|
|
|
241
241
|
---
|
|
242
242
|
|
|
243
|
-
**SmartLedger-BSV v9.1.
|
|
243
|
+
**SmartLedger-BSV v9.1.1**
|