bitcoin-dev-project/sim-ln

Validation: Do not allow defined activity with zero amount

Opened this issue · 4 comments

Currently, we allow zero amount payments to be skipped over to allow for the possibility that our random payment amount generation spits out a zero value every once in an hour.

Right now we don't validate that we're provided with a non-zero defined activity amount, so we'll hit the same check and just endlessly not dispatch payments if we're given a zero value.

We should update validate_activity to disallow zero values.

Hey @carlaKC am interested in working on this issue.

@carlaKC
On validate_activity function I added validation to check for zero amount_msats.

Screenshot 2024-04-15 at 10 26 11

On running cargo run I get the validation error

Screenshot 2024-04-15 at 10 28 59

Which is fine but it seems to skip on running sim-cli

Screenshot 2024-04-15 at 10 30 12

Is that the expected behaviour?

Which is fine but it seems to skip on running sim-cli

Have you re-installed sim-cli before you test?

Which is fine but it seems to skip on running sim-cli

Have you re-installed sim-cli before you test?

That fixed it. Thank you