Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,14 @@ names, environment variables, exit codes, error codes, and the shape of

## [Unreleased]

## [0.7.3] - 2026-10-11

### Changed

- `fees` describes the minimum as the least any pool has recently mined
(which may take longer to confirm), matching how Dogechain.com now
calculates it. Dollar amounts under $0.0001 show as `<$0.0001`.

## [0.7.2] - 2026-10-09

### Changed
Expand Down Expand Up @@ -166,7 +174,8 @@ names, environment variables, exit codes, error codes, and the shape of
- Installers: Homebrew (`blockio/tap/dogechain`), npm (`dogechain`), shell script, PowerShell,
and prebuilt binaries for macOS, Linux and Windows.

[Unreleased]: https://github.com/BlockIo/dogechain-cli/compare/v0.7.2...HEAD
[Unreleased]: https://github.com/BlockIo/dogechain-cli/compare/v0.7.3...HEAD
[0.7.3]: https://github.com/BlockIo/dogechain-cli/compare/v0.7.2...v0.7.3
[0.7.2]: https://github.com/BlockIo/dogechain-cli/compare/v0.7.1...v0.7.2
[0.7.1]: https://github.com/BlockIo/dogechain-cli/compare/v0.7.0...v0.7.1
[0.7.0]: https://github.com/BlockIo/dogechain-cli/compare/v0.6.1...v0.7.0
Expand Down
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dogechain-cli"
version = "0.7.2"
version = "0.7.3"
edition = "2024"
rust-version = "1.88"
description = "Command-line interface for Dogechain.com"
Expand Down
9 changes: 6 additions & 3 deletions src/commands.rs
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,10 @@ fn show_network(out: &mut dyn Write, r: &NetworkReply) -> Result<()> {
fn show_fees(out: &mut dyn Write, r: &FeesReply) -> Result<()> {
let usd = |d: Doge| {
r.price_usd
.map(|p| format!(" (${:.4})", d.0 as f64 / KOINU_PER_DOGE * p))
.map(|p| match d.0 as f64 / KOINU_PER_DOGE * p {
v if v > 0.0 && v < 0.0001 => " (<$0.0001)".to_owned(),
v => format!(" (${v:.4})"),
})
.unwrap_or_default()
};
let sp = &r.simple_payment;
Expand All @@ -496,14 +499,14 @@ fn show_fees(out: &mut dyn Write, r: &FeesReply) -> Result<()> {
)?;
writeln!(
out,
"The least it can pay: {} DOGE{}.",
"The least any pool has recently mined: {} DOGE{}, which may take longer to confirm.",
sp.min_fee,
usd(sp.min_fee)
)?;
}
None => writeln!(
out,
"A simple payment ({} bytes) needs at least {} DOGE in fees{}.",
"The least a simple payment ({} bytes) has recently been mined with: {} DOGE{}.",
sp.bytes,
sp.min_fee,
usd(sp.min_fee)
Expand Down
3 changes: 2 additions & 1 deletion src/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,9 @@ pub struct FeeRates {
#[derive(Debug, Deserialize)]
pub struct SimplePayment {
pub bytes: u64,
/// The least any pool has recently mined (never below the relay floor).
pub min_fee: Doge,
/// What the API suggests paying to make the next block.
/// What recent blocks show gets mined within a few minutes.
#[serde(default)]
pub suggested_fee: Option<Doge>,
}
Expand Down
2 changes: 1 addition & 1 deletion src/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ pub fn schema() -> Value {
},
"fees": {
"api": "GET /api/v3/fees",
"data": "fee_rate_koinu_per_byte{min, median, max}, simple_payment{bytes, min_fee, suggested_fee}, suggested_fee_rate_koinu_per_byte, suggested_fee_basis (plain English), median_fee_paid, median_fee_paid_blocks, mempool{txs, bytes, next_block_txs}, price_usd"
"data": "fee_rate_koinu_per_byte{min, median, max}, simple_payment{bytes, min_fee (the least any pool has recently mined), suggested_fee (mined within about 3 blocks 95 times in 100)}, suggested_fee_rate_koinu_per_byte, least_fee_rate_koinu_per_byte, suggested_fee_basis (plain English), median_fee_paid, median_fee_paid_blocks, mempool{txs, bytes, next_block_txs}, price_usd"
},
"supply": {
"api": "GET /api/v3/supply",
Expand Down
4 changes: 2 additions & 2 deletions tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ fn fees_in_plain_english() {
.assert()
.success()
.stdout(predicate::str::contains(
"A simple payment (226 bytes) needs at least 0.00226 DOGE in fees ($0.0002).",
"The least a simple payment (226 bytes) has recently been mined with: 0.00226 DOGE ($0.0002).",
))
.stdout(predicate::str::contains("min 0.01, median 0.015, max 0.5"));
}
Expand Down Expand Up @@ -1104,7 +1104,7 @@ fn fees_lead_with_the_suggested_fee() {
let text = String::from_utf8(out.stdout).unwrap();
assert!(
text.starts_with(
"Suggested fee for a simple payment (226 bytes): 0.01 DOGE. Why: the next block has room for everything waiting.\nThe least it can pay: 0.00226452 DOGE.\n"
"Suggested fee for a simple payment (226 bytes): 0.01 DOGE. Why: the next block has room for everything waiting.\nThe least any pool has recently mined: 0.00226452 DOGE, which may take longer to confirm.\n"
),
"{text}"
);
Expand Down
Loading