develmaycare / pyprojectutils

A collection of documentation and command line utilities for managing a software project.
BSD 3-Clause "New" or "Revised" License
1 stars 1 forks source link

TemplateNotFound on Init Project #97

Closed develmaycare closed 7 years ago

develmaycare commented 7 years ago

I suspect this error will be raised for each of the files that rely on a template. Path issue, probably.

Traceback (most recent call last):
  File "/usr/local/bin/initproject", line 9, in <module>
    load_entry_point('pyprojectutils==0.35.0-d', 'console_scripts', 'initproject')()
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyprojectutils/cli.py", line 1396, in init_project_command
    if project.initialize(templates=templates):
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyprojectutils/library/projects.py", line 1051, in initialize
    content = parse_jinja_template(templates.get('gitignore', GITIGNORE_TEMPLATE), context)
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pyprojectutils/library/shortcuts.py", line 208, in parse_jinja_template
    template = env.get_template(template_name)
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/jinja2/environment.py", line 830, in get_template
    return self._load_template(name, self.make_globals(globals))
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/jinja2/environment.py", line 804, in _load_template
    template = self.loader.load(self, name, globals)
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/jinja2/loaders.py", line 113, in load
    source, filename, uptodate = self.get_source(environment, name)
  File "/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/jinja2/loaders.py", line 187, in get_source
    raise TemplateNotFound(template)
jinja2.exceptions.TemplateNotFound: gitignore.j2