Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add before init is not fatal error #40

Open
rgamez opened this issue Mar 5, 2013 · 1 comment
Open

add before init is not fatal error #40

rgamez opened this issue Mar 5, 2013 · 1 comment
Labels

Comments

@rgamez
Copy link
Collaborator

rgamez commented Mar 5, 2013

if ~/.catho doesn't exist because catho init hasn't been executed, errors are displayed but the parsing of the directory continues.

$ ~/catho/catho/catho.py add Home ~
Creating catalog: Home
An error occurred: unable to open database file
An error occurred: unable to open database file
An error occurred: unable to open database file
$ ls ~/.catho
ls: cannot access ~/.catho: No such file or directory

Two options/suggestions @iemejia

  • It's a fatal error that ends with the suggestion of executing catho init.
  • ~/.catho it's "touched" before adding any catalog and perhaps any operation.
@iemejia
Copy link
Owner

iemejia commented Mar 5, 2013

both solutions are good, but what i would like is to avoid repeating is the touch code everywhere, or the validation error in case of not init executed (can we solve this in a general way?, maybe with a decorator?), for me touching the folder is better, and maybe that will make the init option to be useless. (less options = better)

@ghost ghost assigned rgamez Mar 5, 2013
@rgamez rgamez removed their assignment Apr 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants