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

Update EIP-6617: Move to Review #6775

Merged
merged 5 commits into from
Sep 13, 2023

Conversation

chiro-hiro
Copy link
Contributor

No description provided.

@github-actions github-actions bot added c-status Changes a proposal's status s-review This EIP is in Review t-erc labels Mar 24, 2023
@eth-bot eth-bot changed the title Update status to review Update EIP-6617: Move to Review Mar 24, 2023
@eth-bot
Copy link
Collaborator

eth-bot commented Mar 24, 2023

✅ All reviewers have approved.

@eth-bot eth-bot added the e-review Waiting on editor to review label Mar 24, 2023
Copy link
Contributor

@SamWilsn SamWilsn left a comment

Choose a reason for hiding this comment

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

The security considerations section is just "need more discussion", which needs to be looked at before the document can be considered complete enough for review.

You can just put "No security considerations" for now though.

EIPS/eip-6617.md Show resolved Hide resolved
@github-actions
Copy link

The commit 72583f2 (as a parent of b8b13e0) contains errors.
Please inspect the Run Summary for details.

@github-actions github-actions bot added the w-ci Waiting on CI to pass label Apr 17, 2023
@SamWilsn SamWilsn closed this Apr 18, 2023
@SamWilsn SamWilsn reopened this Apr 18, 2023
@github-actions github-actions bot removed the w-ci Waiting on CI to pass label Apr 18, 2023
EIPS/eip-6617.md Outdated Show resolved Hide resolved
EIPS/eip-6617.md Outdated
@title EIP-6617 Bit Based Permission
@dev See https://eips.ethereum.org/EIPS/eip-6617
*/
library EIP6617 {
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 my last complaint before merging as draft is that this should be an interface.

Copy link
Contributor Author

@chiro-hiro chiro-hiro Jun 9, 2023

Choose a reason for hiding this comment

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

This part is a library that focused on bit manipulation that allow us to compose/discompose an uint256 permission. In my opinion, it shouldn't be an interface. We have no benefit by implement it as an interface.

Copy link
Contributor

Choose a reason for hiding this comment

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

A library that implements bit manipulation doesn't need to be an EIP. It can live on GitHub, as an npm package, or in OpenZeppelin. You can have multiple different bit manipulation libraries that make different choices in implementation.

The EIP should only describe externally visible functionality, and in the case of Solidity that usually means just interfaces.

@SamWilsn SamWilsn dismissed their stale review June 9, 2023 02:28

Changes made.

@xinbenlv
Copy link
Contributor

xinbenlv commented Aug 8, 2023

The provided Reference Implementation doesn't match the spec, I don't think at this version it satisfied the editorial requirement to merge for Review status.

/**
* @dev Implement the metadata of EIP-6617
*/
contract EIP6617Meta is IEIP6617Meta {
Copy link
Contributor

Choose a reason for hiding this comment

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

This implementation doesn't implement what is being specified.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @xinbenlv, we will review then update the EIP to match the requirements. Could you be more specific so we can update all at once?.

EIPS/eip-6617.md Outdated
## Specification

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 and RFC 8174.

*Note* The following specifications use syntax from Solidity `0.8.7` (or above)
_Note_ The following specifications use syntax from Solidity `0.8.7` (or above)

- Permission and role MUST be defined as an `uint256`
Copy link
Contributor

@xinbenlv xinbenlv Aug 8, 2023

Choose a reason for hiding this comment

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

I appreciate author's effort to propose and authoring this EIP, folks. Hope this help explain it better about what kind of improvement I personally would like to see in this EIP before it can be merged as a Review

The specification of EIP at this current snapshot is far from editorially ready.

For example, this spec section begins with - Permission MUST be defined as a power of two
This is confusing. Is it a requirement for a complying contract to "have the methods of Permission" ? If so, it shall establish a requirement for certain methods.

For example

A compliant contract MUST have the following interface... 

which contains methods about Permissions

And only then, it could begin to describe the requirement of each method, such as "Permission MUST be defined as a power of two." which is depending on a establishment of Permissions.

Also, next question: what does "Permission MUST be defined as power of two" means, exactly?
Maybe I guess you mean that Permission is bit-wise represented so each Permission is defined as one bit in a bytes32/uint256. etc. If so, the implementation shall refer to these requirements shows how a typical example of permission is implemented and how each methods will interact with it.

etc.

You could probably catch these editorial problem by asking a smart contract developer friend to read it and see if they could implement it by reading your ERC. An ERC/EIP's editorial readiness is all about "does it clearly talk about what a standard requires?" If you don't a good community to ask for this kind of help. Here is one resource: https://github.com/ercref/AllERCDevs/ a regular meetup for live tech peer feedback for ERC authors and devs. Feel free to join us. Next will be 5hours later today, and we do it bi-weekly.


Hey, @SamWilsn FYI, you wrote "I think my last complaint before merging as draft is that this should be an interface." in June, just in case you didn't see my complaints :)

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for the comments @xinbenlv,
I tried to apply all the requests everyone made, tell me if it's better like that 😄

@xinbenlv
Copy link
Contributor

xinbenlv commented Aug 8, 2023 via email

@eth-bot eth-bot enabled auto-merge (squash) September 13, 2023 22:01
Copy link
Collaborator

@eth-bot eth-bot left a comment

Choose a reason for hiding this comment

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

All Reviewers Have Approved; Performing Automatic Merge...

@eth-bot eth-bot merged commit d196326 into ethereum:master Sep 13, 2023
11 checks passed
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c-status Changes a proposal's status e-review Waiting on editor to review s-review This EIP is in Review t-erc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants