The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Add copy buttons to all
 blocks
(function() {
function addCopyButtons() {
document.querySelectorAll('pre code').forEach(function(codeBlock) {
if (codeBlock.parentElement.hasAttribute('data-copy-added')) return;
codeBlock.parentElement.setAttribute('data-copy-added', 'true');
var btn = document.createElement('button');
btn.textContent = 'Copy';
btn.style.cssText = 'position:absolute;top:4px;right:4px;padding:2px 8px;font-size:11px;background:#4ecdc4;border:none;border-radius:4px;color:#1a1a2e;cursor:pointer;opacity:0.7;transition:opacity 0.2s;';
btn.onmouseover = function() { this.style.opacity = '1'; };
btn.onmouseout = function() { this.style.opacity = '0.7'; };
btn.onclick = function() {
navigator.clipboard.writeText(codeBlock.textContent).then(function() {
btn.textContent = 'Copied!';
setTimeout(function() { btn.textContent = 'Copy'; }, 1500);
});
};
codeBlock.parentElement.style.position = 'relative';
codeBlock.parentElement.appendChild(btn);
});
}
addCopyButtons();
// Re-run on dynamic content
var observer = new MutationObserver(addCopyButtons);
observer.observe(document.body, { childList: true, subtree: true });
})();
}
} catch(__e) { console.warn('[Userscript:Add Copy Buttons to Code Blocks]', __e); }
})();
(function(){
try {
var __m = "github.com";
var __re = new RegExp('^' + "github\\.com" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Force GitHub README to respect dark mode (function() { var style = document.createElement('style'); style.textContent = ' .markdown-body { color-scheme: dark light; } .markdown-body pre { background: #161b22 !important; } .markdown-body code { background: rgba(110, 118, 129, 0.4) !important; } .markdown-body table th, .markdown-body table td { border-color: #30363d !important; } .markdown-body img { background: #0d1117; } .markdown-body blockquote { border-left-color: #8b949e; } .markdown-body hr { border-color: #30363d; } '; document.head.appendChild(style); })(); } } catch(__e) { console.warn('[Userscript:GitHub Dark Mode README Fix]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Highlight search terms from Google/DuckDuckGo/Bing referrer (function() { var ref = document.referrer; var terms = []; if (ref.includes('google.com') || ref.includes('duckduckgo.com') || ref.includes('bing.com')) { var url = new URL(ref); var q = url.searchParams.get('q') || url.searchParams.get('p'); if (q) { terms = q.split(/\s+/).filter(function(t) { return t.length > 2; }); } } if (terms.length === 0) return; var style = document.createElement('style'); style.textContent = '.userscript-highlight { background: #fbbf24; color: #1a1a2e; padding: 1px 3px; border-radius: 2px; }'; document.head.appendChild(style); function highlight(node) { if (node.nodeType === 3) { // text node var text = node.textContent; var found = false; terms.forEach(function(term) { var regex = new RegExp('(' + term.replace(/[.*+?^${}()|[\]\\]/g, '\\') + ')', 'gi'); if (regex.test(text)) { found = true; var frag = document.createDocumentFragment(); var parts = text.split(regex); parts.forEach(function(part, i) { if (i % 2 === 0) { frag.appendChild(document.createTextNode(part)); } else { var span = document.createElement('span'); span.className = 'userscript-highlight'; span.textContent = part; frag.appendChild(span); } }); node.parentNode.replaceChild(frag, node); } }); } else if (node.nodeType === 1 && node.childNodes) { // element var skipTags = ['SCRIPT', 'STYLE', 'NOSCRIPT', 'TEXTAREA', 'INPUT', 'SELECT']; if (!skipTags.includes(node.tagName)) { Array.from(node.childNodes).forEach(highlight); } } } highlight(document.body); // Re-highlight on dynamic content var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1 || node.nodeType === 3) highlight(node); }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Highlight Search Terms]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Strip utm_, fbclid, gclid, etc. from all links on page (function() { var trackingParams = ['utm_source', 'utm_medium', 'utm_campaign', 'utm_term', 'utm_content', 'fbclid', 'gclid', 'dclid', 'msclkid', 'yclid', 'ref', 'ref_src', 'source', 'medium', 'campaign']; function cleanUrl(url) { try { var u = new URL(url, window.location.origin); var changed = false; trackingParams.forEach(function(p) { if (u.searchParams.has(p)) { u.searchParams.delete(p); changed = true; } }); return changed ? u.toString() : url; } catch (e) { return url; } } function cleanLinks() { document.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } cleanLinks(); var observer = new MutationObserver(function(mutations) { mutations.forEach(function(m) { m.addedNodes.forEach(function(node) { if (node.nodeType === 1) { if (node.tagName === 'A') cleanLinks(); node.querySelectorAll('a[href]').forEach(function(a) { var clean = cleanUrl(a.href); if (clean !== a.href) a.href = clean; }); } }); }); }); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:Remove Tracking Parameters from Links]', __e); } })(); (function(){ try { var __m = "youtube.com"; var __re = new RegExp('^' + "youtube\\.com" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Auto-enable theater mode on YouTube (function() { function tryTheater() { var btn = document.querySelector('button[aria-label="Theater mode"], ytd-player #player button[title="Theater mode"]'); if (btn && !btn.classList.contains('activated')) { btn.click(); } } // Try immediately tryTheater(); // Try after navigation (SPA) var lastUrl = location.href; setInterval(function() { if (location.href !== lastUrl) { lastUrl = location.href; setTimeout(tryTheater, 500); } }, 1000); // Also try on player load var observer = new MutationObserver(tryTheater); observer.observe(document.body, { childList: true, subtree: true }); })(); } } catch(__e) { console.warn('[Userscript:YouTube Theater Mode Default]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Remove or un-stick sticky/fixed headers that block content (function() { function unstick() { document.querySelectorAll('header, nav, [role="banner"], .header, .navbar, .sticky, .fixed-top, [style*="position: fixed"], [style*="position:sticky"]').forEach(function(el) { if (el.style.position === 'fixed' || el.style.position === 'sticky' || getComputedStyle(el).position === 'fixed' || getComputedStyle(el).position === 'sticky') { el.style.position = 'static'; el.style.top = 'auto'; el.style.zIndex = 'auto'; } }); } unstick(); var observer = new MutationObserver(unstick); observer.observe(document.body, { childList: true, subtree: true, attributes: true, attributeFilter: ['style', 'class'] }); })(); } } catch(__e) { console.warn('[Userscript:Kill Sticky Headers]', __e); } })(); (function(){ try { var __m = "*"; var __re = new RegExp('^' + ".*" + '
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory
, 'i'); if (__m === '*' || __re.test(location.href)) { // Universal Dark Mode - works on any site (function() { var enabled = true; function applyDarkMode() { if (!enabled) return; // Create style element if it doesn't exist var style = document.getElementById('universal-dark-mode-style'); if (!style) { style = document.createElement('style'); style.id = 'universal-dark-mode-style'; document.head.appendChild(style); } // Dark mode CSS - inverts colors but preserves images/video style.textContent = ' /* Invert everything except media */ html { filter: invert(1) hue-rotate(180deg) !important; background: #1a1a2e !important; } /* Restore images, videos, iframes, canvas */ img, video, iframe, canvas, svg, picture, [style*="background-image"] { filter: invert(1) hue-rotate(180deg) !important; } /* Preserve specific elements that should not be inverted */ .no-dark-mode, .no-dark-mode *, [data-theme="light"], [data-theme="light"], .ace_editor, .ace_editor *, .CodeMirror, .CodeMirror *, .monaco-editor, .monaco-editor *, .markdown-body pre, .markdown-body pre *, .highlight, .highlight *, pre code, pre code * { filter: none !important; } /* Fix common UI elements */ .modal, .popup, .dropdown-menu, .tooltip, .popover { filter: invert(1) hue-rotate(180deg) !important; background: #2d2d44 !important; border-color: #444 !important; } /* Scrollbars */ ::-webkit-scrollbar { background: #1a1a2e !important; } ::-webkit-scrollbar-thumb { background: #444 !important; } ::-webkit-scrollbar-thumb:hover { background: #555 !important; } /* Selection */ ::selection { background: #4ecdc4 !important; color: #1a1a2e !important; } ::-moz-selection { background: #4ecdc4 !important; color: #1a1a2e !important; } '; } function removeDarkMode() { var style = document.getElementById('universal-dark-mode-style'); if (style) style.remove(); } // Toggle with Alt+Shift+D document.addEventListener('keydown', function(e) { if (e.altKey && e.shiftKey && e.key === 'D') { e.preventDefault(); enabled = !enabled; if (enabled) { applyDarkMode(); console.log('[Universal Dark Mode] Enabled'); } else { removeDarkMode(); console.log('[Universal Dark Mode] Disabled'); } } }); // Apply on load applyDarkMode(); // Re-apply on dynamic content var observer = new MutationObserver(function(mutations) { if (enabled && !document.getElementById('universal-dark-mode-style')) { applyDarkMode(); } }); observer.observe(document.head, { childList: true }); console.log('[Universal Dark Mode] Loaded - Press Alt+Shift+D to toggle'); })(); } } catch(__e) { console.warn('[Userscript:Universal Dark Mode]', __e); } })(); })();
Skip to content

The Great Reset - #99

Merged
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure
Jul 6, 2022
Merged

The Great Reset#99
notmandatory merged 5 commits into
bitcoindevkit:masterfrom
rajarshimaitra:restructure

Conversation

@rajarshimaitra

@rajarshimaitrarajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
Contributor

Description

This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.

This makes the code more modular and makes it look like a typical binary rust crate.

There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.

The crate has following modules now

  • main : The main app runtime
  • commands: Includes all the structopt commands used by bdk-cli.
  • handlers: Include all the command handlers used buy the app.
  • utils: Include all the utility and helper functions
  • Backend : Defines the backend node process, and its related methods. (This will be filled more with Unleash the power of Bitcoin Core into bdk-cli #92).

Apart from the structure changes there are few other changes that took place

  • Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app --help commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves Bug in help doc #93.

  • bdk is updated to v0.19.0

  • bdk-reserves is updated with current version pointing to bdk v0.19.0.

  • Default database is now sqlite.

Overall I think I managed not to break anything.

Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.

We also need to update the README to reflect these changes.. I will open that up in a separate PR.

I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..

Notes to the reviewers

Checklists

All Submissions:

  • I've signed all my commits
  • I followed the contribution guidelines
  • I ran cargo fmt and cargo clippy before committing

New Features:

  • I've added tests for the new feature
  • I've added docs for the new feature
  • I've updated CHANGELOG.md

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 0e07ab4 to 428e919CompareJune 15, 2022 22:36
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Currently trying to pass the CI.. Might require few more updates..

@rajarshimaitra
rajarshimaitraforce-pushed the restructure branch 3 times, most recently from 21a9b51 to 124356bCompareJune 15, 2022 23:02
@rajarshimaitra

rajarshimaitra commented Jun 15, 2022

Copy link
Copy Markdown
ContributorAuthor

I think I have hit a dead lock..

Our Previous CI had reserves with other blockchains features.. But the way reserve command is written it cannot be used with anything other than electrum. I am not sure why it wasn't failing before..

So Either we need to enforce that in build.rs or update the reserve command to work with any backend (not sure if possible, bdk-reserves uses the Electrum Api for the job)..

I have updated the CI file to keep only the reserve, electrum test..

But I think it won't be reflected in the CI of this PR.. So tests will now always fail here..

One easy way out now is to make another PR with the CI change, get that merged, and rebase this one on top of the new CI..

Any suggestion @notmandatory ?

Update: All other tests are passing except the reverses, esplora/comapct_filters.

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

CI fix PR opened here #100

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

cc @notmandatory

Waiting for some concept ack on this so I can start rebasing #92 on top of this.. That will take some no trivial refactoring..

@rajarshimaitra

rajarshimaitra commented Jun 17, 2022

Copy link
Copy Markdown
ContributorAuthor

Rebased on top of #100 to make this dependent on it..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Removed bdk-reserves patch after v0,19.0 update..

@notmandatory

Copy link
Copy Markdown
Member

Concept ACK, but looks like some tests still broken. I'm going to be tied up with a PlebFi here in LA this weekend but can spend some time reviewing next week!

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

No issues.. I will work on fixing the tests, and then move #92 on top of it too..

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Pushed some minor doc fixes..

@rajarshimaitra

rajarshimaitra commented Jun 27, 2022

Copy link
Copy Markdown
ContributorAuthor

Added a commit to remove external base64 dependency + some clippy nits..

This PR moves all the components into different module.
Checkout PR description for more details.
We don't need base64 because rust-bitcoin already exposes a version of
that crate that we can use. Removing one more parallel dependency.
@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Rebased on master and removed author list changes..

@rajarshimaitrarajarshimaitra mentioned this pull request Jun 27, 2022
3 tasks

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't review all the code in details since most of it is existing code that was moved. But the general reorganization makes sense.

I tested the commands help and it looked OK. But the repl command doesn't seem to be working, it won't take any command including exit, it just shows the help.

Comment threadsrc/backend.rs Outdated
Comment threadCargo.toml Outdated
Comment threadCargo.toml Outdated
@notmandatory

Copy link
Copy Markdown
Member

My suggestion for the changelog is something like this, based on your PR comments:

  • Reorganize existing code into new modules
  • Rewrite relevant doc comments as structopt help documentation
  • Update bdk and bdk-reserves to v0.19.0
  • Change default database to sqlite

@rajarshimaitra

Copy link
Copy Markdown
ContributorAuthor

Thanks @notmandatory for the look.. Sorry it took me some time to get back to this.. ACK on all the comments.. Updated with a new commit for easier review..

@notmandatory

notmandatory commented Jul 6, 2022

Copy link
Copy Markdown
Member

I pushed a commit to fix a couple little typos and a problem I found in repl mode with command parsing, probably wasn't a new issue but noticed it when testing, had to enable clap::AppSettings::NoBinaryName.

https://docs.rs/structopt/latest/structopt/trait.StructOpt.html#method.from_iter_safe

@notmandatorynotmandatory left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@notmandatory
notmandatory merged commit d8e93ab into bitcoindevkit:masterJul 6, 2022
logosstone pushed a commit to logosstone/bdk-cli that referenced this pull request Jul 7, 2022
292dd1e Fix repl mode command parsing (Steve Myers)
073f1c3 Update with review comments (rajarshimaitra)
4e8f830 revert author list change (rajarshimaitra)
b09c405 Remove base64 dependency (rajarshimaitra)
1e70ff9 Refactor everything (rajarshimaitra)
Pull request description:
<!-- You can erase any parts of this template not applicable to your Pull Request. -->
### Description
This is a massive refactoring PR that changes the whole structure of the crate. Previously it was written like a library
to be used to create the bdk-cli app. But eventually the crate itself became the app. This PR attempts to remove the remaining
lib like patterns in the code, and make it a pure binary crate.
This makes the code more modular and makes it look like a typical binary rust crate.
There was no real good way to structure the change into separate commits, so I made one single big one.. The best way to review is to look at the final structure of the code itself, not the change set.
The crate has following modules now
- `main` : The main app runtime
- `commands`: Includes all the structopt commands used by bdk-cli.
- `handlers`: Include all the command handlers used buy the app.
- `utils`: Include all the utility and helper functions
- `Backend` : Defines the backend node process, and its related methods. (This will be filled more with bitcoindevkit#92).
Apart from the structure changes there are few other changes that took place
- Almost all of the previous doc comments are removed. As they were written to use bdk-cli as a lib. Instead new structopts "comments" are added to describe the app functionality better. As a result the app `--help` commands are more elaborate and descriptive now. I have also removed few redundant description messages used before, that would mess up the help comments. And as a by product it solves bitcoindevkit#93.
- bdk is updated to v0.19.0
- bdk-reserves is updated with current version pointing to bdk v0.19.0.
- Default database is now sqlite.
Overall I think I managed not to break anything.
Currently this change will remove most of the previous documentation on the crate. But those aren't useful to context of bdk-cli after this change.. My proposal would be reproduce the README instructions itself in doc.rs landing page.
We also need to update the README to reflect these changes.. I will open that up in a separate PR.
I also haven't updated changelog yet.. Not sure yet how to describe the change in short.. Will do that once this is almost finalized..
### Notes to the reviewers
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
#### New Features:
* [ ] I've added tests for the new feature
* [ ] I've added docs for the new feature
* [ ] I've updated `CHANGELOG.md`
ACKs for top commit:
notmandatory:
ACK 292dd1e
Tree-SHA512: 895d8088bf93a481fd776e2ac5fe85926f13b7b4535f17b9edd3c0363a89dc3689e28c6e13dbcac3970bc00e3ff206f402e94406f3b3688c9e4a7f9d31b20e40
@notmandatorynotmandatory added the enhancement New feature or request label Jul 14, 2022
rajarshimaitra added a commit that referenced this pull request Sep 20, 2022
f8a5999 Minor grammar and puctuation fixes (Steve Myers)
e7b6854 Update with Readme fixes (rajarshimaitra)
52e8c61 Add all `possible_values` to network command option (Leonardo Lima)
179618c Update crate documentation (rajarshimaitra)
Pull request description:
### Description
After #99 the previous documentation have been removed and new docs as per `structopts` documentation. This PR adds more documentation across the crate..
This PR is above #102 , to accommodate all the further refactoring changes.
The Readme About section have been updated with more details.. Readme format made aligned with the BDK project itself..
The Readme file is used itself as the crate level documentation in docs.rs too..
### Checklists
#### All Submissions:
* [x] I've signed all my commits
* [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md)
* [x] I ran `cargo fmt` and `cargo clippy` before committing
ACKs for top commit:
notmandatory:
ACK f8a5999
Tree-SHA512: 26c5b3903b0215aa9841c4d1079bbdeb9f9d9d458c7e27dddb625db24eb364b73ca978bb2018f486215878f3601b5572ca58d5c202cb74325c992f3e7107d850
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancementNew feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants

@rajarshimaitra@notmandatory