Where we can see that “domain.expiryDate” for unwrapped/wrapped names
is actually expiryDate + grace period.
So, my question is:
did I get this things straight? I have to get the correct expiryDate
for unwrapped/wrapped names from “registration.expiryDate”
and for subnames from “wrappedDomain.expiryDate” ?
You can only see this in NameWrapper contract — note: this only applies to ETH2LDs.
I think registration.expiryDate corresponds to BaseRegistrar.{NameRenewed,NameRegistered} events and wrappedDomain.expires corresponds to NameWrapper.ExpiryExtended event.
IMO for expiration: if ETH2LDs, you should consult nameExpires() and use the wrapper expiration for non-ETH2LD wrapped names.
nameRenew actually only updates the expiry on registration and not on wrappedDomain.
so if a name gets wrapped it inherits the expiry from the domain.expiry (which includes grace) but will not be updated again once I renew my wrapped name.
wrapped.expiry should therefore (atm) only be used to track sub expiries.