New issue
Advanced search Search tips

Issue 785972 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac , Fuchsia
Pri: 3
Type: Bug

Blocking:
issue 397952



Sign in to add a comment

<input type=number> shows inappropriate console warning message for floating point out of range

Reported by justja...@gmail.com, Nov 16 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 6.3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36

Steps to reproduce the problem:
1. Make an HTML file with just this line:

<input type="number" value="1.79E+309">

2. On the page, the value of input is an empty string. In the devtools, the warning message:

The specified value "1.79E+309" is not a valid number. The value must match to the following regular expression: -?(\d+|\d+\.\d+|\.\d+)([eE][-+]?\d+)?

What is the expected behavior?

What went wrong?
The warning message is incorrect.

execute the code:

/-?(\d+|\d+\.\d+|\.\d+)([eE][-+]?\d+)?/.test("1.79E+309")

the result is: true

Did this work before? N/A 

Chrome version: 62.0.3202.94  Channel: stable
OS Version: 6.3
Flash Version:
 
20171116230442.png
5.9 KB View Download
Labels: Needs-Triage-M62

Comment 2 by l...@chromium.org, Nov 16 2017

Blocking: 397952
Components: -Platform>DevTools Blink>Forms>Number
Owner: tkent@chromium.org
Status: Assigned (was: Unconfirmed)
Thanks for the report.

The value you've shown is just above the max double-precision number.  According to the spec, the number input has a parse error if the value is not in the set of "IEEE 754 double-precision floating-point values".  tkent@, could you please take a look?

Comment 3 by justja...@gmail.com, Nov 17 2017

But the warning message shown in devtools is "... The value must match to the following regular expression..."


Comment 4 by tkent@chromium.org, Jan 9 2018

Labels: -Pri-2 OS-Android OS-Chrome OS-Fuchsia OS-Linux OS-Mac Pri-3
Owner: ----
Status: Available (was: Assigned)
Summary: input type=number Show inappropriate console warning message for floating point out of range (was: input type=number Show console warning message for floating point out of range)

Comment 5 by tkent@chromium.org, Jan 11 2018

Summary: <input type=number> shows inappropriate console warning message for floating point out of range (was: input type=number Show inappropriate console warning message for floating point out of range)
Project Member

Comment 6 by sheriffbot@chromium.org, Jan 11

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Hotlist-Recharge-Cold
Status: Available (was: Untriaged)

Sign in to add a comment