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

Use go-perun event and timeout types #11

Merged
merged 3 commits into from
Apr 4, 2024
Merged

Conversation

iljabvh
Copy link
Collaborator

@iljabvh iljabvh commented Apr 3, 2024

This PR removes the custom Event and Timeout types from the event and channel package to use the types provided by go-perun.

iljabvh added 3 commits April 3, 2024 15:21
…interface from go-perun instead. Accordingly, use RegisteredEvent and ConcludedEvent instead of custom event types.

* refactor(channel): Remove timeout.go, as its functionality is now located in the event package.

*refactor(event): Remove the Tstamp() method, as it is not used now. Use TimeTimeout type from go-perun instead of custom Timeout type in the Timeout() methods. Remove EventDataFromChannel method because it was only needed for the AdjEvent interface. Use NewTimeTimeout instead of NewTimeout. Rem
… events.

* refactor(event)
: Remove Timeout() method and Timestamp field in PerunEvent events. Remove custom Timeout methods that are already provided by go-perun

* fix(channel): Make AdjEventSub.Next() process PerunEvent events and return AdjudicatorEvent events.
…truct. Introduce DefaultChallengeDuration. Refactor NewTimeTimeout to satisfy TimeoutV field for PerunEvent events.

* chore(event): Add doc.go, remove duplicate error check. Refactor MakeTimeout.
@iljabvh iljabvh merged commit afd5083 into dev Apr 4, 2024
1 check passed
@iljabvh iljabvh deleted the refactor-timeout-events branch April 4, 2024 08:52
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

Successfully merging this pull request may close these issues.

1 participant