Skip to content

Inadvertent regular expression validation failures during global search #11555

@jeremystretch

Description

@jeremystretch

NetBox version

v3.4.3

Python version

3.8

Steps to Reproduce

  1. Create a site named "Site(1)"
  2. Search for "Site(" in global search (using the default "partial match" type)

Expected Behavior

The site should appear in the results list.

Observed Behavior

An exception is raised:

missing ), unterminated subpattern at position 0

This was originally resolved under #11516, but inadvertently reversed while solving for a related issue. The search term should be escaped when regex matching is not in play.

Metadata

Metadata

Assignees

Labels

status: acceptedThis issue has been accepted for implementationtype: bugA confirmed report of unexpected behavior in the application

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions