CardanoSolutions / ogmios

❇️ A WebSocket JSON/RPC bridge for Cardano
https://ogmios.dev
Mozilla Public License 2.0
304 stars 90 forks source link

No support for stake script rewards #277

Closed klntsky closed 1 year ago

klntsky commented 1 year ago

Describe what the problem is?

It looks like Ogmios only support querying stake rewards for PubKey hashes, there's no ScriptHash support:

  1. https://github.com/CardanoSolutions/ogmios/blob/7a039607bfb982ddcba8ef9f6c83afeeb7776974/server/src/Ogmios/Data/Json/Query.hs#L904
  2. https://github.com/CardanoSolutions/ogmios/blob/7a039607bfb982ddcba8ef9f6c83afeeb7776974/server/src/Ogmios/Data/Json/Query.hs#L1589
  3. https://github.com/input-output-hk/cardano-ledger/blob/9a25a43f3970941a2cd64029f7ce667b48832635/libs/cardano-ledger-core/src/Cardano/Ledger/Credential.hs#L73

What should be the expected behavior?

We need this kind of query to work with script hashes as well for CTL.

KtorZ commented 1 year ago

Indeed, as indicated in the note here:

https://github.com/CardanoSolutions/ogmios/blob/7a039607bfb982ddcba8ef9f6c83afeeb7776974/server/src/Ogmios/Data/Json/Query.hs#L1578

So, bech32 will likely come at the rescue here.

KtorZ commented 1 year ago

Closed in 1495b4f5655ad61b03f5318187a3adbebd9e5144