Skip to content

Commit 97e1742

Browse files
committed
updating time stamp
1 parent 678977d commit 97e1742

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

app.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
import redis
4545
from molmass import Formula
4646
from pyteomics import mass
47+
from datetime import datetime
4748

4849
# Project Imports
4950

@@ -3053,6 +3054,11 @@ def create_link(usi, usi2, xic_mz, xic_formula, xic_peptide,
30533054
import copy
30543055
to_save_settings = copy.deepcopy(full_json_settings)
30553056
to_save_settings["ip"] = request.remote_addr
3057+
3058+
now = datetime.now()
3059+
date_time = now.strftime("%m/%d/%Y, %H:%M:%S")
3060+
to_save_settings["timestamp"] = date_time
3061+
30563062
with open(log_filename, "w") as o:
30573063
o.write(json.dumps(to_save_settings))
30583064
except:

0 commit comments

Comments
 (0)