Raise exception when org file not found

- No need to catch the IOError in OrgNode
This commit is contained in:
Debanjum Singh Solanky
2022-09-11 01:09:24 +03:00
parent c415af32d5
commit e951ba37ad
2 changed files with 15 additions and 6 deletions

View File

@@ -57,12 +57,7 @@ def makelist(filename):
"""
ctr = 0
try:
f = open(filename, 'r')
except IOError:
print(f"Unable to open file {filename}")
print("Program terminating.")
sys.exit(1)
f = open(filename, 'r')
todos = { "TODO": "", "WAITING": "", "ACTIVE": "",
"DONE": "", "CANCELLED": "", "FAILED": ""} # populated from #+SEQ_TODO line