Feat:IBD status page#6562
Draft
jramos0 wants to merge 3 commits into
Draft
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an IBD/indexing “Getting started” experience for self-hosted deployments by introducing a sync-progress API and a new frontend route/page that displays progress instead of showing an unusable dashboard during initial sync.
Changes:
- Added backend
GET /api/v1/sync-progressendpoint to expose Bitcoin Core IBD status and a basic “indexed/not indexed” indicator. - Added a new Angular
getting-startedlazy-loaded page with progress UI and periodic polling. - Wired the app shell to redirect to the getting-started page when the node is reported as in IBD.
Reviewed changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| frontend/src/app/services/api.service.ts | Adds getSyncProgress$() API method. |
| frontend/src/app/master-page.module.ts | Registers the new getting-started route. |
| frontend/src/app/interfaces/node-api.interface.ts | Adds SyncProgress frontend interface. |
| frontend/src/app/components/getting-started/getting-started.module.ts | Introduces the getting-started module + routing. |
| frontend/src/app/components/getting-started/getting-started.component.ts | Implements polling and ETA formatting for the status page. |
| frontend/src/app/components/getting-started/getting-started.component.html | Renders the progress UI (Bitcoin Core + electrs/indexing section). |
| frontend/src/app/components/getting-started/getting-started.component.scss | Styles the new status/progress UI. |
| frontend/src/app/components/app/app.component.ts | Adds startup redirect to /getting-started based on sync status. |
| frontend/package-lock.json | Updates Cypress (and related transitive deps) lock entries. |
| backend/src/mempool.interfaces.ts | Adds IBDProgress backend interface. |
| backend/src/api/bitcoin/bitcoin.routes.ts | Adds the /sync-progress endpoint and ETA estimation logic. |
Comment on lines
1
to
5
| import { Location, ViewportScroller } from '@angular/common'; | ||
| import { Component, HostListener, OnInit, Inject, LOCALE_ID, HostBinding } from '@angular/core'; | ||
| import { Router, NavigationEnd, Scroll } from '@angular/router'; | ||
| import { ApiService } from '@app/services/api.service'; | ||
| import { StateService } from '@app/services/state.service'; |
Comment on lines
+60
to
+64
| this.apiService.getSyncProgress$().subscribe((progress) => { | ||
| if (progress.ibd && !this.location.path().startsWith('/getting-started')) { | ||
| this.router.navigate(['/getting-started']); | ||
| } | ||
| }); |
Comment on lines
+6
to
+9
| <div class="sync-header"> | ||
| <span class="sync-label" i18n="getting-started.bitcoin-core.label">Downloading and validating blocks</span> | ||
| <span class="sync-network">mainnet</span> | ||
| </div> |
Comment on lines
+18
to
+22
| constructor( | ||
| private apiService: ApiService, | ||
| private cd: ChangeDetectorRef, | ||
| ) { } | ||
|
|
Comment on lines
57
to
60
| "optionalDependencies": { | ||
| "@cypress/schematic": "^2.5.0", | ||
| "cypress": "^15.16.0", | ||
| "cypress": "^15.13.0", | ||
| "cypress-fail-on-console-error": "~5.1.1", |
Comment on lines
+60
to
+64
| this.apiService.getSyncProgress$().subscribe((progress) => { | ||
| if (progress.ibd && !this.location.path().startsWith('/getting-started')) { | ||
| this.router.navigate(['/getting-started']); | ||
| } | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a dedicated getting started page for self-hosted instances while Bitcoin Core is in IBD and backend indexing is still in progress.
This replaces the broken dashboard/skeleton-loader experience with a user-friendly status page showing sync/indexing progress.
Changes
Fixes #6558