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

Do a bit more defensive programming #4

Open
vmbrasseur opened this issue Jun 13, 2014 · 0 comments
Open

Do a bit more defensive programming #4

vmbrasseur opened this issue Jun 13, 2014 · 0 comments
Labels

Comments

@vmbrasseur
Copy link
Owner

For example:

def create_dir(basedir, identifier):
  newdir = basedir + "/" + identifier
  if os.path.exists(newdir):
    verboseout(newdir + " already exists. Not creating")
  else:
    verboseout(" Going to create" + newdir)
    os.makedirs(newdir) #XXX confirm this worked
    verboseout(newdir + " created")
  return newdir

There are several places in the code where some try/catch action ought to happen to make things a bit more robust.

@vmbrasseur vmbrasseur added the bug label Jun 13, 2014
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

1 participant