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

abcoathup GSN Bouncers review #1916

Merged
merged 26 commits into from
Sep 25, 2019
Merged

abcoathup GSN Bouncers review #1916

merged 26 commits into from
Sep 25, 2019

Conversation

abcoathup
Copy link
Contributor

@abcoathup abcoathup commented Sep 11, 2019

I have updated the document based on my review.

I used request transactions rather than call, though the code uses call.

@abcoathup abcoathup marked this pull request as ready for review September 12, 2019 07:08
Copy link
Contributor

@frangio frangio left a comment

Choose a reason for hiding this comment

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

Thanks @abcoathup! There are some good improvements here. I think the GSNBouncerERC20Fee section could use some restructuring of the content. I left some details in a comment below.

docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Show resolved Hide resolved

The only thing you must do is extend from `GSNRecipient` and implement the accept method.
Depending on the logic for your Custom Bouncer, you may need to implement `_postRelayedCall` and `_preRelayedCall`.
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should explain how the charge estimates work, and why they work that way: that pre will tell you the maximum possible charge, and later post will tell you the real amount. Or point towards GSNBouncerERC20Fee as an example of how to deal with it.

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 have pointed to the GitHub repo 2.4.0 versions of GSNBouncerERC20Fee and GSNBouncerSignature. Is there a better way to do this?

@abcoathup
Copy link
Contributor Author

WIP, still a couple of points to handle tomorrow.

@abcoathup
Copy link
Contributor Author

Updated, ready for review

docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
docs/modules/ROOT/pages/gsn-bouncers.adoc Outdated Show resolved Hide resolved
Copy link
Contributor

@frangio frangio left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you @abcoathup for reviewing this document!

@frangio frangio merged commit 18473d0 into OpenZeppelin:master Sep 25, 2019
@abcoathup abcoathup deleted the abcoathup-gsn-review branch September 25, 2019 02:21
frangio pushed a commit that referenced this pull request Oct 8, 2019
* Fix typo

* Replace pseudo code contracts with sample code

* Update GSN Bouncers text

* More text changes

* Update with latest code and remove reference to allowance

* Capitalize Custom Bouncer

* Update docs/modules/ROOT/pages/gsn-bouncers.adoc

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Update gsn-bouncers.adoc with Antora cross reference

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Revert to handling msg.sender msg.data differently

* Change by default to simplest implementation

* Change signing to include signature for GSNBouncerSignature

* Reword summary of what is in the guide

* Remove "The" from before `GSNBouncer...`

* Fix code snippet markdown

* Change to API references to xref:api

* Remove code from How it works sections

* Explain 1:1 exchange rate

* Change transaction request to relayed call

* Minor fixes

* Add info to Custom Bouncers

* Typo

* Minor fixes

* reorder sentence based on review gsn-bouncers.adoc

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Improve wording of signing of relayed call parameters by trusted signer

(cherry picked from commit 18473d0)
frangio pushed a commit that referenced this pull request Oct 29, 2019
* Fix typo

* Replace pseudo code contracts with sample code

* Update GSN Bouncers text

* More text changes

* Update with latest code and remove reference to allowance

* Capitalize Custom Bouncer

* Update docs/modules/ROOT/pages/gsn-bouncers.adoc

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Update gsn-bouncers.adoc with Antora cross reference

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Revert to handling msg.sender msg.data differently

* Change by default to simplest implementation

* Change signing to include signature for GSNBouncerSignature

* Reword summary of what is in the guide

* Remove "The" from before `GSNBouncer...`

* Fix code snippet markdown

* Change to API references to xref:api

* Remove code from How it works sections

* Explain 1:1 exchange rate

* Change transaction request to relayed call

* Minor fixes

* Add info to Custom Bouncers

* Typo

* Minor fixes

* reorder sentence based on review gsn-bouncers.adoc

Co-Authored-By: Francisco Giordano <frangio.1@gmail.com>

* Improve wording of signing of relayed call parameters by trusted signer

(cherry picked from commit 18473d0)
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.

2 participants