You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The pattern for hex encoded 256 bit unsigned integer doesn't look correct to me:
^0x([1-9a-f]+[0-9a-f]{0,31})|0$
I think there are two problems here. The first one is that the + there means that one million 1s would be a valid value, which is obviously incorrect.
And if the + is removed, there's still a problem, because then the string has a length of at most 32 hex characters, but for a 32-byte value the max length should be 64 hex characters.
I think the right pattern should be:
^0x([1-9a-f][0-9a-f]{0,63})|0$
I don't know why the test for this works fine though. I haven't checked how these tests are executed, and if they validate the patterns somehow.
The text was updated successfully, but these errors were encountered:
The pattern for hex encoded 256 bit unsigned integer doesn't look correct to me:
I think there are two problems here. The first one is that the
+
there means that one million1
s would be a valid value, which is obviously incorrect.And if the
+
is removed, there's still a problem, because then the string has a length of at most 32 hex characters, but for a 32-byte value the max length should be 64 hex characters.I think the right pattern should be:
I don't know why the test for this works fine though. I haven't checked how these tests are executed, and if they validate the patterns somehow.
The text was updated successfully, but these errors were encountered: