erc7730.model.resolved.context module
- class erc7730.model.resolved.context.ResolvedBindingContext(*, deployments: Annotated[list[ResolvedDeployment], MinLen(min_length=1)])[source]View on GitHub
Bases:
Model- deployments: list[ResolvedDeployment]
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedContract(*, deployments: Annotated[list[ResolvedDeployment], MinLen(min_length=1)], abi: list[Annotated[Constructor | Event | Function | Fallback | Error | Receive, FieldInfo(annotation=NoneType, required=True, discriminator='type')]], addressMatcher: HttpUrl | None = None, factory: ResolvedFactory | None = None)[source]View on GitHub
Bases:
ResolvedBindingContextContract Binding Context.
The contract binding context is a set constraints that are used to bind the ERC7730 file to a specific smart contract.
- abi: list[Annotated[Constructor | Event | Function | Fallback | Error | Receive, FieldInfo(annotation=NoneType, required=True, discriminator='type')]]
- addressMatcher: HttpUrl | None
- factory: ResolvedFactory | None
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedContractContext(*, id: ~typing.Annotated[str, FieldInfo(annotation=NoneType, required=True, title='Id', description='An internal identifier that can be used either for clarity specifying what the element is or as a reference in device specific sections.', examples=['some_identifier'], metadata=[MinLen(min_length=1)]), ~erc7730.common.pydantic.ErrorTypeLabel(func=~erc7730.common.pydantic.ErrorTypeLabel._validator.<locals>.validate, json_schema_input_type=PydanticUndefined)] | None = None, contract: ~erc7730.model.resolved.context.ResolvedContract)[source]View on GitHub
Bases:
ModelContract Binding Context.
The contract binding context is a set constraints that are used to bind the ERC7730 file to a specific smart contract.
- contract: ResolvedContract
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedDeployment(*, chainId: int, address: ~typing.Annotated[str, ~annotated_types.MinLen(min_length=42), ~annotated_types.MaxLen(max_length=42), _PydanticGeneralMetadata(pattern='^0x[a-f0-9]+$'), ~pydantic.functional_validators.BeforeValidator(func=~erc7730.model.types.<lambda>, json_schema_input_type=PydanticUndefined), ~erc7730.common.pydantic.ErrorTypeLabel(func=~erc7730.common.pydantic.ErrorTypeLabel._validator.<locals>.validate, json_schema_input_type=PydanticUndefined)])[source]View on GitHub
Bases:
ModelA deployment describing where the contract is deployed.
The target contract (Tx to or factory) MUST match one of those deployments.
- chainId: int
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedDomain(*, name: str | None = None, version: str | None = None, chainId: int | None = None, verifyingContract: Annotated[str, FieldInfo(annotation=NoneType, required=True, title='Contract Address', description='An Ethereum contract address (normalized to lowercase).', metadata=[MinLen(min_length=42), MaxLen(max_length=42), _PydanticGeneralMetadata(pattern='^0x[a-f0-9]+$')]), ~pydantic.functional_validators.BeforeValidator(func=~erc7730.model.types.<lambda>, json_schema_input_type=PydanticUndefined), ~erc7730.common.pydantic.ErrorTypeLabel(func=~erc7730.common.pydantic.ErrorTypeLabel._validator.<locals>.validate, json_schema_input_type=PydanticUndefined)] | None = None)[source]View on GitHub
Bases:
ModelEIP 712 Domain Binding constraint.
Each value of the domain constraint MUST match the corresponding eip 712 message domain value.
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedEIP712(*, deployments: Annotated[list[ResolvedDeployment], MinLen(min_length=1)], domain: ResolvedDomain | None = None, domainSeparator: str | None = None, schemas: list[EIP712Schema])[source]View on GitHub
Bases:
ResolvedBindingContextEIP 712 Binding.
The EIP-712 binding context is a set of constraints that must be verified by the message being signed.
- domain: ResolvedDomain | None
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- schemas: list[EIP712Schema]
- class erc7730.model.resolved.context.ResolvedEIP712Context(*, id: ~typing.Annotated[str, FieldInfo(annotation=NoneType, required=True, title='Id', description='An internal identifier that can be used either for clarity specifying what the element is or as a reference in device specific sections.', examples=['some_identifier'], metadata=[MinLen(min_length=1)]), ~erc7730.common.pydantic.ErrorTypeLabel(func=~erc7730.common.pydantic.ErrorTypeLabel._validator.<locals>.validate, json_schema_input_type=PydanticUndefined)] | None = None, eip712: ~erc7730.model.resolved.context.ResolvedEIP712)[source]View on GitHub
Bases:
ModelEIP 712 Binding.
The EIP-712 binding context is a set of constraints that must be verified by the message being signed.
- eip712: ResolvedEIP712
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class erc7730.model.resolved.context.ResolvedFactory(*, deployments: list[ResolvedDeployment], deployEvent: str)[source]View on GitHub
Bases:
ModelA factory constraint is used to check whether the target contract is deployed by a specified factory.
- deployEvent: str
- deployments: list[ResolvedDeployment]
- model_config = {'allow_inf_nan': False, 'arbitrary_types_allowed': False, 'extra': 'forbid', 'frozen': True, 'strict': True, 'validate_assignment': True, 'validate_default': True, 'validate_return': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].