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

refactor: remove TriggeringEventFilterBox #4866

Merged

Conversation

mversic
Copy link
Contributor

@mversic mversic commented Jul 19, 2024

Description

I love static typing. It prevents many errors.
But there is a tradeoff between static typing and an API that is easy to use.
Sometimes too much static typing is difficult for end users

Linked issue

Closes #4376

Benefits

Checklist

  • I've read CONTRIBUTING.md
  • I've used the standard signed-off commit format (or will squash just before merging)
  • All applicable CI checks pass (or I promised to make them pass later)
  • (optional) I've written unit tests for the code changes
  • I replied to all comments after code review, marking all implemented changes with thumbs up

@github-actions github-actions bot added the api-changes Changes in the API for client libraries label Jul 19, 2024
@mversic mversic force-pushed the remove_triggering_event_filter_box branch 4 times, most recently from a41865b to a824afd Compare July 22, 2024 08:07
Copy link
Contributor

@Erigara Erigara left a comment

Choose a reason for hiding this comment

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

I still not sure why we should treat trigger completion event separately.

It was requested like that in #2885, but reasons are not specified.

core/src/smartcontracts/isi/triggers/mod.rs Show resolved Hide resolved
@Erigara
Copy link
Contributor

Erigara commented Jul 22, 2024

In general i agree that strict typing in this case create more inconvenience than value.

@mversic mversic force-pushed the remove_triggering_event_filter_box branch from a824afd to ec25f64 Compare July 22, 2024 14:42
Copy link
Contributor

@0x009922 0x009922 left a comment

Choose a reason for hiding this comment

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

LGTM, good tradeoff.

data_model/src/trigger.rs Show resolved Hide resolved
@mversic mversic force-pushed the remove_triggering_event_filter_box branch from ec25f64 to 3bb0b8c Compare July 23, 2024 21:12
@mversic mversic enabled auto-merge (squash) July 23, 2024 21:13
@Erigara Erigara force-pushed the remove_triggering_event_filter_box branch from 3bb0b8c to 015e030 Compare July 24, 2024 07:57
Signed-off-by: Marin Veršić <marin.versic101@gmail.com>
@mversic mversic force-pushed the remove_triggering_event_filter_box branch from 015e030 to ed886e6 Compare July 24, 2024 09:40
@mversic mversic merged commit 2dec013 into hyperledger:main Jul 24, 2024
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api-changes Changes in the API for client libraries
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Should we remove TriggeringEventFilterBox?
3 participants