nwb-extensions/ndx-template

Allow fix of errors

Closed this issue · 2 comments

Thanks for the nice template. I tried to create an extension to work on the ICEphys extension and ran into a problem (or rather an inconvenience). When running cookiecutter as follows:

 cookiecutter gh:nwb-extensions/ndx-template
namespace [ndx-my-namespace]: icephys_meta_struct            
description [An NWB:N extension]: Implement proposal for hierarchical metadata strucutre for intracellular electrophysiology data  
author [My Name]: Oliver Ruebel, Ryan Ly, Benjamin Dichter, Thomas Braun, Andrew Tritt
email [my_email@example.com]: oruebel@lbl.gov
github_username [myname]: oruebel
copyright [2019, Oliver Ruebel, Ryan Ly, Benjamin Dichter, Thomas Braun, Andrew Tritt]: 
version [0.1.0]: 
release [alpha]: 
license [BSD 3-Clause]: 
py_pkg_name [icephys_meta_struct]: 

It errors out with the following message:

ERROR: The name of your NDX extension should start with "ndx-".
ERROR: Stopping generation because pre_gen_project hook script didn't exit successfully
Hook script failed (exit status: 1)

While this behavior is correct, it would be nice to either get the warning at the beginning when the error occurs so that one can enter a correct name, rather than having to rerun the script an renter the corrected information. Again, this is not a priority, I just figured I should at least create an issue so we don't forget.

@rly feel free to close if this would be too hard to fix.

rly commented

This is not yet fixed, but I'm working on it.