Web storage follow-ups after #408: wasm round-trip tests and message index
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 42/100
- Issue type
- Feature
- Clarity
- Clearly specified
- Activity status
- Active
- Domain
- databases, performance, testing
Research direction
Read docs/OPTIMIZATION_PLAN.md PR 4.2 and the existing SQLite backend tests for the expected patterns. The issue names IndexedDbStorage, list_messages, open_db, and wasm-bindgen-test as the relevant entry points; start by checking those alongside the current tests. Done means adding IndexedDB round-trip coverage and addressing the message-index, cached-handle, and batched-write follow-ups.
Written by the indexing model from the issue text.
Description
Follow-up to #233, which #408 resolved for the defect itself: every Storage method is now implemented on IndexedDB (messages, settings, trades, trade keys, orders, relays, identity, outbox), the store is opened on the web at bootstrap, and whole-document writes are serialised in-process and across the origin through the Web Locks API.
Two items from #233's "what done looks like" did not land in #408 and are tracked here:
- Round-trip tests under
wasm-bindgen-testmirroring the SQLite backend's tests. Today the web backend is covered by native unit tests of the pure document patching (db::trade_json), bycargo clippy --target wasm32-unknown-unknown, and by live end-to-end trades driven through the browser by Mortsom; there is no unit suite that exercisesIndexedDbStorageitself. - Message index and single DB handle.
list_messagesstill scans the wholemessagesstore and JSON-parses every document, andopen_dbopens the database per operation.docs/OPTIMIZATION_PLAN.mdPR 4.2 already describes the fix: cache the handle, index messages bytrade_id, batch writes.
Nothing here affects correctness on the web; both are test coverage and performance.
- Dominant language
- Dart
- Stars
- 11
- Forks
- 9
- Avg merge
- 20h 34m
- Merged PRs (30d)
- 233
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from MostroP2P/app
-
area: rust-core bug priority: low
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
Maintainers usually reply within 1 day
-
area: ui
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
AimesSoft/NipaPlay-Reload#1021 ·
Maintainers usually reply within 1 day
-
enhancement triage
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
fluttercommunity/plus_plugins#4004 ·
Maintainers usually reply within 1 day
-
agent:ready bug P2 · 中 健壮性 区域: 启动与合规 待验证 隐私与合规
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
ASDW51/DanmuFloat#106 ·
Maintainers usually reply within 1 day
-
c: proposal p: go_router package team-ecosystem
Difficulty 2/5 1-3 hours Newbie friendliness 60/100
flutter/flutter#194542 · 1 comment ·
Maintainers usually reply within 1 day
-
enhancement good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 80/100