Browse Source

UrlLib

pull/3/head
Jure Šorn 5 years ago
parent
commit
c516db0907
1 changed files with 2 additions and 8 deletions
  1. 10
      README.md

10
README.md

@ -1268,15 +1268,9 @@ with pycallgraph.PyCallGraph(output=graph):
#### Utility code for unique PNG filenames:
```python
def get_filename():
time_str = get_current_datetime_string()
from datetime import datetime
time_str = datetime.now().strftime('%Y%m%d%H%M%S')
return f'profile-{time_str}.png'
def get_current_datetime_string():
now = datetime.datetime.now()
return get_datetime_string(now)
def get_datetime_string(a_datetime):
return a_datetime.strftime('%Y%m%d%H%M%S')
```

Loading…
Cancel
Save