You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[stable/10] Backport: restore TenantId/BusinessId model typing before 10.1.0 (#329) #330
Backport the semantic-type regression fix to stable/10before 10.1.0 is released.
Since b81c24f (7 May), 18 models on stable/10 have tenant_id: str and 3 have business_id: str, where v10.0.0 typed them TenantId / BusinessId. Examples: ProcessInstanceResult, UserTaskResult, JobSearchResult, MessageSubscriptionResult, the deployment result models, ElementInstanceFilter*, and ProcessCreationById/ByKey. Shipping 10.1.0 as it is would remove these nominal types from the public API compared with 10.0.0.
Root cause and fix
See the main issue (#329) for the full analysis. In hooks/post_gen/1000_patch_semantic_types_in_models.py, b81c24f's ambiguity guard drops tenantId and businessId from the global name map. The per-schema fallback then:
ignores properties declared as a $ref (or single-element allOf$ref) to a semantic-key schema, because it only counts an inline x-semantic-type;
never matches models that openapi-python-client names from the schema title, e.g. process_creation_by_id.py vs schema ProcessInstanceCreationInstructionById.
Apply the same fix on stable/10, against the spec stable/10 already uses (don't regenerate from spec main):
resolve $ref / allOf$ref targets carrying x-semantic-type in the per-schema map;
key the per-schema map by the generated model name (title when set, else schema name);
add the regression test pinning ProcessInstanceResult.tenant_id: TenantId, ProcessCreationById.tenant_id / business_id, etc.;
confirm that the generated models have no tenant_id: str except where the spec declares a bare string (ExpressionEvaluationRequest), matching v10.0.0;
keep the name / ClusterVariableName case from b81c24f working.
You can implement this independently of the main PR. The hook is the same on both branches.
Activity
jwulf commentedon Oct 25, 2026
🤖 Starting work on this issue — branch
feat/issue-330.jwulf commentedon Oct 25, 2026
🤖 Starting work on this issue — branch
feat/issue-330.fix: restore TenantId/BusinessId model typing in generated SDK (#332)