def _stage_from_version(version):
if version:<EOL><INDENT>m = re.match(r"<STR_LIT>", version)<EOL>if m:<EOL><INDENT>return "<STR_LIT>" if m.group("<STR_LIT>") else "<STR_LIT>"<EOL><DEDENT><DEDENT>return "<STR_LIT>"<EOL>
return "prd", "stg", or "dev" for the given version string.  A value is always returned