irongit

Enhanced time synchronization for drf views.

edit readme

huncholanehuncholaneauthored
parent e0ecc66commit 4dbee488a18de994a3029075a7e1bb36c0b1e7f9Browse files

1 file changed, +13 -13

+13-13README.md
@@ -9,7 +9,7 @@ It adds a structured way to compare client and server timestamps, detect when up
99 ## Features
1010
1111 - ✅ `PlusRequest`: subclass of DRF’s `Request` with timestamp parsing & comparison
12-- 🧠 `TimestampOp`: context-aware timestamp diff logic (`client_is_newer`, etc.)
12+- 🧠 `TimestampOp`: context-aware timestamp diff logic (`raise_get`, etc.)
1313 - ⚙️ Configurable via `PlusRequestConf` (env vars or `settings.PLUSREQUEST_CONF`)
1414 - 🧾 Typed request metadata with `Meta`, `PlusMeta`, and `DefaultMeta`
1515 - 🔒 Built-in error handling for missing or invalid timestamps
@@ -47,15 +47,15 @@ def view(request: PlusRequest):
4747
4848 The `TimestampOp` class is accessed via `request.top_builder(...)`. It automatically:
4949
50-* Extracts server timestamps from a model instance
51-* Parses client timestamps from headers or body
52-* Validates datetime format
53-* Raises errors or returns status flags
50+- Extracts server timestamps from a model instance
51+- Parses client timestamps from headers or body
52+- Validates datetime format
53+- Raises errors or returns status flags
5454
5555 ### Supported behaviors
5656
57-* `raise_get`
58-* `raise_update`
57+- `raise_get`
58+- `raise_update`
5959
6060 ---
6161
@@ -89,17 +89,17 @@ def view(request: PlusRequest):
8989
9090 ### Meta Types
9191
92-* `DefaultMeta`: Core Django fields (e.g. `HTTP_HOST`, `REQUEST_METHOD`)
93-* `PlusMeta`: Common API headers (e.g. `HTTP_AUTHORIZATION`, `HTTP_X_APP_VERSION`)
94-* `Meta`: Union of both
92+- `DefaultMeta`: Core Django fields (e.g. `HTTP_HOST`, `REQUEST_METHOD`)
93+- `PlusMeta`: Common API headers (e.g. `HTTP_AUTHORIZATION`, `HTTP_X_APP_VERSION`)
94+- `Meta`: Union of both
9595
9696 ---
9797
9898 ## Exceptions
9999
100-* `InvalidClientDatetimeField`
101-* `InvalidServerDatetimeField`
102-* `NoUpdate`
100+- `InvalidClientDatetimeField`
101+- `InvalidServerDatetimeField`
102+- `NoUpdate`
103103
104104 Raised when timestamps are missing, malformatted, or update should be skipped.
105105