Commit 550e5c19 by Saikiran Srirangapalli

Merge branch 'errorhandle'

parents 1935cba7 26c48ba9
......@@ -22,7 +22,7 @@ class ExecutionError(Exception):
class GASResponse(object):
""" GAS advising information """
_missing_class_re = r'hasNotTaken\({},([a-z]+[1-4][0-9V][0-9][0-9])\)'
_missing_hours_re = r'needsHours\({},([a-zA-Z]+),([0-9]+)\)'
_missing_hours_re = r'needsHours\({},([^)]+),([0-9]+)\)'
_missing_electives_re = r'needsElectiveHours\({},([0-9]+)\)'
_grad = r'ableToGraduate\({}\)'
......
......@@ -47,5 +47,5 @@ def submit():
@app.errorhandler(500)
def exc(err):
error_list = str(err).split("\n")
return render_template('GASErrorTemplate.html',error_message = error_list)
error_list = str(err).split("\n")
return render_template('GASErrorTemplate.html', error_message=error_list)
Subproject commit 5f8c28d719d551f92e420e911aba409ee1bffde2
Subproject commit 47e95ec823a94da5f6c60d5186ce0f45d8f45aff
......@@ -9,11 +9,11 @@ import sys
def main():
with open('listOfCourses.txt', 'r') as file:
courses = re.findall('[a-z]+[0-9][0-9V][0-9]{2}', file.read())
print(courses)
with open('htmlCourses.txt', 'w') as file:
for course in courses:
file.write('<option value="%s">\n' % course)
with open('listOfCourses.txt', 'r') as file:
courses = re.findall('[a-z]+[0-9][0-9V][0-9]{2}', file.read())
print(courses)
with open('htmlCourses.txt', 'w') as file:
for course in courses:
file.write('<option value="%s">\n' % course)
if __name__ == '__main__':
main()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment