Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dev tooling #22

Merged
merged 3 commits into from
Dec 5, 2024
Merged

Conversation

tcharding
Copy link
Member

@tcharding tcharding commented Dec 5, 2024

Add two new tools

  • A Perl script to create the rustdocs list found in, for example types/src/v17/mod.rs
  • A Rust verify tool that parses the RPC text file and then greps the codebase doing various checks.

The verify tool is so that one can look at the docs for version specific types (the list of method names and implementation status) and have confidence that they are correct.

I'm going to merge and release this without review because its just an additional unreleased dev tool. The fixes included in this PR are what I wanted to have confidence in the next release.

The next thing I want to verify is that the methods documented as returning nothing or stdlib types really do so by either hitting Core or grepping the source ... one day.

Add a Perl script that creates the rustdocs for a version specific
module it `types` e.g., `types/src/v17/mod.rs`.
@tcharding tcharding force-pushed the 12-05-add-verify-tool branch from a1e4ee1 to 5edaa24 Compare December 5, 2024 23:02
Add a tool to help verify that what we have done is correct.

Adds crate that when run produces:

```bash
Verifying support for Bitcoin Core v17

        Checking he documented methods are correct for this version of Core ... ✓
        The documented status is correct ... ✓
```

Run the tool for v17 module and fix the few mistakes it found - WIN!

Then fix up the docs in v18 and run the tool to verify the v18 stuff
is correct.
@tcharding tcharding force-pushed the 12-05-add-verify-tool branch from 5edaa24 to 4fdea9c Compare December 5, 2024 23:23
@tcharding tcharding merged commit 25eb57e into rust-bitcoin:master Dec 5, 2024
32 checks passed
@tcharding
Copy link
Member Author

Ugh, I clicked merge instead of ack'ing and using the merge script.

@tcharding
Copy link
Member Author

Just crossed my mind that you have been gracious in helping me out with this crate @apoelstra, I merged this to save you the time/effort of looking at it. Didn't mean to brush you. I figured its easier to just pull master and play with the verify crate in this PR.

@apoelstra
Copy link
Member

Yeah, no problem. I don't want to hold you up with process. But if I see stuff that's open I'll probably take a quick look and run through my local CI.

@tcharding tcharding deleted the 12-05-add-verify-tool branch December 6, 2024 21:32
@apoelstra
Copy link
Member

This PR broke Cargo-minimal.lock (and maybe the other one) by adding the MSRV-incompatible regex-automata package.

@tcharding
Copy link
Member Author

Oh I should have excluded it from the workspace, woops. How did that pass CI I wonder.

@tcharding
Copy link
Member Author

Fixed in #35

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants