Skip to content

Commit

Permalink
Add r prefix to regular expression strings.
Browse files Browse the repository at this point in the history
The r prefix makes the string a raw string.

This isn't technically required, and has no real affect, however might
make future changes easier.

Change-Id: I69b767b112acf0fdbb5d3bc0ded47753d118bc29
  • Loading branch information
brianmay committed Feb 10, 2015
1 parent 1e9cf86 commit c20e3dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions karaage/conf/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@
}

# RE for validing a username.
USERNAME_VALIDATION_RE = '[-\w]+'
USERNAME_VALIDATION_RE = r'[-\w]+'

# Error to display if username validation failed.
USERNAME_VALIDATION_ERROR_MSG = six.u(
Expand All @@ -349,7 +349,7 @@
USERNAME_MAX_LENGTH = 255

# RE for validing a project.
PROJECT_VALIDATION_RE = '[-\w]+'
PROJECT_VALIDATION_RE = r'[-\w]+'

# Max length of a project identifier
PROJECT_ID_MAX_LENGTH = 255
Expand All @@ -360,7 +360,7 @@
'numbers and underscores')

# RE for validing a group id.
GROUP_VALIDATION_RE = '[-\w]+'
GROUP_VALIDATION_RE = r'[-\w]+'

# Error to display if group validation failed.
GROUP_VALIDATION_ERROR_MSG = six.u(
Expand Down

0 comments on commit c20e3dc

Please sign in to comment.