httpr 0.2.3.dev163__tar.gz → 0.2.5__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/workflows/CI.yml +17 -39
  2. {httpr-0.2.3.dev163 → httpr-0.2.5}/Cargo.lock +1 -1
  3. {httpr-0.2.3.dev163 → httpr-0.2.5}/Cargo.toml +1 -1
  4. {httpr-0.2.3.dev163 → httpr-0.2.5}/PKG-INFO +1 -1
  5. {httpr-0.2.3.dev163 → httpr-0.2.5}/README.md +13 -13
  6. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/index.md +2 -2
  7. {httpr-0.2.3.dev163 → httpr-0.2.5}/pyproject.toml +1 -1
  8. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/actions/set-version/action.yml +0 -0
  9. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/copilot-instructions.md +0 -0
  10. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/workflows/CI.yml.backup +0 -0
  11. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/workflows/copilot-setup-steps.yml +0 -0
  12. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/workflows/mkdocs.yml +0 -0
  13. {httpr-0.2.3.dev163 → httpr-0.2.5}/.github/workflows/set_version.py +0 -0
  14. {httpr-0.2.3.dev163 → httpr-0.2.5}/.gitignore +0 -0
  15. {httpr-0.2.3.dev163 → httpr-0.2.5}/.pre-commit-config.yaml +0 -0
  16. {httpr-0.2.3.dev163 → httpr-0.2.5}/CLAUDE.md +0 -0
  17. {httpr-0.2.3.dev163 → httpr-0.2.5}/LICENSE +0 -0
  18. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark/README.md +0 -0
  19. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark/benchmark.py +0 -0
  20. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark/benchmark_cbor.py +0 -0
  21. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark/generate_image.py +0 -0
  22. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark/server.py +0 -0
  23. {httpr-0.2.3.dev163 → httpr-0.2.5}/benchmark.jpg +0 -0
  24. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/advanced/cookies.md +0 -0
  25. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/advanced/index.md +0 -0
  26. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/advanced/proxy.md +0 -0
  27. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/advanced/ssl-tls.md +0 -0
  28. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/api/async-client.md +0 -0
  29. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/api/client.md +0 -0
  30. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/api/functions.md +0 -0
  31. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/api/index.md +0 -0
  32. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/api/response.md +0 -0
  33. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/quickstart.md +0 -0
  34. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/tutorial/async.md +0 -0
  35. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/tutorial/authentication.md +0 -0
  36. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/tutorial/index.md +0 -0
  37. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/tutorial/making-requests.md +0 -0
  38. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/tutorial/response-handling.md +0 -0
  39. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/writings/index.md +0 -0
  40. {httpr-0.2.3.dev163 → httpr-0.2.5}/docs/writings/posts/2025-02-24-python-http-clients-suck.md +0 -0
  41. {httpr-0.2.3.dev163 → httpr-0.2.5}/httpr/__init__.py +0 -0
  42. {httpr-0.2.3.dev163 → httpr-0.2.5}/httpr/httpr.pyi +0 -0
  43. {httpr-0.2.3.dev163 → httpr-0.2.5}/httpr/py.typed +0 -0
  44. {httpr-0.2.3.dev163 → httpr-0.2.5}/httpr.code-workspace +0 -0
  45. {httpr-0.2.3.dev163 → httpr-0.2.5}/mkdocs.yml +0 -0
  46. {httpr-0.2.3.dev163 → httpr-0.2.5}/src/exceptions.rs +0 -0
  47. {httpr-0.2.3.dev163 → httpr-0.2.5}/src/lib.rs +0 -0
  48. {httpr-0.2.3.dev163 → httpr-0.2.5}/src/response.rs +0 -0
  49. {httpr-0.2.3.dev163 → httpr-0.2.5}/src/traits.rs +0 -0
  50. {httpr-0.2.3.dev163 → httpr-0.2.5}/src/utils.rs +0 -0
  51. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/cbor_test_server.py +0 -0
  52. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/conftest.py +0 -0
  53. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/httpx_conns.py +0 -0
  54. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_asyncclient.py +0 -0
  55. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_cbor.py +0 -0
  56. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_client.py +0 -0
  57. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_defs.py +0 -0
  58. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_docs.py +0 -0
  59. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_exceptions.py +0 -0
  60. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_ssl.py +0 -0
  61. {httpr-0.2.3.dev163 → httpr-0.2.5}/tests/test_streaming.py +0 -0
  62. {httpr-0.2.3.dev163 → httpr-0.2.5}/uv.lock +0 -0
