{"record":{"id":"ffb5848479f600d5","repo":"ory/kratos","slug":"unable-to-find-strategy-for-s-have-v-ffb584","errorCode":null,"errorMessage":"unable to find strategy for %s have %v","messagePattern":"unable to find strategy for (.+?) have (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"selfservice/flow/settings/strategy.go","lineNumber":44,"sourceCode":"type Strategy interface {\n\tSettingsStrategyID() string\n\tNodeGroup() node.UiNodeGroup\n\tPopulateSettingsMethod(context.Context, *http.Request, *identity.Identity, *Flow) error\n\tSettings(ctx context.Context, w http.ResponseWriter, r *http.Request, f *Flow, s *session.Session) (*UpdateContext, error)\n}\n\ntype Strategies []Strategy\n\nfunc (s Strategies) Strategy(id string) (Strategy, error) {\n\tids := make([]string, len(s))\n\tfor k, ss := range s {\n\t\tids[k] = ss.SettingsStrategyID()\n\t\tif ss.SettingsStrategyID() == id {\n\t\t\treturn ss, nil\n\t\t}\n\t}\n\n\treturn nil, errors.Errorf(`unable to find strategy for %s have %v`, id, ids)\n}\n\nfunc (s Strategies) MustStrategy(id string) Strategy {\n\tstrategy, err := s.Strategy(id)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn strategy\n}\n\n// StrategyFilter selects which Settings strategies to include when populating a flow.\ntype StrategyFilter func(strategy Strategy) bool\n\ntype StrategyProvider interface {\n\tSettingsStrategies(ctx context.Context, filters ...StrategyFilter) Strategies\n\tAllSettingsStrategies() Strategies\n}\n","sourceCodeStart":26,"sourceCodeEnd":62,"githubUrl":"https://github.com/ory/kratos/blob/b86338da04a040247a07f46100a86dcfb3875909/selfservice/flow/settings/strategy.go#L26-L62","documentation":"The settings flow's Strategies.Strategy compared its SettingsStrategyID string against every registered settings strategy and found no match. Like the login/registration variants, the error includes the available ids: the requested settings method simply is not registered in this instance.","triggerScenarios":"Thrown at selfservice/flow/settings/strategy.go:44 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Enable the corresponding selfservice method (e.g. profile, password, totp) in configuration","Use the 'have %v' list to verify which settings strategies are loaded","Check for typos in the strategy id being requested"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b86338da04a040247a07f46100a86dcfb3875909","analyzedAt":"2026-09-07T15:58:15.934Z","contentChangedAt":"2026-09-07T15:58:15.934Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}