Skip to content

TransactionReceipt status type should be nullable #3841

Closed

Description

@nicklatkovich

Check existing issues

Viem Version

2.33.2

Current Behavior

TransactionReceipt['status'] is 'success' | 'reverted'

Expected Behavior

TransactionReceipt['status'] is 'success' | 'reverted' | null

Steps To Reproduce

  const client = createPublicClient({ transport: http(CONFIG.WEB3_PROVIDER) });
  const hash: Hash = "0x592ae92598bffc4e142d0b68b720788451d320d6e34da06fd765c488e7330027";
  const receipt = await client.getTransactionReceipt({ hash });
  // TS with strict:true doesn't fail here, but it should, since `receipt.status` is null
  const status: string = receipt.status;

Link to Minimal Reproducible Example

No response

Anything else?

No response

Activity

  1. jxom commented on Aug 5, 2025

    @jxom
    Member

    Receipts must have a 0x1 (success) or 0x0 (failure). How is null coming through?

  2. locked and limited conversation to collaborators on Aug 5, 2025
  3. converted this issue into a discussion #3842 on Aug 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions