Skip to content

Commit 8ae6e17

Browse files
OmarAlJarrahclaude
andcommitted
chore: modernise packaging metadata and add contributor scaffolding
Migrate every distribution's license metadata to the PEP 639 SPDX form (license = "MIT" plus license-files = ["LICENSE.md"]) and bump the build requirement to hatchling>=1.27, the first release that supports it. Drop the now-redundant "License :: OSI Approved :: MIT License" classifier, which recent build and publish tooling rejects when a license expression is also present. While here, enrich the metadata: add the "Topic :: Internet :: WWW/HTTP" and "Typing :: Typed" classifiers, Documentation and Issues project URLs, the "pipeline" keyword, and a sharper core summary. Add the standard GitHub community-health files so external contributors have a clear on-ramp: bug-report and feature-request issue forms with a security contact link, a pull-request template wired to the project's quality gates, a Dependabot config covering GitHub Actions and uv dependencies, plus CONTRIBUTING.md and SECURITY.md. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent f172ff1 commit 8ae6e17

12 files changed

Lines changed: 249 additions & 17 deletions

File tree

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Bug report
2+
description: Something behaves incorrectly
3+
labels: ["bug"]
4+
body:
5+
- type: dropdown
6+
id: package
7+
attributes:
8+
label: Package
9+
description: Which distribution is affected?
10+
options:
11+
- dexpace-sdk-core
12+
- dexpace-sdk-http-stdlib
13+
- dexpace-sdk-http-httpx
14+
- dexpace-sdk-http-aiohttp
15+
- dexpace-sdk-http-requests
16+
- not sure
17+
validations:
18+
required: true
19+
- type: textarea
20+
id: description
21+
attributes:
22+
label: Description
23+
description: What happened, and what did you expect instead?
24+
validations:
25+
required: true
26+
- type: textarea
27+
id: reproduction
28+
attributes:
29+
label: Minimal reproduction
30+
description: The smallest code snippet that triggers the bug.
31+
render: python
32+
validations:
33+
required: true
34+
- type: textarea
35+
id: traceback
36+
attributes:
37+
label: Traceback / output
38+
render: text
39+
- type: input
40+
id: python-version
41+
attributes:
42+
label: Python version
43+
placeholder: "3.12.4"
44+
validations:
45+
required: true
46+
- type: input
47+
id: sdk-version
48+
attributes:
49+
label: SDK version(s)
50+
placeholder: "dexpace-sdk-core 0.1.0"
51+
validations:
52+
required: true

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: true
2+
contact_links:
3+
- name: Security vulnerability
4+
url: https://github.com/dexpace/python-sdk/security/advisories/new
5+
about: Please report security issues privately, not as public issues.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Feature request
2+
description: Propose a new capability or improvement
3+
labels: ["enhancement"]
4+
body:
5+
- type: textarea
6+
id: problem
7+
attributes:
8+
label: Problem
9+
description: What are you trying to do that the SDK doesn't support today?
10+
validations:
11+
required: true
12+
- type: textarea
13+
id: proposal
14+
attributes:
15+
label: Proposed solution
16+
description: >-
17+
What would the API look like? Note that core stays free of new
18+
runtime dependencies — third-party needs belong behind the
19+
`HttpClient`/`Serde` seams or in a transport package.
20+
validations:
21+
required: true
22+
- type: textarea
23+
id: alternatives
24+
attributes:
25+
label: Alternatives considered

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
## What
2+
3+
<!-- What does this PR change, and why? Link related issues with "Fixes #123". -->
4+
5+
## Checklist
6+
7+
- [ ] `uv run pytest -q` passes
8+
- [ ] `uv run mypy --strict` passes
9+
- [ ] `uv run ruff check` and `uv run ruff format --check` pass
10+
- [ ] New/changed public symbols have Google-style docstrings and appear in `__all__`
11+
- [ ] New `.py` files carry the two-line MIT licence header
12+
- [ ] Commit messages use the `feat:` / `fix:` / `chore:` / `docs:` / `ci:` prefixes

.github/dependabot.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: github-actions
4+
directory: /
5+
schedule:
6+
interval: weekly
7+
groups:
8+
actions:
9+
patterns: ["*"]
10+
11+
- package-ecosystem: uv
12+
directory: /
13+
schedule:
14+
interval: weekly
15+
groups:
16+
python-deps:
17+
patterns: ["*"]