@@ -7,9 +7,6 @@ on:
7
7
  tags:
8
8
  - "*"
9
9
  pull_request:
10
- schedule:
11
- # Run weekly on Sundays at midnight UTC
12
- - cron: "0 0 * * 0"
13
10
  workflow_dispatch:
14
11
 
15
12
  permissions:
@@ -39,10 +36,10 @@ jobs:
39
36
  - name: Rust clippy
40
37
  run: cargo clippy -- -D warnings
41
38
 
42
- # Fast test job - runs on PRs and main branch pushes with Python version matrix
39
+ # Fast test job - runs on PRs, main branch pushes, and tag pushes with Python version matrix
43
40
  test:
44
41
  runs-on: ubuntu-22.04
45
- if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
42
+ if: github.event_name == 'pull_request' || (github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')))
46
43
  strategy:
47
44
  matrix:
48
45
  python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
@@ -80,13 +77,11 @@ jobs:
80
77
  uv sync --extra docs
81
78
  uv run mkdocs build --strict
82
79
 
83
- # Build jobs - run on tags, main branch pushes, weekly schedule, or manual dispatch
80
+ # Build jobs - run only on tags or manual dispatch
84
81
  linux:
85
82
  runs-on: ${{ matrix.platform.runner }}
86
- # Wait for test job if it runs, but don't fail if it was skipped (schedule/tag/dispatch)
87
83
  needs: [test]
88
- # Always run unless test job explicitly failed
89
- if: ${{ always() && github.event_name != 'pull_request' && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
84
+ if: ${{ always() && (startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch') && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
90
85
  strategy:
91
86
  matrix:
92
87
  platform:
@@ -140,27 +135,13 @@ jobs:
140
135
  set -e
141
136
  uv sync --extra dev --find-links dist --reinstall
142
137
  uv run pytest
143
- - name: pytest
144
- if: ${{ matrix.platform.target == 'armv7' }}
145
- uses: uraimo/run-on-arch-action@v2
146
- with:
147
- arch: ${{ matrix.platform.target }}
148
- distro: ubuntu22.04
149
- githubToken: ${{ github.token }}
150
- install: |
151
- apt-get update
152
- apt-get install -y --no-install-recommends python3 python3-pip python3-dev build-essential libffi-dev libssl-dev pkg-config curl
153
- curl -LsSf https://astral.sh/uv/install.sh | sh
154
- run: |
155
- set -e
156
- export PATH="$HOME/.local/bin:$PATH"
157
- uv sync --extra dev --find-links dist --reinstall
158
- uv run pytest
138
+ # Skip pytest on armv7 - QEMU emulation is 20x+ slower than native.
139
+ # Tests already run on x86_64 and aarch64 which provides sufficient coverage.
159
140
 
160
141
  musllinux:
161
142
  runs-on: ${{ matrix.platform.runner }}
162
143
  needs: [test]
163
- if: ${{ always() && github.event_name != 'pull_request' && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
144
+ if: ${{ always() && (startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch') && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
164
145
  strategy:
165
146
  matrix:
166
147
  platform:
@@ -218,7 +199,7 @@ jobs:
218
199
  windows:
219
200
  runs-on: ${{ matrix.platform.runner }}
220
201
  needs: [test]
221
- if: ${{ always() && github.event_name != 'pull_request' && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
202
+ if: ${{ always() && (startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch') && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
222
203
  strategy:
223
204
  matrix:
224
205
  platform:
@@ -269,7 +250,7 @@ jobs:
269
250
  macos:
270
251
  runs-on: ${{ matrix.platform.runner }}
271
252
  needs: [test]
272
- if: ${{ always() && github.event_name != 'pull_request' && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
253
+ if: ${{ always() && (startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch') && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
273
254
  strategy:
274
255
  matrix:
275
256
  platform:
@@ -315,7 +296,7 @@ jobs:
315
296
  sdist:
316
297
  runs-on: ubuntu-latest
317
298
  needs: [test]
318
- if: ${{ always() && github.event_name != 'pull_request' && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
299
+ if: ${{ always() && (startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch') && (needs.test.result == 'success' || needs.test.result == 'skipped') }}
319
300
  steps:
320
301
  - uses: actions/checkout@v4
321
302
  - uses: astral-sh/setup-uv@v7
@@ -341,8 +322,8 @@ jobs:
341
322
  name: Release
342
323
  environment: pypi
343
324
  runs-on: ubuntu-latest
344
- # Release on tag pushes, main branch pushes, or manual dispatch
345
- if: ${{ startsWith(github.ref, 'refs/tags/') || (github.event_name == 'push' && github.ref == 'refs/heads/main') || github.event_name == 'workflow_dispatch' }}
325
+ # Release only on tag pushes or manual dispatch
326
+ if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
346
327
  needs: [linux, musllinux, windows, macos, sdist]
347
328
  permissions:
348
329
  # Use to sign the release artifacts
@@ -358,8 +339,8 @@ jobs:
358
339
  with:
359
340
  subject-path: "wheels-*/*"
360
341
  - name: Publish to PyPI
361
- # Publish on tag pushes (stable releases), main branch pushes (dev releases), and manual dispatch
362
- if: ${{ startsWith(github.ref, 'refs/tags/') || (github.event_name == 'push' && github.ref == 'refs/heads/main') || github.event_name == 'workflow_dispatch' }}
342
+ # Publish on tag pushes or manual dispatch
343
+ if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
363
344
  uses: PyO3/maturin-action@v1
364
345
  env:
365
346
  MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
@@ -372,6 +353,7 @@ jobs:
372
353
  contents: write
373
354
  runs-on: ubuntu-latest
374
355
  needs: [linux]
356
+ if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
375
357
  steps:
376
358
  - uses: actions/checkout@v4
377
359
  with:
@@ -393,18 +375,14 @@ jobs:
393
375
  - name: Run benchmark
394
376
  run: uv run python benchmark/benchmark.py
395
377
  - name: Generate and commit benchmark image
396
- if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'schedule'
378
+ if: startsWith(github.ref, 'refs/tags/')
397
379
  run: |
398
380
  uv run python benchmark/generate_image.py
399
381
  git config --global user.name 'github-actions[bot]'
400
382
  git config --global user.email '41898282+github-actions[bot]@users.noreply.github.com'
401
383
  git add *.jpg
402
384
  if ! git diff --quiet --cached; then
403
- if [ "${{ github.event_name }}" = "schedule" ]; then
404
- git commit -m "Update benchmark image (weekly)"
405
- else
406
- git commit -m "Update benchmark image for ${{ github.ref_name }}"
407
- fi
385
+ git commit -m "Update benchmark image for ${{ github.ref_name }}"
408
386
  # Push to main branch explicitly (handles detached HEAD state from tag checkout)
409
387
  git push origin HEAD:main
410
388
  else
@@ -470,7 +470,7 @@ checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"
470
470
 
471
471
  [[package]]
472
472
  name = "httpr"
473
- version = "0.2.3"
473
+ version = "0.2.5"
474
474
  dependencies = [
475
475
  "anyhow",
476
476
  "bytes",
@@ -1,6 +1,6 @@
1
1
  [package]
2
2
  name = "httpr"
3
- version = "0.2.3"
3
+ version = "0.2.5"
4
4
  edition = "2021"
5
5
  description = "Fast HTTP client for python"
6
6
  authors = ["thomasht86"]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: httpr
3
- Version: 0.2.3.dev163
3
+ Version: 0.2.5
4
4
  Classifier: Programming Language :: Rust
5
5
  Classifier: Programming Language :: Python :: 3
6
6
  Classifier: Programming Language :: Python :: 3 :: Only
@@ -339,19 +339,19 @@ Provides precompiled wheels for the following platforms:
339
339
 
340
340
  ## CI
341
341
 
342
- | Job | PRs | Push to main | Tags (Release) | Weekly (Sunday) | Manual |
343
- |-----|:---:|:------------:|:--------------:|:---------------:|:------:|
344
- | `test` (Python 3.10-3.14) | ✓ | | | | |
345
- | `docs` (build) | ✓ | | | | |
346
- | `docs` (deploy) | | ✓ | | | |
347
- | `linux`, `musllinux`, `windows`, `macos`, `sdist` | | | ✓ | ✓ | ✓ |
348
- | `release` (PyPI publish) | | ✓ (dev) | ✓ (stable) | | ✓ |
349
- | `benchmark` | | | ✓ | ✓ | ✓ |
350
-
351
- - **PRs**: Run tests across Python 3.10-3.14 matrix and verify docs build
352
- - **Push to main**: Run tests, build wheels, publish dev release to PyPI (e.g., `0.1.0.dev42`)
353
- - **Tags**: Build wheels, publish stable release to PyPI (e.g., `0.2.0`)
354
- - **Weekly/Manual**: Full multi-platform wheel builds with benchmarks
342
+ | Job | PRs | Push to main | Tags (Release) | Manual |
343
+ |-----|:---:|:------------:|:--------------:|:------:|
344
+ | `lint` | ✓ | | | |
345
+ | `test` (Python 3.10-3.14) | ✓ | | | |
346
+ | `docs` (build) | ✓ | | | |
347
+ | `linux`, `musllinux`, `windows`, `macos`, `sdist` | | | ✓ | ✓ |
348
+ | `release` (PyPI publish) | | | ✓ | ✓ |
349
+ | `benchmark` | | | ✓ | ✓ |
350
+
351
+ - **PRs**: Run lint, tests across Python 3.10-3.14 matrix, and verify docs build
352
+ - **Push to main**: Run tests only
353
+ - **Tags**: Run tests, build wheels, publish stable release to PyPI, run benchmarks
354
+ - **Manual**: Full multi-platform wheel builds with release and benchmarks
355
355
 
356
356
  ## Acknowledgements
357
357
 
@@ -149,8 +149,8 @@ print(response.cookies) # Response cookies
149
149
 
150
150
  This documentation is available in LLM-optimized formats:
151
151
 
152
- - **[llms.txt](llms.txt)** - Documentation index for LLMs
153
- - **[llms-full.txt](llms-full.txt)** - Complete documentation in a single file
152
+ - **[llms.txt](https://thomasht86.github.io/httpr/llms.txt)** - Documentation index for LLMs
153
+ - **[llms-full.txt](https://thomasht86.github.io/httpr/llms-full.txt)** - Complete documentation in a single file
154
154
 
155
155
  ---
156
156
 
@@ -8,7 +8,7 @@ description = "Fast HTTP client for Python"
8
8
  requires-python = ">=3.10"
9
9
  keywords = [ "python", "request",]
10
10
  classifiers = [ "Programming Language :: Rust", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", "Topic :: Internet :: WWW/HTTP", "Topic :: Software Development :: Libraries :: Python Modules",]
11
- version = "0.2.3.dev163"
11
+ version = "0.2.5"
12
12
  dependencies = []
13
13
  [[project.authors]]
14
14
  name = "thomasht86"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes