Skip to content

Commit

Permalink
[feat/#72] Fix: file_path for getValueAndTime
Browse files Browse the repository at this point in the history
  • Loading branch information
NayeonKeum committed Aug 27, 2023
1 parent f9edb17 commit c88eedc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ start=`date +%s.%N`
finish=`date +%s.%N`
diff=$( echo "$finish - $start" | bc -l )

echo $diff > time.txt
/usr/bin/echo $diff > time.txt
5 changes: 3 additions & 2 deletions resources/images/professor-ubuntu/server/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,11 +77,12 @@ async def get_assignment(id: str, assignment_id: str):
file_list = os.listdir(dir_path)
return_dict = {}
for file in file_list:
f = open(dir_path+"/"+file, "r")
file_path=dir_path+"/"+file
f = open(file_path, "r")
content = f.read()
return_dict["content"] = content
f.close()
os.system('/bin/bash %s/getValueAndTime.sh' % curr_path)
os.system('/bin/bash %s/getValueAndTime.sh %s' % (curr_path, file_path))
f = open("%s/values.txt" % curr_path, "r")
values = f.read()
return_dict["values"] = values
Expand Down

0 comments on commit c88eedc

Please sign in to comment.