Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resolve_hashes does not return datums #186

Open
theeldermillenial opened this issue Jan 10, 2025 · 1 comment
Open

resolve_hashes does not return datums #186

theeldermillenial opened this issue Jan 10, 2025 · 1 comment

Comments

@theeldermillenial
Copy link

What Git revision / release tag are you using?

v2.10.0

Describe what the problem is?

When retrieving matches using the resolve_hashes flag, datum hashes are returned but the datum field is empty. The datums appear to be resolvable because fetching the datums by hash using the endpoint works as expected.

What should be the expected behavior?

Resolvable datum hashes are retrieved in the match outputs when the resolve_hashes flag is used.

If applicable, what are the logs from the server around the occurence of the problem?

Here is an example of a match when using the resolve_hashes flag:

{
    "transaction_index": 3,
    "transaction_id": "8ee798c896b9918abaeb56b9f6f47bde51d8abf32cd52dc911a10e2456e03a87",
    "output_index": 1,
    "address": "addr1z84q0denmyep98ph3tmzwsmw0j7zau9ljmsqx6a4rvaau66j2c79gy9l76sdg0xwhd7r0c0kna0tycz4y5s6mlenh8pq777e2a",
    "value": {
        "coins": 362467826015,
        "assets": {
            "f5808c2c990d86da54bfc97d89cee6efa20cd8461616359478d96b4c.4d5350": 1,
            "f5808c2c990d86da54bfc97d89cee6efa20cd8461616359478d96b4c.7dd6988c5a86693c76aeec1ea94afa41770be0de21a775ca7a2a1eabdb6a0171": 9223371692031396353,
            "c48cbb3d5e57ed56e276bc45f99ab39abe94e6cd7ac39fb402da47ad.0014df105553444d": 391881587861
        }
    },
    "datum_hash": "69619e16b28156f6e669de4230dd08771c33270b40fdf3aa421ecebd9a9f167f",
    "datum": None,
    "datum_type": <DatumType.inline: "inline">,
    "script_hash": None,
    "script": None,
    "created_at": {
        "slot_no": 144650049,
        "header_hash": "5f2bfdb266166f7c5bdb80d898e1ef75f29ce42d684491752dfdcc9e3c085cee"
    },
    "spent_at": None
}
@KtorZ
Copy link
Member

KtorZ commented Jan 13, 2025

So. I've looked into the code again without finding anything wrong (or at least, anything that could explain this). I also checked the 750,000+ datums entries on Preview without finding any inline datum without a corresponding non-null `datum value 🤔 ...

While I could imagine an issue with the garbage collector that could cause this, it would be incompatible with your second observation that the datum is still available through the normal endpoint. I'll have to investigate further looking at mainnet data.

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

No branches or pull requests

2 participants