CONTRIBUTING.md

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Contributing
2+
3+
Thanks for your interest in the Dexpace Python SDK. External pull requests
4+
are welcome — this page covers everything you need to get a change merged.
5+
6+
## Setup
7+
8+
The repository is a [`uv`](https://docs.astral.sh/uv/)-managed workspace of
9+
five packages. One sync provisions everything in editable mode along with
10+
the dev toolchain:
11+
12+
```bash
13+
git clone https://github.com/dexpace/python-sdk.git
14+
cd python-sdk
15+
uv sync
16+
```
17+
18+
## Quality gates
19+
20+
Every pull request must pass the same four gates CI runs (on Python 3.12,
21+
3.13, and 3.14):
22+
23+
```bash
24+
uv run pytest -q # full test suite
25+
uv run mypy --strict # type-check
26+
uv run ruff check # lint
27+
uv run ruff format --check # formatting
28+
```
29+
30+
Run them locally before opening a PR.
31+
32+
## Conventions
33+
34+
The full convention set lives in [`CLAUDE.md`](CLAUDE.md). The essentials:
35+
36+
- **Python 3.12+** with modern syntax: `X | None`, built-in generics,
37+
PEP 695 type parameters, `from __future__ import annotations` everywhere.
38+
- **Immutable models**: `@dataclass(frozen=True, slots=True)`; mutate via
39+
`dataclasses.replace` or `with_*` helpers — no builders.
40+
- **`Protocol` for SPIs, `ABC` for shared behaviour.**
41+
- **No new runtime dependencies.** `core` ships against the standard
42+
library plus `furl` only; new third-party needs belong behind the
43+
`HttpClient` or `Serde` seams, or in a new transport package.
44+
- **Google-style docstrings** on every public symbol; functions capped at
45+
50 lines.
46+
- **MIT licence header** (two lines) at the top of every `.py` file, src
47+
and tests alike.
48+
49+
## Commit messages
50+
51+
Use the prefixes the history already follows:
52+
53+
| Prefix | Use for |
54+
|----------|----------------------------------|
55+
| `feat:` | new features |
56+
| `fix:` | bug fixes |
57+
| `chore:` | refactors and cleanup |
58+
| `docs:` | documentation-only changes |
59+
| `ci:` | CI configuration |
60+
61+
## Reporting issues
62+
63+
Use the [issue templates](https://github.com/dexpace/python-sdk/issues/new/choose).
64+
For security vulnerabilities, follow [`SECURITY.md`](SECURITY.md) instead of
65+
opening a public issue.

SECURITY.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Security Policy
2+
3+
## Supported versions
4+
5+
| Version | Supported |
6+
|---------|--------------------|
7+
| 0.1.x | :white_check_mark: |
8+
9+
## Reporting a vulnerability
10+
11+
Please **do not** open a public issue for security vulnerabilities.
12+
13+
Instead, report privately via
14+
[GitHub private vulnerability reporting](https://github.com/dexpace/python-sdk/security/advisories/new)
15+
(Security tab → "Report a vulnerability"). If you cannot use GitHub, email
16+
[o.mazari.om63@gmail.com](mailto:o.mazari.om63@gmail.com) with
17+
`[SECURITY]` in the subject line.
18+
19+
Include what you can of the following:
20+
21+
- The affected package(s) and version(s)
22+
- A description of the vulnerability and its impact
23+
- Steps or a proof of concept to reproduce it
24+
25+
You can expect an acknowledgement within a few days. Please allow time for
26+
a fix to land and be released before disclosing publicly.
27+
28+
## Scope notes
29+
30+
- The SDK is a **toolkit**, not a service: it executes no network I/O of
31+
its own. Transport-level vulnerabilities (TLS, connection handling)
32+
usually belong to the underlying HTTP library (`httpx`, `aiohttp`,
33+
`requests`, or the standard library) — report those upstream.
34+
- In scope here: credential handling (`http.auth`), header/URL redaction
35+
in logging, redirect safety (`Authorization` stripping, userinfo
36+
dropping), body capture, and challenge parsing.

packages/dexpace-sdk-core/pyproject.toml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,36 @@
11
[build-system]
2-
requires = ["hatchling"]
2+
requires = ["hatchling>=1.27"]
33
build-backend = "hatchling.build"
44

55
[project]
66
name = "dexpace-sdk-core"
77
version = "0.1.0"
8-
description = "Zero-dependency Python SDK core for building HTTP client libraries."
8+
description = "Toolkit core for building Python HTTP client libraries: immutable models, staged policy pipelines, auth, and observability."
99
readme = "README.md"
1010
requires-python = ">=3.12"
11-
license = { file = "LICENSE.md" }
11+
license = "MIT"
12+
license-files = ["LICENSE.md"]
1213
authors = [{ name = "Omar Aljarrah", email = "o.mazari.om63@gmail.com" }]
13-
keywords = ["sdk", "http", "client", "toolkit"]
14+
keywords = ["sdk", "http", "client", "toolkit", "pipeline"]
1415
classifiers = [
1516
"Development Status :: 3 - Alpha",
1617
"Intended Audience :: Developers",
17-
"License :: OSI Approved :: MIT License",
1818
"Operating System :: OS Independent",
1919
"Programming Language :: Python :: 3",
2020
"Programming Language :: Python :: 3.12",
2121
"Programming Language :: Python :: 3.13",
2222
"Programming Language :: Python :: 3.14",
23+
"Topic :: Internet :: WWW/HTTP",
2324
"Topic :: Software Development :: Libraries",
25+
"Typing :: Typed",
2426
]
2527
dependencies = ["furl>=2.1.3"]
2628

2729
[project.urls]
2830
Homepage = "https://github.com/dexpace/python-sdk"
31+
Documentation = "https://github.com/dexpace/python-sdk/tree/main/docs"
2932
Repository = "https://github.com/dexpace/python-sdk"
33+
Issues = "https://github.com/dexpace/python-sdk/issues"
3034

3135
[tool.hatch.build.targets.wheel]
3236
packages = ["src/dexpace/sdk/core"]

packages/dexpace-sdk-http-aiohttp/pyproject.toml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["hatchling"]
2+
requires = ["hatchling>=1.27"]
33
build-backend = "hatchling.build"
44

55
[project]
@@ -8,20 +8,22 @@ version = "0.1.0"
88
description = "aiohttp-backed async HTTP transport for dexpace-sdk-core."
99
readme = "README.md"
1010
requires-python = ">=3.12"
11-
license = { file = "LICENSE.md" }
11+
license = "MIT"
12+
license-files = ["LICENSE.md"]
1213
authors = [{ name = "Omar Aljarrah", email = "o.mazari.om63@gmail.com" }]
1314
keywords = ["sdk", "http", "aiohttp", "async"]
1415
classifiers = [
1516
"Development Status :: 3 - Alpha",
1617
"Framework :: AsyncIO",
1718
"Intended Audience :: Developers",
18-
"License :: OSI Approved :: MIT License",
1919
"Operating System :: OS Independent",
2020
"Programming Language :: Python :: 3",
2121
"Programming Language :: Python :: 3.12",
2222
"Programming Language :: Python :: 3.13",
2323
"Programming Language :: Python :: 3.14",
24+
"Topic :: Internet :: WWW/HTTP",
2425
"Topic :: Software Development :: Libraries",
26+
"Typing :: Typed",
2527
]
2628
dependencies = [
2729
"dexpace-sdk-core>=0.1,<0.2",
@@ -30,7 +32,9 @@ dependencies = [
3032

3133
[project.urls]
3234
Homepage = "https://github.com/dexpace/python-sdk"
35+
Documentation = "https://github.com/dexpace/python-sdk/tree/main/docs"
3336
Repository = "https://github.com/dexpace/python-sdk"
37+
Issues = "https://github.com/dexpace/python-sdk/issues"
3438

3539
[tool.hatch.build.targets.wheel]
3640
packages = ["src/dexpace/sdk/http/aiohttp"]

packages/dexpace-sdk-http-httpx/pyproject.toml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["hatchling"]
2+
requires = ["hatchling>=1.27"]
33
build-backend = "hatchling.build"
44

55
[project]
@@ -8,19 +8,21 @@ version = "0.1.0"
88
description = "httpx-backed HTTP transports for dexpace-sdk-core."
99
readme = "README.md"
1010
requires-python = ">=3.12"
11-
license = { file = "LICENSE.md" }
11+
license = "MIT"
12+
license-files = ["LICENSE.md"]
1213
authors = [{ name = "Omar Aljarrah", email = "o.mazari.om63@gmail.com" }]
1314
keywords = ["sdk", "http", "httpx"]
1415
classifiers = [
1516
"Development Status :: 3 - Alpha",
1617
"Intended Audience :: Developers",
17-
"License :: OSI Approved :: MIT License",
1818
"Operating System :: OS Independent",
1919
"Programming Language :: Python :: 3",
2020
"Programming Language :: Python :: 3.12",
2121
"Programming Language :: Python :: 3.13",
2222
"Programming Language :: Python :: 3.14",
23+
"Topic :: Internet :: WWW/HTTP",
2324
"Topic :: Software Development :: Libraries",
25+
"Typing :: Typed",
2426
]
2527
dependencies = [
2628
"dexpace-sdk-core>=0.1,<0.2",
@@ -29,7 +31,9 @@ dependencies = [
2931

3032
[project.urls]
3133
Homepage = "https://github.com/dexpace/python-sdk"
34+
Documentation = "https://github.com/dexpace/python-sdk/tree/main/docs"
3235
Repository = "https://github.com/dexpace/python-sdk"
36+
Issues = "https://github.com/dexpace/python-sdk/issues"
3337

3438
[tool.hatch.build.targets.wheel]
3539
packages = ["src/dexpace/sdk/http/httpx"]

0 commit comments

Comments
 (0)