-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Turn on ENSIP-15 by default #3024
Conversation
- This causes methods that utilize normalize_name() internally to throw with a very obscure message that empty names aren't allowed. e.g. when calling ns.name(ens_address), if the reverse resolver isn't properly set up it will throw ``InvalidName`` with a message saying names can't be empty. This would create a lot of confusion. - ``normalize_name_ensip15()`` method still raises ``InvalidName`` on empty name and this seems more appropriate when directly calling the method.
c8f0761
to
a1045aa
Compare
- Remove the ENSIP-15 flags since we will be turning this on as default in ``v6``. - Keep tests that assert the ``normalize_name_ensip15()`` method is called under the hood for utility methods, explicitly ensuring that we are normalizing names passed to those methods according to standard.
408a765
to
dfbdaa7
Compare
dfbdaa7
to
85e272d
Compare
85e272d
to
d9766b7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do with nits as you will, lgtm!
ee93d15
to
4212ffd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not blocking, thought of something we could add to add to the docs.
|
||
web3.py ``v6.1.0`` introduced ENS name normalization standard | ||
`ENSIP-15 <https://docs.ens.domains/ens-improvement-proposals/ensip-15-normalization-standard>`_. | ||
This update to ENS name validation and normalization won't affect ~99% |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could add a statement about the prior "art" of normalization in the ENS module. Not sure if it would help to call out specific cases that prompted the breaking change but that might be useful too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could add a statement about the prior "art" of normalization in the ENS module.
Any suggestion here? I'm not sure I understand.
Not sure if it would help to call out specific cases that prompted the breaking change but that might be useful too.
Not sure here either. I think the biggest driver was that there wasn't a properly defined standard to begin with, or at least clear lines drawn when it comes to complex names. I lean towards deferring to the proper ENS documentation for answering the why questions but if you think of a clarifying addition I'm happy to pop it in here 👀 .
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this doesn't make sense, feel free to leave it out. I was not following everything that was implemented prior to this release. Suggestion might be:
Prior to this version, ENS normalization used a ruleset that allowed invalid names.
What you have is basically the inverse, so I think people will get it with or without the history lesson.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, heard. Yeah I think that can be addressed in the proper ENS docs as long as we link out to it here. There's a motivation section in the ENSIP-15
documentation that I think addresses this pretty well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Just a small nit around the version this was introduced in in the docs.
4212ffd
to
48cbe73
Compare
What was wrong?
closes #3010
How was it fixed?
normalize_name_ensip15
as this is important to test for.Todo:
Cute Animal Picture