Skip to content

Commit 0fe7551

Browse files
authored
Drop Python 2 support.
2 parents f8d3f2f + 6506490 commit 0fe7551

File tree

76 files changed

+3370
-23236
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+3370
-23236
lines changed

.github/workflows/build.yml

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,31 @@ name: "build"
22
on:
33
push:
44
pull_request:
5+
workflow_dispatch:
56
jobs:
67
build:
78
runs-on: ubuntu-latest
89
strategy:
910
matrix:
10-
python: [python27, python39, python310, python311]
11-
docutils: [docutils016, docutils017, docutils018, docutils019, docutils020]
11+
python: [python310, python311, python312, python313, python314]
12+
sphinx: [8.2.3, 8.1.3, 8.0.2, 7.4.7]
1213
exclude:
13-
- python: python27
14-
docutils: docutils018
15-
- python: python27
16-
docutils: docutils019
17-
- python: python27
18-
docutils: docutils020
19-
env:
20-
COVERALLS_REPO_TOKEN: ${{ secrets.github_token }}
21-
COVERALLS_SERVICE_NAME: github
14+
- python: python310
15+
sphinx: 8.2.3
2216
steps:
23-
- uses: actions/checkout@v4.1.1
24-
- uses: cachix/install-nix-action@v25
17+
- uses: actions/checkout@v4
18+
- uses: cachix/install-nix-action@v30
2519
with:
2620
nix_path: nixpkgs=channel:nixos-unstable
27-
- uses: cachix/cachix-action@v14
21+
- uses: cachix/cachix-action@v15
2822
with:
2923
name: datakurre
30-
# authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'j
31-
- run: make nix-show nix-test nix-coverage nix-coveralls nix-docs PYTHON=${{ matrix.python }} FEATURE=${{ matrix.docutils }}
24+
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
25+
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
26+
- run: nix profile install nixpkgs#devenv
27+
- run: LC_ALL=en_US.UTF-8 make devenv-test devenv-coverage devenv-docs PYTHON=${{ matrix.python }} SPHINX=${{ matrix.sphinx }}
28+
- uses: coverallsapp/github-action@v2
29+
with:
30+
debug: true
31+
format: cobertura
32+
github-token: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
*.egg-info
22
*.mo
33
*.pyc
4-
.installed.cfg
54
.cache
65
.coverage
6+
.devenv*
77
.eggs/
88
.idea/
9+
.installed.cfg
10+
.pre-commit-config.yaml
911
.pytest_cache/
1012
bin/
13+
devenv.local.nix
1114
docs/_build/
1215
html/
16+
htmlcov/
1317
result
18+
coverage.xml

.treefmt.toml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
on-unmatched = "debug"
2+
3+
[formatter.nix]
4+
command = "nixfmt"
5+
includes = ["*.nix"]
6+
7+
[formatter.python]
8+
command = "black"
9+
includes = ["*.py"]
10+
11+
[formatter.isort]
12+
command = "isort"
13+
includes = ["*.py"]

CHANGELOG.md

