projectdiscovery/nuclei · error

could not replace interactsh marker for argument %q: %w

Error message

could not replace interactsh marker for argument %q: %w

What it means

Error "could not replace interactsh marker for argument %q: %w" thrown in projectdiscovery/nuclei.

Source

Thrown at pkg/protocols/headless/engine/page_actions.go:1037

	case "r":
		return rod.SelectorTypeRegex
	case "css":
		return rod.SelectorTypeCSSSector
	case "regex":
		return rod.SelectorTypeRegex
	default:
		return rod.SelectorTypeText
	}
}

func (p *Page) getActionArg(action *Action, arg string) (string, error) {
	var err error

	argValue := action.GetArg(arg)

	prepared, err := render.ReplaceInteractshMarkers(argValue, p.instance.interactsh, nil)
	if err != nil {
		return "", fmt.Errorf("could not replace interactsh marker for argument %q: %w", arg, err)
	}
	argValue = prepared.Text

	exprs := getExpressions(argValue, p.variables)

	err = expressions.ContainsUnresolvedVariables(exprs...)
	if err != nil {
		return "", errkit.Wrapf(err, "argument %q, value: %q", arg, argValue)
	}

	result, err := render.Render(render.Input{
		Text:         argValue,
		Values:       p.variables,
		InteractURLs: prepared.InteractURLs,
	})
	if err != nil {
		return "", fmt.Errorf("could not get value for argument %q: %s", arg, err)
	}

View on GitHub (pinned to 265b3a3dec)

When it happens

Trigger: Thrown at pkg/protocols/headless/engine/page_actions.go:1037 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of projectdiscovery/nuclei@265b3a3dec (2026-08-15). Data as JSON: /api/errors/361dd29499be6487. Report an issue: GitHub.