Skip to content

RegexTextExtractor - set return_empty_on_no_match default value to False #10252

@anakin87

Description

@anakin87

In #10152, the return_empty_on_no_match init parameter was added to RegexTextExtractor with a default value of True.

We also added a DeprecationWarning:

"Warning: In an upcoming release, the output when no matches are found will change from "
"'{}' to {'captured_text': "
"}"

While I would have preferred to handle #10105 with a small breaking change and always return {"captured_text": ...}, we now have to follow our deprecation policy and set return_empty_on_no_match default value to False on 2.22.0.
We should also remove the captured_texts=list[str] output edge, which is never populated.

Metadata

Metadata

Assignees

Labels

P1High priority, add to the next sprint

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions