grafana/k6 · error

parsing element input value options

Error message

parsing element input value options: %w

What it means

Generic parse wrapper for elementHandle.inputValue: the options argument failed to decode into common.ElementHandleBaseOptions (a timeout). The wrapped error names the offending key — usually an unknown option or a non-numeric timeout.

Solutions

  1. Pass only { timeout: <number> } (milliseconds)
  2. Remove any unsupported option keys
  3. Omit the options argument to use the default timeout
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at internal/js/modules/k6/browser/browser/element_handle_mapping.go:119 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of grafana/k6@3fcf5388d7 (2026-09-14). Data as JSON: /api/errors/cc1e691676e6c26f. Report an issue: GitHub.

Appendix: source

Thrown at internal/js/modules/k6/browser/browser/element_handle_mapping.go:126

			}
			return promise(vu, func() (any, error) {
				return nil, eh.Hover(popts) //nolint:wrapcheck
			}), nil
		},
		"innerHTML": func() *sobek.Promise {
			return promise(vu, func() (any, error) {
				return eh.InnerHTML() //nolint:wrapcheck
			})
		},
		"innerText": func() *sobek.Promise {
			return promise(vu, func() (any, error) {
				return eh.InnerText() //nolint:wrapcheck
			})
		},
		"inputValue": func(opts sobek.Value) (*sobek.Promise, error) {
			popts := common.NewElementHandleBaseOptions(eh.DefaultTimeout())
			if err := parseElementHandleBaseOptions(popts, rt, opts); err != nil {
				return nil, fmt.Errorf("parsing element input value options: %w", err)
			}
			return promise(vu, func() (any, error) {
				return eh.InputValue(popts) //nolint:wrapcheck
			}), nil
		},
		"isChecked": func() *sobek.Promise {
			return promise(vu, func() (any, error) {
				return eh.IsChecked() //nolint:wrapcheck
			})
		},
		"isDisabled": func() *sobek.Promise {
			return promise(vu, func() (any, error) {
				return eh.IsDisabled() //nolint:wrapcheck
			})
		},
		"isEditable": func() *sobek.Promise {
			return promise(vu, func() (any, error) {
				return eh.IsEditable() //nolint:wrapcheck

View on GitHub (pinned to 3fcf5388d7)