Lines changed: 202 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,202 @@
1+
# Changelog
2+
3+
## 1.4 (unreleased)
4+
5+
- Nothing changed yet.
6+
7+
## 1.3 (2024-08-18)
8+
9+
- Add new directive `.. http:example-block::` to allow use with Sphinx tab libraries like
10+
[sphinx-inline-tabs](https://sphinx-inline-tabs.readthedocs.io/en/latest/) or
11+
[sphinx-design](https://sphinx-design.readthedocs.io/en/furo-theme/tabs.html).
12+
[AWhetter]
13+
14+
## 1.2 (2024-08-17)
15+
16+
- Add new HTTP example builder `plone-javascript`
17+
[datakurre]
18+
- Fix tabbing to no longer depend on jQuery
19+
[datakurre]
20+
- Fix tabbing to support arrow key navigation
21+
[datakurre]
22+
- Fix tab key to stop at tab list only once
23+
[datakurre]
24+
- Fix requests builder to flatten simple values in form data
25+
[datakurre]
26+
- Fix requests builder to pass form data as dictionary
27+
[datakurre]
28+
- Change JavaScript-based tabbing to no longer require JQuery
29+
[datakurre]
30+
31+
## 1.1 (2021-12-25)
32+
33+
- Add support for docutils 0.17.x
34+
[kvondersaar, datakurre]
35+
- Add support for Python 3.8
36+
[datakurre]
37+
- Fix example tabs accessibility
38+
[datakurre]
39+
40+
## 1.0 (2021-09-10)
41+
42+
- The curl command builder will now always specify a method
43+
[LefterisJP]
44+
45+
## 0.11.0 (2021-05-14)
46+
47+
- Change to quote examples with `"` rather than `'`
48+
[datakurre]
49+
- Fix Sphinx deprecation warnings and support Sphinx 4.x
50+
[kkrypt0nn, AWhetter]
51+
- Fix to use `ast.unparse` instead of `astunparse` on Python >= 3.9
52+
[datakurre]
53+
54+
## 0.10.3 (2019-05-01)
55+
56+
- Re-release 0.10.2 with wheel
57+
[datakurre]
58+
59+
## 0.10.2 (2019-05-01)
60+
61+
- Add support for inline response examples without HTTP version
62+
(e.g., `HTTP 200 OK`)
63+
[datakurre]
64+
- Fix regression where support for reading request examples from
65+
external files was broken since 0.10.0
66+
[datakurre]
67+
68+
## 0.10.1 (2019-03-19)
69+
70+
- Fix issue where it was not possible to request examples with
71+
float values in payload JSON [fixes #42]
72+
[datakurre]
73+
74+
## 0.10.0 (2018-10-09)
75+
76+
- Add support for URL query parameters, using the `query` field.
77+
Given a line `:query param_name: param_value` in an HTTP example
78+
directive, the key-value pair `param_name`, `param_value` will be
79+
added to the request URL (and excluded from further processing).
80+
[ludaavics]
81+
82+
Example:
83+
84+
```http
85+
GET /items HTTP/1.1
86+
Host: localhost
87+
Accept: application/json
88+
Authorization: Basic dXNlcjpwYXNzd29yZA==
89+
90+
:query from: 20170101
91+
:query to: 20171231
92+
:query user_id: 12
93+
:query limit: 20
94+
:query sort: date(asc)
95+
```
96+
97+
## 0.9.1 (2018-10-06)
98+
99+
- Fix packaging to include `setup.cfg` in sdist
100+
[datakurre]
101+
- Add the Guillotina docs (which now uses httpexample)
102+
[cdevienne]
103+
104+
## 0.9.0 (2018-07-22)
105+
106+
- Add support for inlining responses
107+
[cdevienne]
108+
109+
## 0.8.1 (2018-06-27)
110+
111+
- Fix error when parsing top-level JSON lists
112+
[AWhetter]
113+
114+
## 0.8.0 (2017-11-18)
115+
116+
- Fix to not strip out `Accept`/`Content-Type` headers in builders
117+
[dokai]
118+
- Improve logic to detect a JSON content type
119+
[dokai]
120+
- Use redirected input to pass request payload to `httpie`
121+
[dokai]
122+
- Fix quoting of non-trivial HTTP headers in builders
123+
[dokai]
124+
- Change to use declarative packaging (`setup.cfg` instead of `setup.py`)
125+
[datakurre]
126+
127+
## 0.7.0 (2017-10-21)
128+
129+
- Allow the URL scheme (`http` or `https`) to be configured
130+
[dokai]
131+
- Quote the URL if it contains `&` characters in `curl`/`httpie`/`wget` examples
132+
[dokai]
133+
134+
## 0.6.1 (2017-05-11)
135+
136+
- Release as universal wheel
137+
[datakurre]
138+
139+
## 0.6.0 (2017-05-11)
140+
141+
- Support non-JSON requests
142+
[jaroel]
143+
- Support `application/json; charset=utf-8`
144+
[skyzyx]
145+
146+
## 0.5.2 (2017-03-09)
147+
148+
- Fix packaging to include the files in `static` [#3]
149+
[csenger]
150+
151+
## 0.5.1 (2017-03-05)
152+
153+
- Update README and documentation
154+
[datakurre]
155+
156+
## 0.5.0 (2017-03-05)
157+
158+
- Change development status to beta
159+
[datakurre]
160+
161+
## 0.4.2 (2017-03-05)
162+
163+
- Fix issue where `wget` basic auth required a challenge from the backend, which is not
164+
always available
165+
[datakurre]
166+
167+
## 0.4.1 (2017-03-05)
168+
169+
- Fix issue where generated `httpie` commands did not always set `Accept` and
170+
`Content-Type` headers
171+
[datakurre]
172+
173+
## 0.4.0 (2017-03-05)
174+
175+
- Add support for `wget`
176+
[datakurre]
177+
178+
## 0.3.0 (2017-03-05)
179+
180+
- Add generic `Authorization` header support
181+
[datakurre]
182+
183+
## 0.2.1 (2017-03-05)
184+
185+
- Fix issue where `Authorization` header was always required
186+
[datakurre]
187+
- Fix to raise proper exception when parsing bad requests
188+
[datakurre]
189+
- Fix issue where `httpie` builder did not quote values with spaces
190+
[datakurre]
191+
- Fix link to `python-requests` documentation
192+
[datakurre]
193+
194+
## 0.2.0 (2017-03-05)
195+
196+
- Add support for `GET` requests
197+
[datakurre]
198+
199+
## 0.1.0 (2017-03-05)
200+
201+
- First release
202+
[datakurre]

0 commit comments

Comments
 (0)