Skip to content

fix: add validation for mutually exclusive Signal target fields#203

Open
thebookofiz wants to merge 2 commits into0xIntuition:v2_0from
thebookofiz:fix/signal-mutually-exclusive-validation
Open

fix: add validation for mutually exclusive Signal target fields#203
thebookofiz wants to merge 2 commits into0xIntuition:v2_0from
thebookofiz:fix/signal-mutually-exclusive-validation

Conversation

@thebookofiz
Copy link
Copy Markdown
Collaborator

Adds validate() method to Signal struct to ensure exactly one of atom_id, triple_id, deposit_id, or redemption_id is set.

These fields are mutually exclusive and this validation prevents invalid data from being inserted into the database.

Implements the TODO that was in the code comment.

OpenClaw Agent added 2 commits February 20, 2026 08:04
Addresses GitHub issue 0xIntuition#151: Check for EIP-55 when resolving account atoms.

This change adds EIP-55 checksum validation in the resolver's process_account
function. When an account with an invalid EIP-55 checksum is encountered,
the ENS resolution is skipped instead of attempting to resolve it.

This prevents potential issues where addresses with incorrect checksum
formatting could cause false positives or errors during ENS resolution.

The validation uses Address::parse_checksummed from the alloy library,
which is the same approach used in metadata.rs for atom creation validation.
Adds validate() method to Signal struct to ensure exactly one of
atom_id, triple_id, deposit_id, or redemption_id is set. These fields
are mutually exclusive and this validation prevents invalid data from
being inserted into the database.

Implements the TODO that was in the code comment.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant