Skip to content

Commit 261e2a3

Browse files
vdusekclaude
andauthored
ci: Remove volatile metadata from generated models header (#718)
## Summary - Disable `timestamp` and `filename` in the `datamodel-codegen` header via `pyproject.toml` config - Prevents spurious PRs when the OpenAPI spec hasn't changed but regeneration produces a diff due to volatile metadata (timestamp, source URL). ## Test plan - [x] Regenerated models locally — header is now a single static line `# generated by datamodel-codegen` - [x] CI passes Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 8a0e8e1 commit 261e2a3

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

pyproject.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,6 +226,8 @@ extra_fields = "allow"
226226
allow_population_by_field_name = true
227227
aliases = "datamodel_codegen_aliases.json"
228228
formatters = ["ruff-check", "ruff-format"]
229+
custom_file_header = "# generated by datamodel-codegen"
230+
disable_timestamp = true
229231

230232
[tool.uv]
231233
# Minimal defense against supply-chain atatcks.

src/apify_client/_models.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
# generated by datamodel-codegen:
2-
# filename: openapi.json
3-
# timestamp: 2026-04-13T07:02:33+00:00
1+
# generated by datamodel-codegen
42

53
from __future__ import annotations
64

0 commit comments

Comments
 (0)