2 files changed
+2
-0
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
10 | 10 |
| |
11 | 11 |
| |
12 | 12 |
| |
| 13 | + | |
13 | 14 |
| |
14 | 15 |
| |
15 | 16 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
111 | 111 |
| |
112 | 112 |
| |
113 | 113 |
| |
| 114 | + | |
114 | 115 |
| |
115 | 116 |
| |
116 | 117 |
| |
|
4 commit comments
kayhayen commentedon Feb 7, 2015
Maybe better to use os.path.dirname(timestamp_path), as you are violating "DRY" there.
Kwpolska commentedon Feb 7, 2015
Why bother? We know
timestamp_path
is in the cache folder, we don’t plan to move it, better to just use this and call it a day.kayhayen commentedon Feb 7, 2015
Oh, I wasn't suggesting to change it. It's just that "knowing" comes into play when you repeat yourself, and that can be avoided. That is why "DRY" comes into play for me. Just a comment, no demand.
Seeing code:
os.makedirs(some_dirname)
open(some_filename, "w")
requires that the reader knows the relationship between some_file and some_dir. Using
os.makedirs(dirname(some_filename))
open(some_filename, "w")
on the other hand, is pretty much immediately recognizable.
Again, just a comment, because I looked at the commit. If code review is not welcome, make that clear some prominent place.
Kwpolska commentedon Feb 7, 2015
Code review is certainly welcome.