Drift
TypeScript's MissingWalletAddress explicitly narrows its constructor to a single message parameter, dropping the field/exchange parameters its parent ValidationError exposes. Python's MissingWalletAddress has no __init__ override at all, so it inherits ValidationError.__init__(self, message, field=None, **kwargs) verbatim — callers can pass field=/exchange= that have no TypeScript equivalent.
TypeScript SDK
sdks/typescript/pmxt/hosted-errors.ts:152-157:
export class MissingWalletAddress extends ValidationError {
constructor(message: string) {
super(message);
this.name = this.constructor.name;
}
}
Only message is accepted; field and exchange (both present on the parent ValidationError constructor, errors.ts:99) are unreachable when constructing MissingWalletAddress directly.
Python SDK
sdks/python/pmxt/_hosted_errors.py:100-101:
class MissingWalletAddress(ValidationError):
"""Hosted trading request requires a wallet address before any network call."""
No __init__ is defined, so it inherits ValidationError.__init__(self, message: str, field: str | None = None, **kwargs) -> None (errors.py:107-109) unchanged — MissingWalletAddress("msg", field="walletAddress", exchange="polymarket") is valid Python but has no TypeScript equivalent constructor call.
Expected
MissingWalletAddress's constructor surface should match across languages — either TypeScript widens its constructor to accept field/exchange like its parent, or Python narrows its override to message only, consistent with how the class is actually constructed in practice.
Impact
Code that constructs MissingWalletAddress with a field or exchange argument (as its parent class and other error subclasses generally support) works in Python but is a compile-time type error in TypeScript, giving the two SDKs different construction ergonomics for hosted-trading wallet-address validation failures.
Found by automated SDK cross-language drift audit
Drift
TypeScript's
MissingWalletAddressexplicitly narrows its constructor to a singlemessageparameter, dropping thefield/exchangeparameters its parentValidationErrorexposes. Python'sMissingWalletAddresshas no__init__override at all, so it inheritsValidationError.__init__(self, message, field=None, **kwargs)verbatim — callers can passfield=/exchange=that have no TypeScript equivalent.TypeScript SDK
sdks/typescript/pmxt/hosted-errors.ts:152-157:Only
messageis accepted;fieldandexchange(both present on the parentValidationErrorconstructor,errors.ts:99) are unreachable when constructingMissingWalletAddressdirectly.Python SDK
sdks/python/pmxt/_hosted_errors.py:100-101:No
__init__is defined, so it inheritsValidationError.__init__(self, message: str, field: str | None = None, **kwargs) -> None(errors.py:107-109) unchanged —MissingWalletAddress("msg", field="walletAddress", exchange="polymarket")is valid Python but has no TypeScript equivalent constructor call.Expected
MissingWalletAddress's constructor surface should match across languages — either TypeScript widens its constructor to acceptfield/exchangelike its parent, or Python narrows its override tomessageonly, consistent with how the class is actually constructed in practice.Impact
Code that constructs
MissingWalletAddresswith afieldorexchangeargument (as its parent class and other error subclasses generally support) works in Python but is a compile-time type error in TypeScript, giving the two SDKs different construction ergonomics for hosted-trading wallet-address validation failures.Found by automated SDK cross-language drift audit