Record each order's node in the local store and report it in order mine
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 25/100
Hướng nghiên cứu
Start with the local order store and the code behind order mine, order new, order take-sell/order take-buy and order sync, then the store's migration path. Decide the open question first: whether rows with an unknown node are listed without a filter. Done means the node's public key is stored on each of those paths, order mine reports node_pubkey (null for old rows), --node accepts hex or npub, old stores open after migration, and docs/commands.md is updated.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Problem
The local order store does not record which Mostro node an order belongs to. At 0.17.1, an order mine row carries id, side, status, trade_index and trade_pubkey, and nothing about the node the order was made, taken or adopted on.
An identity can trade on several nodes, since MOSTRO_PUBKEY is just configuration. A client therefore cannot tell which orders a node change would strand. MostroP2P/mcp#11 lets an agent switch between the trusted nodes, and has to refuse the switch while any order in the store is not finished, on any node. The consequences:
- An open order on node A blocks a switch from node B to C, even though it has nothing to do with B.
- An order the node already closed, whose local status is stale, blocks every switch.
- Order-scoped commands (
order info,order watch,order chat, the trade steps) always use the configured node. A client cannot follow a trade on node A while configured for node B.
Proposal
- Record the node. Store the node's public key (lowercase hex) with each order when it is created (
order new), taken (order take-sell/order take-buy) or adopted (order sync). - Report it. Add
node_pubkeyto eachorder minerow in the JSON output (and to the human table). Rows written before this change have no node: reportnull, never a guess. - Filter by it. Add
order mine --node=<hex|npub>to list only one node's orders (rows with an unknown node are listed under no filter only, or with an explicit option; the spec should decide).
A follow-up, not in this issue: order-scoped commands could use the order's recorded node when it differs from the configured one, so a trade can be followed after a node change.
Acceptance criteria
- New orders from
order new, both take commands andorder syncstore the node's public key; a test covers each path. -
order mineJSON rows includenode_pubkey(nullfor older rows), and the output schema inmostro-cli --output json schemasays so. -
order mine --node=…returns only that node's orders and accepts hex or npub. - Existing stores open without error, through a migration that adds the column with no value for old rows.
-
docs/commands.mdand the mostro-cli book document the field and the filter.
- Ngôn ngữ chính
- Rust
- Star
- 39
- Fork
- 16
- Merge trung bình
- 6 giờ
- Pull request đã merge (30 ngày)
- 50
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của MostroP2P/mostro-cli
-
Add a JSON node status command that reads a node's health eventCó thể làm lại được @victrvondoom đã nhận 14 ngày trước và không có pull request nào đang mở. Đang mởenhancement status: accepted
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
MostroP2P/mostro-cli#271 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
MostroP2P/mostro-cli#242 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Stablecoins as order currencies: check market price against the node's rates, not YadioCó thể đã có người làm @grunch đã nhận 41 ngày trước. Đang mởenhancement
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 56/100
MostroP2P/mostro-cli#213 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 Nửa ngày Mức phù hợp với người mới 74/100
MostroP2P/mostro-cli#200 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
MostroP2P/mostro-cli#188 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của MostroP2P/mostro-cli
Issue tương tự
-
bug llm translation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày
-
build comp-keeper
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
ClickHouse/ClickHouse#137202 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:ops chore priority:low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
jdrouet/tinyobserve#267 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Sweep due before phase 95Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
storytold/photocraft#20056 ·
Maintainer thường phản hồi trong vòng 1 ngày