Skip to content

Commit da708bf

Browse files
Doc cleanup (#75)
* Clean up documentation and readmes * Add tenet of JMESPath, guiding the distinction between syntax and functions
1 parent e3add61 commit da708bf

File tree

3 files changed

+28
-41
lines changed

3 files changed

+28
-41
lines changed

.github/pull_request_template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Please keep PR discussion strictly about the content of the PR and any comments
2121
| **[SemVer](https://semver.org/spec/v2.0.0.html#summary)** | MAJOR\|MINOR\|PATCH
2222
| **[Discussion #](https://github.com/jmespath-community/jmespath.jep/discussions)** | [##](https://github.com/jmespath-community/jmespath.jep/discussions/##)
2323

24-
*Please discuss the merit of the JEP in the linked discussion. PR discussion should be limited to proofing the content of the PR and the PR proposal inital comment*
24+
*Please discuss the merit of the JEP in the linked discussion. PR discussion should be limited to proofing the content of the PR and the PR proposal initial comment*
2525

2626
## Abstract
2727

README.md

Lines changed: 20 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
# JMESPath Specification
22

33
Any changes to the JMESPath specification
4-
(https://jmespath.site/specification.html) must have a JEP (JMESPath Enhancement
5-
Proposal) which is tracked in this repo. There are implementations of JMESPath
6-
in over 9 different languages, and we want to make sure that any modifications
7-
to the spec make sense for all JMESPath libraries. A JEP helps to work through
8-
the design process for new additions and ensures that the JMESPath community
9-
has a chance to give feedback before it's officially part of the specification.
4+
(https://jmespath.site/specification.html) must have a JEP (JMESPath Enhancement Proposal) which is tracked in this repo. There are implementations of
5+
JMESPath in over 9 different languages, and we want to make sure that any modifications to the spec make sense for all JMESPath libraries. A JEP helps
6+
to work through the design process for new additions and ensures that the JMESPath community has a chance to give feedback before it's officially part
7+
of the specification.
108

119
## Things that need a JEP
1210

13-
Any functionaly change that would require an update to the specification
11+
Any functionality change that would require an update to the specification
1412
(http://jmespath.site/specification.html) requires a JEP.
1513

1614
This includes, but is not limited to:
@@ -21,44 +19,34 @@ This includes, but is not limited to:
2119

2220
## Things that do not need a JEP
2321

24-
Anything that is specific to a JMESPath library does not need a JEP. You
25-
should defer to the specific library's contributing guide. This can include
26-
additional language specific APIs, extension points (e.g. adding custom
27-
functions), configuration options, etc.
22+
Anything that is specific to a JMESPath library does not need a JEP. You should defer to the specific library's contributing guide. This can include
23+
additional language specific APIs, extension points (e.g. adding custom functions), configuration options, etc.
2824

2925
## Guidelines for proposing new features
3026

31-
First, make sure that the feature has not been previously proposed. If it has,
32-
make sure to reference prior proposals and explain why this new proposal should
33-
be considered despite similar proposals not being accepted.
27+
First, make sure that the feature has not been previously proposed. If it has, make sure to reference prior proposals and explain why this new
28+
proposal should be considered despite similar proposals not being accepted.
3429

35-
Writing a JEP can be a lot of work, so it can help to get initial guidance
36-
before getting too far. You can chat on the JMESPath gitter channel
30+
Writing a JEP can be a lot of work, so it can help to get initial guidance before getting too far. You can chat on the JMESPath gitter channel
3731
(https://gitter.im/jmespath/chat) to get an initial pulse of a new feature.
3832

39-
You can also create a discussion in this repo with a rough proposal
40-
to get initial high level feedback. If you'd like to move
41-
forward with the proposal you will still need to write a JEP
42-
and send a pull request (PR).
33+
Then open a [discussion](https://github.com/jmespath-community/jmespath.spec/discussions) to discuss the feature, its merit, and any possible
34+
alternatives. Once the discussion has reached a mature level of feedback it will be assigned a JEP#. At this point it is safe to begin composing a
35+
JEP, along with all the required changes and documentation.
4336

4437
### Tenets of JMESPath
4538

46-
When proposing new features, keep these tenets in mind. Adhering to
47-
these tenets gives your proposal a higher likelihood of being accepted:
39+
When proposing new features, keep these tenets in mind. Adhering to these tenets gives your proposal a higher likelihood of being accepted:
4840

49-
* JMESPath is not specific to a particular programming language. Avoid
50-
constructs that are difficult to implement in another language.
41+
* JMESPath is not specific to a particular programming language. Avoid constructs that are difficult to implement in another language.
5142
* JMESPath strives to have one way to do something.
5243
* Features are driven from real world use cases.
44+
* Syntax is generally used to express data structure manipulation while functions are used to express datum manipulation
5345

5446
# JMESPath Compliance Tests
5547

56-
This repo contains a suite of JMESPath compliance tests. JMESPath's implementations can use these tests in order to verify their
57-
implementation adheres to the JMESPath spec.
58-
59-
## Test Organization
60-
61-
`grammar/*.yml` contains tests for general grammar functionality. These documents must validate against the `grammar_schema.yml`.
62-
63-
`functions/*.yml` contains a description of each function accompanied by a suite of tests/examples. These documents must validate against the `function_schema.yml`.
48+
This repo contains a suite of JMESPath compliance tests. JMESPath's implementations can use these tests in order to verify their implementation
49+
adheres to the JMESPath spec. Every implementation of JMESPath should provide a basic command line executable that allows execution of compliance
50+
tests. This eases third-party validation of the implementation, without needing any specific testing suite.
6451

52+
See [bin/README.md](bin/README.md) for more information on running compliance tests.

bin/README.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,25 @@
11
# JMESPath Compliance Tests
22

3-
This repo contains a suite of JMESPath compliance tests. JMESPath's implementations can use these tests in order to verify their
4-
implementation adheres to the JMESPath spec.
3+
This repo contains a suite of JMESPath compliance tests. JMESPath's implementations can use these tests in order to verify their implementation
4+
adheres to the JMESPath spec.
55

66
## Test Organization
77

88
`grammar/*.yml` contains tests for general grammar functionality. These documents must validate against the `grammar_schema.yml`.
99

10-
`functions/*.yml` contains a description of each function accompanied by a suite of tests/examples. These documents must validate against the `function_schema.yml`.
10+
`functions/*.yml` contains a description of each function accompanied by a suite of tests/examples. These documents must validate against
11+
the `function_schema.yml`.
1112

1213
## Running Tests
1314

14-
This repository include a Python `jp-compliance` executable test runner.
15+
This repository includes a Python `jp-compliance` executable test runner.
1516

1617
```
1718
jp-compliance <executable> <test yaml> [<test name>..]
1819
```
1920

20-
This will run the JMESPath compliance tests against a JMESPath executable.
21-
The executable must accept the query as the only argument, and the input data on stdin.
22-
The result must be printed to stdout as JSON.
23-
Errors must be printed to stderr and match expected values.
21+
This will run the JMESPath compliance tests against a JMESPath executable. The executable must accept the query as the only argument, and the input
22+
data on stdin. The result must be printed to stdout as JSON. Errors must be printed to stderr and match expected values.
2423

2524
If your executable requires additional arguments, wrap it in an executable script.
2625

0 commit comments

Comments
 (0)