bsv-wallet-postgres 0.2.0 → 0.3.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/bsv/wallet_postgres/postgres_store.rb +17 -0
- data/lib/bsv/wallet_postgres/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b1159b17c5c9a6d0f20be0c47648eab1fbb13f8131e4d9b48d5a13ff5edc8126
|
|
4
|
+
data.tar.gz: 4abd93ce4a43614e4c28b0601d031ce8ca51504dfd2270d6cf58856148dca1d8
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 846999a97dd79648e234d37863bbceeda51478d1926500d4e2176cbae5eb9646fbc240a67bb4c80a6e5554f49cc4ff51ac779c3b1d73c4d2e475fd335449ac1f
|
|
7
|
+
data.tar.gz: 5643c7caead597cf5327ada2b857a0faf375769f46010bc6545cb995130611c3e05b5c27985333f103e1b240573f4dbea4ce6be7259c23cc43d45448da1bcfb0
|
data/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,12 @@ All notable changes to the `bsv-wallet-postgres` gem are documented here.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
|
6
6
|
and this gem adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## 0.3.0 — 2026-04-12
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- `update_action_status` and `delete_action` implementations for PostgresStore,
|
|
12
|
+
matching the new StorageAdapter contract introduced in bsv-wallet 0.6.0 (#370)
|
|
13
|
+
|
|
8
14
|
## 0.2.0 — 2026-04-12
|
|
9
15
|
|
|
10
16
|
### Added
|
|
@@ -102,6 +102,23 @@ module BSV
|
|
|
102
102
|
filter_actions(@db[:wallet_actions], query).count
|
|
103
103
|
end
|
|
104
104
|
|
|
105
|
+
def update_action_status(txid, new_status)
|
|
106
|
+
ds = @db[:wallet_actions].where(txid: txid)
|
|
107
|
+
raise WalletError, "Action not found: #{txid}" if ds.empty?
|
|
108
|
+
|
|
109
|
+
ds.update(
|
|
110
|
+
data: Sequel.lit(
|
|
111
|
+
"data || jsonb_build_object('status', ?)",
|
|
112
|
+
new_status
|
|
113
|
+
)
|
|
114
|
+
)
|
|
115
|
+
symbolise_keys(ds.first[:data])
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
def delete_action(txid)
|
|
119
|
+
@db[:wallet_actions].where(txid: txid).delete.positive?
|
|
120
|
+
end
|
|
121
|
+
|
|
105
122
|
# --- Outputs ---
|
|
106
123
|
|
|
107
124
|
def store_output(output_data)
|
metadata
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: bsv-wallet-postgres
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Simon Bettison
|
|
8
8
|
bindir: bin
|
|
9
9
|
cert_chain: []
|
|
10
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
11
|
dependencies:
|
|
12
12
|
- !ruby/object:Gem::Dependency
|
|
13
13
|
name: bsv-wallet
|
|
@@ -15,7 +15,7 @@ dependencies:
|
|
|
15
15
|
requirements:
|
|
16
16
|
- - ">="
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version: 0.
|
|
18
|
+
version: 0.6.0
|
|
19
19
|
- - "<"
|
|
20
20
|
- !ruby/object:Gem::Version
|
|
21
21
|
version: '1.0'
|
|
@@ -25,7 +25,7 @@ dependencies:
|
|
|
25
25
|
requirements:
|
|
26
26
|
- - ">="
|
|
27
27
|
- !ruby/object:Gem::Version
|
|
28
|
-
version: 0.
|
|
28
|
+
version: 0.6.0
|
|
29
29
|
- - "<"
|
|
30
30
|
- !ruby/object:Gem::Version
|
|
31
31
|
version: '1.0'
|
|
@@ -95,7 +95,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
95
95
|
- !ruby/object:Gem::Version
|
|
96
96
|
version: '0'
|
|
97
97
|
requirements: []
|
|
98
|
-
rubygems_version:
|
|
98
|
+
rubygems_version: 4.0.10
|
|
99
99
|
specification_version: 4
|
|
100
100
|
summary: PostgreSQL storage adapter for bsv-wallet
|
|
101
101
|
test_files: []
|