Skip to content

Error messages incorrectly reports missing wallet and hides actual incompatibility reason #32

@acogn

Description

@acogn

Summary

When a payment requirement is incompatible for reasons other than wallet presence (e.g., unsupported token or network filter), purl reports a wallet-missing style error, even when a wallet is configured.

How to Reproduce

  1. Configure a Solana wallet (purl wallet add, set active).
  2. Call an endpoint that returns a Solana payment requirement with an unsupported token (e.g. USDT)
  3. Run: purl --dry-run <url>.

Actual

Error implies no compatible wallet is configured.

Expected

Error should indicate the true incompatibility reason:

  • unsupported token configuration, or
  • network filtered out, or
  • missing wallet (only when that is the actual cause).

Root Cause

  • Negotiator collapsed all incompatibilities into NoCompatibleMethod without reason metadata.
  • Token-support failure (TokenConfigNotFound) was reduced to a boolean and discarded.
  • CLI converted PurlError to string (anyhow!("{e}")), losing typed error context.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions