Created attachment 1694570 [details] 1_KnativeServing_form.png Description of problem: Create Operand form: Knative Serving - Integer field erroneously allows char (should map to "number" widget) See attached screenshots. Version-Release number of selected component (if applicable): OCP4.5 How reproducible: 100% Steps to Reproduce: 1. Install OpenShift Serverless Operator from "OperatorHub" view 2. Go to "Installed Operators" view and create "Knative Serving" instance 3. Find "High Availability --> replicas" field, type in char Actual results: Chars are allowed Expected results: Should only accept integer Additional info:
*** Bug 1843242 has been marked as a duplicate of this bug. ***
Checked on ocp 4.6 cluster with payload 4.6.0-0.ci-2020-06-04-011434. 1. Install OpenShift Serverless Operator from "OperatorHub" view 2. Go to "Installed Operators" view and create "Knative Serving" instance 3. Find "High Availability --> replicas" field, type in char, eg: abc, could not succeed. Could type in number. Type in "--1--2--3--4.5-6", click "Create". Will succeed, and check the instance yaml, the replicas is set 2: high-availability: replicas: 2 It's better not allow input "-",".".
Created attachment 1695019 [details] special-char
This is working as expected. The HTML number input element allows the characters '+-.,e', which matches the behavior of previous releases. I would have to dig further into why step 3 in Comment 6 seems to be resulting in an incorrectly parsed value for High Availability replicas, but I think that might be a separate bug with the way number fields are parsed.
I've been trying to reproduce the issue where an incorrect number is parsed from an invalid string in a number field. I can't seem to reproduce. I entered the exact same string you used in Comment 6 on multiple different forms with number fields. After creating the instance, the resulting resource did not have any value defined on the corresponding property. Feel free to open another bug if you are able to reproduce the issue again.
The original issue could be reproduced. I input "test" in "replicas" field and it created successfully, the replicas is automatically set to 2. Checked on 4.6.0-0.nightly-2020-06-20-011219
Cannot reproduce in latest. Can we check this again. Maybe the release we checked didn't have my fix for some reason.
Could this be browser specific? What browser are you using xiaocwan ?
Checked on 4.6 cluster with payload 4.6.0-0.nightly-2020-07-05-192128. The result is the same with that in Comment 6. I will check again if I need open another bug. The issue for current bug has been fixed, so move it to Verified for now.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (OpenShift Container Platform 4.6 GA Images), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:4196