Skip to content

Conversation

@samuelWilliams99
Copy link
Contributor

No description provided.

@samuelWilliams99 samuelWilliams99 added the enhancement New feature or request label Jun 14, 2022
Raw rp -> deserialiseRaw rp
Signed sp -> fmap CAPI.getTxBody <$> deserialiseSigned sp

pparamsRes <- QueryNode.queryProtocolParams debugNodeInf
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure which way is better, but protocol params can be pulled from PABConfig.
(slot <-> time conversions now use pparams from PABConfig).

It feels like getting them from PABConfig will be safer as cardano-cli will use that also.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I saw this ticket and assumed we wanted to move over to using the node for everything over time #112
I can switch to params if we'd prefer?
I bellieve if the cli uses params that don't match the node, it'll fail regardless, no?

Copy link
Collaborator

@mikekeke mikekeke Jun 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I bellieve if the cli uses params that don't match the node, it'll fail regardless, no?

Can't say with confidence =)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love cardano :)

getScaledBudget maxUnits scaler budget =
if fst scalers >= 1 && snd scalers >= 1
then Right $ fmap (fmap $ scaleBudget scalers) budget
else Left $ BudgetEstimationError "Exceeded global transaction budget"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it could be helpful if current maximum and calculated budgets will be printed together with the error message.

@samuelWilliams99 samuelWilliams99 merged commit 405bfc9 into master Jun 15, 2022
@samuelWilliams99 samuelWilliams99 deleted the sam/expose-budget-multiplier branch June 15, 2022 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants