Skip to content

Commit 9783c78

Browse files
committed
Fix broken links and update quickstart
1 parent 730d259 commit 9783c78

File tree

3 files changed

+39
-11
lines changed

3 files changed

+39
-11
lines changed

docs/reference/quickstart.md

Lines changed: 36 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@ in [test-gen][test-gen]
1919
The specification itself is written in [OpenRPC][openrpc]. Refer to the OpenRPC
2020
specification and the JSON schema [specification][json-schema] to get started.
2121

22-
### Building
22+
### Updating the specs
2323

24+
#### Compiling
2425
The specification is split into multiple files to improve readability. The
2526
spec can be compiled into a single document as follows:
2627

@@ -33,11 +34,26 @@ Build successful.
3334
This will output the file `openrpc.json` in the root of the project. This file
3435
will have all schema `#ref`s resolved.
3536

36-
#### Testing
37+
#### Building the docs
38+
39+
Once you've updated something in the spec, you can use the docs generation tools
40+
to view the updated specs locally.
41+
42+
```console
43+
$ npm run build:docs
44+
$ npm run watch
45+
```
46+
47+
The `watch` command starts a local webserver serving the docs in-browser at
48+
`http://0.0.0.0:8000` and it rebuilds when you update something in the specs.
49+
Please reload the page to see your changes.
50+
51+
### Testing
3752

3853
There are several mechanisms for testing specification contributions and client
3954
conformance.
4055

56+
#### Linting
4157
First is the [OpenRPC validator][validator]. It performs some basic syntactic
4258
checks on the generated specification.
4359

@@ -47,13 +63,21 @@ $ npm run lint
4763
OpenRPC spec validated successfully.
4864
```
4965

66+
#### Spec tests
5067
Next is `speccheck`. This tool validates the test cases in the `tests`
51-
directory against the specification.
68+
directory against the specification. There are two npm scripts to simplify this.
69+
70+
```console
71+
$ npm run build:test
72+
$ npm run test
73+
all passing.
74+
```
75+
76+
or
5277

5378
```console
5479
$ go install github.com/lightclient/rpctestgen/cmd/speccheck@latest
5580
$ speccheck -v
56-
all passing.
5781
```
5882

5983
If you get an error that says: `speccheck: command not found`,
@@ -63,6 +87,8 @@ If you get an error that says: `speccheck: command not found`,
6387
$ export PATH=$HOME/go/bin:$PATH
6488
```
6589

90+
#### Spelling
91+
6692
The spell checker ensures the specification is free of spelling errors.
6793

6894
```console
@@ -75,8 +101,9 @@ pyspelling is a wrapper around either [Aspell](http://aspell.net/) or
75101
[Hunspell](https://hunspell.github.io/). You'll need to install
76102
one of those before running `pyspelling`.
77103

104+
#### Hive tests
78105
Finally, the test cases in the `tests/` directory may be run against individual
79-
execution client using the [`hive`] simulator [`rpc-compat`][rpc-compat].
106+
execution client using the [`hive`][hive] simulator [`rpc-compat`][rpc-compat].
80107
Please see the documentation in the aforementioned repositories for more
81108
information.
82109

@@ -104,16 +131,17 @@ $ npm run graphql:validate
104131

105132
## License
106133

107-
This repository is licensed under [CC0](LICENSE).
134+
This repository is licensed under [CC0][license].
108135

109136

110137
[playground]: https://ethereum.github.io/execution-apis/docs/reference/json-rpc-api
111138
[openrpc]: https://open-rpc.org
112139
[validator]: https://open-rpc.github.io/schema-utils-js/functions/validateOpenRPCDocument.html
113140
[graphql-schema]: http://graphql-schema.ethdevops.io/?url=https://raw.githubusercontent.com/ethereum/execution-apis/main/graphql.json
114141
[eip-1767]: https://eips.ethereum.org/EIPS/eip-1767
115-
[contributors-guide]: docs/reference/contributors-guide.md
142+
[contributors-guide]: ../contributors-guide
116143
[json-schema]: https://json-schema.org
117144
[hive]: https://github.com/ethereum/hive
118145
[rpc-compat]: https://github.com/ethereum/hive/tree/master/simulators/ethereum/rpc-compat
119-
[test-gen]: docs/reference/tests.md
146+
[test-gen]: ../tests
147+
[license]: https://github.com/ethereum/execution-apis/blob/main/LICENSE

docs/reference/tests.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ The Execution API has a comprehensive test suite to verify conformance of
44
clients. The tests in this repository are loaded into the [`hive`][hive] test
55
simulator [`rpc-compat`][rpc-compat] and validated against every major client.
66

7-
The test suite is run daily and results are always available [here][hivetests2]
7+
The test suite is run daily and results are always available [here][hivetests]
88
under the tag `rpc-compat`.
99

1010
To learn more about the `rpc-compat` simulator, please see its
@@ -68,6 +68,6 @@ A good final verification of tests is to run them in the hive simulator
6868
simulator can be found with there.
6969

7070
[hive]: https://github.com/ethereum/hive
71-
[hivetests2]: https://hivetests2.ethdevops.io
71+
[hivetests]: https://hive.ethpandaops.io
7272
[rpc-compat]: https://github.com/ethereum/hive/tree/master/simulators/ethereum/rpc-compat
7373
[rpctestgen]: https://github.com/lightclient/rpctestgen

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"graphql:validate": "node scripts/graphql-validate.js",
1717
"serve": "cd build/docs/gatsby && gatsby develop",
1818
"test": "speccheck -v",
19-
"watch": "nodemon --watch src --ext yaml,md,json --exec \"npm run build && cp ./openrpc.json build/docs/gatsby/src/openrpc.json && npm run serve\""
19+
"watch": "nodemon --watch src,docs --ext yaml,md,json --exec \"npm run build && cp ./openrpc.json build/docs/gatsby/src/openrpc.json && npm run serve\""
2020
},
2121
"repository": {
2222
"type": "git",

0 commit comments

Comments
 (0)