Plutonomicon / cardano-transaction-lib

A Purescript library for building smart contract transactions on Cardano
https://plutonomicon.github.io/cardano-transaction-lib/
MIT License
93 stars 50 forks source link

Slot length is truncated on private testnet (Plutip) #868

Closed ngua closed 2 years ago

ngua commented 2 years ago

During Slot~POSIXTime conversion, we might be inadvertently rounding a value somewhere to the nearest second. This might cause a division by zero error when using conversions and slotting arithmetic in Plutip tests

klntsky commented 2 years ago

I'm for banning div from the codebase (it is silently partial).

rynoV commented 2 years ago

It seems like the issue is ogmios is returning a slot length of 0, so before we fix that no changes to ctl will help

klntsky commented 2 years ago

From slack:

If someone wants to try to update the Ogmios input and the parser, I cherry-picked the commit on mlabs-haskell/ogmios. The commit on our fork is 496fd7555131eab2a0b5702011a260064a145824. We should wait for the fixes to the ogmios.wsp.json file as well though before merging the changes (edited)