Skip to content

Commit

Permalink
making sure leading/trailing whitespace is removed
Browse files Browse the repository at this point in the history
  • Loading branch information
PhillipsOwen committed Jul 11, 2023
1 parent 438a979 commit 458e871
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,9 @@ async def set_the_supervisor_component_image_version(image_repo: ImageRepo, job_
# create a regex pattern for the version number
version_pattern = re.compile(r"(v\d\.+\d\.+\d)")

# strip off any whitespace on the version
version = version.strip()

# makesure that the input params are legit
if version_pattern.search(version) or version.startswith('latest'):
# make the update. fix the job name (hyphen) so it matches the DB format
Expand Down

0 comments on commit 458e871

Please sign in to comment.