From 0031fbf886c2537aac2524f7ec34fc782fc589b7 Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Mon, 13 Jun 2022 21:03:17 -0400 Subject: [PATCH 1/8] Fix anchor links on new ng faq template --- frontend/src/app/docs/api-docs/api-docs.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/app/docs/api-docs/api-docs.component.ts b/frontend/src/app/docs/api-docs/api-docs.component.ts index 69abd18de..323eb1ba6 100644 --- a/frontend/src/app/docs/api-docs/api-docs.component.ts +++ b/frontend/src/app/docs/api-docs/api-docs.component.ts @@ -36,6 +36,7 @@ export class ApiDocsComponent implements OnInit, AfterViewInit { ngAfterViewInit() { const that = this; + this.faqTemplates.forEach((x) => this.dict[x.type] = x.template); setTimeout( () => { if( this.route.snapshot.fragment ) { this.openEndpointContainer( this.route.snapshot.fragment ); @@ -44,7 +45,6 @@ export class ApiDocsComponent implements OnInit, AfterViewInit { window.addEventListener('scroll', function() { that.desktopDocsNavPosition = ( window.pageYOffset > 182 ) ? "fixed" : "relative"; }, { passive: true} ); - this.faqTemplates.forEach((x) => this.dict[x.type] = x.template); }, 1 ); } From 8de1fb52898218c779d1e2facaacc0d6fa93ca05 Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Mon, 13 Jun 2022 21:08:44 -0400 Subject: [PATCH 2/8] Fix stray typos from moving faqs to html --- frontend/src/app/docs/api-docs/api-docs.component.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/frontend/src/app/docs/api-docs/api-docs.component.html b/frontend/src/app/docs/api-docs/api-docs.component.html index 90ec13695..386bab7d2 100644 --- a/frontend/src/app/docs/api-docs/api-docs.component.html +++ b/frontend/src/app/docs/api-docs/api-docs.component.html @@ -108,7 +108,7 @@ -

A mempool (short for "memory pool") the queue of pending and unconfirmed transactions for a cryptocurrency network node. There is no one global mempool: every node on the network maintains its own mempool, so different nodes may hold different transactions in their mempools.

+

A mempool (short for "memory pool") is the queue of pending and unconfirmed transactions for a cryptocurrency network node. There is no one global mempool: every node on the network maintains its own mempool, so different nodes may hold different transactions in their mempools.

@@ -127,7 +127,7 @@ - Mining is the process by which unconfirmed transactions in a mempool are confirmed into a block on a blockchain. Miners select unconfirmed transactions from their mempools and arrange them into a block such that they solve a particular math problem.

The first miner on the network to find a suitable block earns all the transaction fees from the transactions in that block. As a result, miners tend to prioritize transactions with higher transaction fees.

+

Mining is the process by which unconfirmed transactions in a mempool are confirmed into a block on a blockchain. Miners select unconfirmed transactions from their mempools and arrange them into a block such that they solve a particular math problem.

The first miner on the network to find a suitable block earns all the transaction fees from the transactions in that block. As a result, miners tend to prioritize transactions with higher transaction fees.

@@ -135,7 +135,7 @@ -

When a Bitcoin transaction is made, it is stored in a Bitcoin node's mempool before it is confirmed into a block. When the rate of incoming transactions exceeds the rate transactions are confirmed, the mempool grows in size.

The default maximum size of a Bitcoin node's mempool is 300MB, so when there are 300MB of transactions in the mempool, we say it's \"full\".

+

When a Bitcoin transaction is made, it is stored in a Bitcoin node's mempool before it is confirmed into a block. When the rate of incoming transactions exceeds the rate transactions are confirmed, the mempool grows in size.

The default maximum size of a Bitcoin node's mempool is 300MB, so when there are 300MB of transactions in the mempool, we say it's "full".

@@ -183,7 +183,7 @@ - You can manually install mempool on your own Linux server, but this requires advanced sysadmin skills since you will be manually configuring everything. We do not provide support for manual deployments." + You can manually install mempool on your own Linux server, but this requires advanced sysadmin skills since you will be manually configuring everything. We do not provide support for manual deployments. From b82abc282763f9b8926b92465d0daf094ac6b31f Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Mon, 13 Jun 2022 21:11:57 -0400 Subject: [PATCH 3/8] Make minor faq updates Add Start9 and capitalize Mempool. --- frontend/src/app/docs/api-docs/api-docs.component.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/app/docs/api-docs/api-docs.component.html b/frontend/src/app/docs/api-docs/api-docs.component.html index 386bab7d2..1f6fca48c 100644 --- a/frontend/src/app/docs/api-docs/api-docs.component.html +++ b/frontend/src/app/docs/api-docs/api-docs.component.html @@ -179,11 +179,11 @@ - We support one-click installation on a number of Raspberry Pi full-node distros including Umbrel, RaspiBlitz, MyNode, and RoninDojo. + We support one-click installation on a number of Raspberry Pi full-node distros including Umbrel, RaspiBlitz, MyNode, RoninDojo, and Start9's Embassy. - You can manually install mempool on your own Linux server, but this requires advanced sysadmin skills since you will be manually configuring everything. We do not provide support for manual deployments. + You can manually install Mempool on your own Linux server, but this requires advanced sysadmin skills since you will be manually configuring everything. We do not provide support for manual deployments. From 9fe4cc2d2b3b8d769fc21133c2a06246f3c3eb38 Mon Sep 17 00:00:00 2001 From: nymkappa Date: Sat, 11 Jun 2022 00:04:19 +0200 Subject: [PATCH 4/8] Only show `(1w)` on `Blocks` in pool ranking widget Add tooltips to explain `Pools luck`, `Pools count` and `Blocs (1w)` --- .../pool-ranking/pool-ranking.component.html | 27 ++++++++++--------- .../pool-ranking/pool-ranking.component.scss | 3 ++- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/frontend/src/app/components/pool-ranking/pool-ranking.component.html b/frontend/src/app/components/pool-ranking/pool-ranking.component.html index 738f540f3..4651b62c1 100644 --- a/frontend/src/app/components/pool-ranking/pool-ranking.component.html +++ b/frontend/src/app/components/pool-ranking/pool-ranking.component.html @@ -5,24 +5,27 @@
-
Pools Luck (1w)
-

+

Pools luck
+

{{ miningStats['minersLuck'] }}%

-
Blocks (1w)
-

- {{ miningStats.blockCount }} +

Pools count
+

+ {{ miningStats.pools.length }}

-
Pools Count (1w)
-

- {{ miningStats.pools.length }} +

Blocks (1w)
+

+ {{ miningStats.blockCount }}

@@ -142,4 +145,4 @@

-
\ No newline at end of file + diff --git a/frontend/src/app/components/pool-ranking/pool-ranking.component.scss b/frontend/src/app/components/pool-ranking/pool-ranking.component.scss index 4f46c8927..855b4e65c 100644 --- a/frontend/src/app/components/pool-ranking/pool-ranking.component.scss +++ b/frontend/src/app/components/pool-ranking/pool-ranking.component.scss @@ -89,7 +89,7 @@ flex-direction: row; } h5 { - margin-bottom: 10px; + margin-bottom: 5px; } .item { max-width: 160px; @@ -103,6 +103,7 @@ } } &:nth-child(3) { + width: 50%; order: 3; @media (min-width: 485px) { order: 2; From 9d20637dcbc0e34aaf005a50a940d813c45876b4 Mon Sep 17 00:00:00 2001 From: nymkappa Date: Tue, 14 Jun 2022 09:58:32 +0200 Subject: [PATCH 5/8] Hide bottom axis label for mempool and incoming tx charts on widgets --- .../incoming-transactions-graph.component.ts | 2 +- .../src/app/components/mempool-graph/mempool-graph.component.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/app/components/incoming-transactions-graph/incoming-transactions-graph.component.ts b/frontend/src/app/components/incoming-transactions-graph/incoming-transactions-graph.component.ts index 328742946..33ae2d320 100644 --- a/frontend/src/app/components/incoming-transactions-graph/incoming-transactions-graph.component.ts +++ b/frontend/src/app/components/incoming-transactions-graph/incoming-transactions-graph.component.ts @@ -127,7 +127,7 @@ export class IncomingTransactionsGraphComponent implements OnInit, OnChanges { }, xAxis: [ { - name: formatterXAxisLabel(this.locale, this.windowPreference), + name: this.template === 'widget' ? '' : formatterXAxisLabel(this.locale, this.windowPreference), nameLocation: 'middle', nameTextStyle: { padding: [20, 0, 0, 0], diff --git a/frontend/src/app/components/mempool-graph/mempool-graph.component.ts b/frontend/src/app/components/mempool-graph/mempool-graph.component.ts index dfb111fdb..04c7ddf69 100644 --- a/frontend/src/app/components/mempool-graph/mempool-graph.component.ts +++ b/frontend/src/app/components/mempool-graph/mempool-graph.component.ts @@ -319,7 +319,7 @@ export class MempoolGraphComponent implements OnInit, OnChanges { }, xAxis: [ { - name: formatterXAxisLabel(this.locale, this.windowPreference), + name: this.template === 'widget' ? '' : formatterXAxisLabel(this.locale, this.windowPreference), nameLocation: 'middle', nameTextStyle: { padding: [20, 0, 0, 0], From 20a4b9fb5a6621d61fb9b4bd399e315b92754838 Mon Sep 17 00:00:00 2001 From: nymkappa Date: Tue, 14 Jun 2022 10:35:29 +0200 Subject: [PATCH 6/8] Make Latest blocks and Adjustments widget title clickable --- .../mining-dashboard.component.html | 14 ++++++++++---- .../mining-dashboard.component.scss | 7 +++++++ .../src/app/dashboard/dashboard.component.html | 12 +++++++----- .../src/app/dashboard/dashboard.component.scss | 7 +++++++ 4 files changed, 31 insertions(+), 9 deletions(-) diff --git a/frontend/src/app/components/mining-dashboard/mining-dashboard.component.html b/frontend/src/app/components/mining-dashboard/mining-dashboard.component.html index fe7c08ba2..b0ec46ac5 100644 --- a/frontend/src/app/components/mining-dashboard/mining-dashboard.component.html +++ b/frontend/src/app/components/mining-dashboard/mining-dashboard.component.html @@ -49,9 +49,12 @@ @@ -60,9 +63,12 @@ diff --git a/frontend/src/app/components/mining-dashboard/mining-dashboard.component.scss b/frontend/src/app/components/mining-dashboard/mining-dashboard.component.scss index 3ee108d9d..303591974 100644 --- a/frontend/src/app/components/mining-dashboard/mining-dashboard.component.scss +++ b/frontend/src/app/components/mining-dashboard/mining-dashboard.component.scss @@ -97,3 +97,10 @@ .card-text { font-size: 22px; } + +.title-link, .title-link:hover, .title-link:focus, .title-link:active { + display: block; + margin-bottom: 10px; + text-decoration: none; + color: inherit; +} \ No newline at end of file diff --git a/frontend/src/app/dashboard/dashboard.component.html b/frontend/src/app/dashboard/dashboard.component.html index 99ae4a301..4eb95c1ca 100644 --- a/frontend/src/app/dashboard/dashboard.component.html +++ b/frontend/src/app/dashboard/dashboard.component.html @@ -103,10 +103,14 @@ -
+
-
Latest blocks
+ +
Latest blocks
+   + +
@@ -136,11 +140,10 @@
Height
-
-
+
Latest transactions
@@ -160,7 +163,6 @@ -
 
diff --git a/frontend/src/app/dashboard/dashboard.component.scss b/frontend/src/app/dashboard/dashboard.component.scss index 81e7a671d..a7e21ba94 100644 --- a/frontend/src/app/dashboard/dashboard.component.scss +++ b/frontend/src/app/dashboard/dashboard.component.scss @@ -317,3 +317,10 @@ vertical-align: text-top; padding-left: 10px; } + +.title-link, .title-link:hover, .title-link:focus, .title-link:active { + display: block; + margin-bottom: 10px; + text-decoration: none; + color: inherit; +} \ No newline at end of file From ca92834493c20a255887c664d70bca79df57e6f0 Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Wed, 15 Jun 2022 13:11:59 -0400 Subject: [PATCH 7/8] Edit formatting of regtest docs --- backend/README.md | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/backend/README.md b/backend/README.md index b65001182..823998fdc 100644 --- a/backend/README.md +++ b/backend/README.md @@ -160,57 +160,56 @@ nodemon src/index.ts --ignore cache/ --ignore pools.json `nodemon` should be in npm's global binary folder. If needed, you can determine where that is with `npm -g bin`. -### Regtest cheatsheets +### Useful Regtest Commands -* Useful link https://gist.github.com/System-Glitch/cb4e87bf1ae3fec9925725bb3ebe223a +Helpful link: https://gist.github.com/System-Glitch/cb4e87bf1ae3fec9925725bb3ebe223a -* Run bitcoind for regtest +Run bitcoind on regtest: ``` bitcoind -regtest -rpcport=8332 ``` -* If it's the first time, create a new wallet +Create a new wallet, if needed: ``` bitcoin-cli -regtest -rpcport=8332 createwallet test ``` -* If it's not the first time, load the wallet. This command may take a while if you have lot of utxos +Load wallet (this command may take a while if you have lot of UTXOs): ``` bitcoin-cli -regtest -rpcport=8332 loadwallet test ``` -* Get a new address +Get a new address: ``` address=$(./src/bitcoin-cli -regtest -rpcport=8332 getnewaddress) ``` -* Mine blocks to the previously generated new address, you need at least 101 blocks before being able to spend. This will take some time to execute (~1 min) +Mine blocks to the previously generated address. You need at least 101 blocks before you can spend. This will take some time to execute (~1 min): ``` bitcoin-cli -regtest -rpcport=8332 generatetoaddress 101 $address ``` -* Send 0.1 BTC at 5 sat/vB to another address +Send 0.1 BTC at 5 sat/vB to another address: ``` ./src/bitcoin-cli -named -regtest -rpcport=8332 sendtoaddress address=$(./src/bitcoin-cli -regtest -rpcport=8332 getnewaddress) amount=0.1 fee_rate=5 ``` -* See more example of `sendtoaddress` +See more example of `sendtoaddress`: ``` ./src/bitcoin-cli sendtoaddress # will print the help ``` -* Mini script to generate transactions with random TX fee-rate (between 1 to 100 sat/vB). It's slow so don't expect to use this to test mempool spam, except if you let it run for a long time, or maybe with multiple regtest node connected to each other. +Mini script to generate transactions with random TX fee-rate (between 1 to 100 sat/vB). It's slow so don't expect to use this to test mempool spam, except if you let it run for a long time, or maybe with multiple regtest nodes connected to each other. ``` #!/bin/bash address=$(./src/bitcoin-cli -regtest -rpcport=8332 getnewaddress) for i in {1..1000000} do - ./src/bitcoin-cli -regtest -rpcport=8332 -named sendtoaddress address=$address amount=0.01 fee_rate=$(jot -r 1 1 100) + ./src/bitcoin-cli -regtest -rpcport=8332 -named sendtoaddress address=$address amount=0.01 fee_rate=$(jot -r 1 1 100) done ``` -* Generate block at regular interval (every 10 sec in this example) +Generate block at regular interval (every 10 seconds in this example): ``` watch -n 10 "./src/bitcoin-cli -regtest -rpcport=8332 generatetoaddress 1 $address" ``` - From 539d41f19ea6e4e190e89a2fb18aa0992e388bae Mon Sep 17 00:00:00 2001 From: hunicus <93150691+hunicus@users.noreply.github.com> Date: Wed, 15 Jun 2022 15:51:11 -0400 Subject: [PATCH 8/8] Add k3tan video link to docker readme --- docker/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docker/README.md b/docker/README.md index 45bdff615..286201548 100644 --- a/docker/README.md +++ b/docker/README.md @@ -4,6 +4,8 @@ This directory contains the Dockerfiles used to build and release the official i If you are looking to use these Docker images to deploy your own instance of Mempool, note that they only containerize Mempool's frontend and backend. You will still need to deploy and configure Bitcoin Core and an Electrum Server separately, along with any other utilities specific to your use case (e.g., a reverse proxy, etc). Such configuration is mostly beyond the scope of the Mempool project, so please only proceed if you know what you're doing. +See a video guide of this installation method by k3tan [on BitcoinTV.com](https://bitcointv.com/w/8fpAx6rf5CQ16mMhospwjg). + Jump to a section in this doc: - [Configure with Bitcoin Core Only](#configure-with-bitcoin-core-only) - [Configure with Bitcoin Core + Electrum Server](#configure-with-bitcoin-core--electrum-server)