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

Bad strftime format, for windows, in nbconvert exporter #3719

Closed
jstenar opened this issue Jul 22, 2013 · 1 comment
Closed

Bad strftime format, for windows, in nbconvert exporter #3719

jstenar opened this issue Jul 22, 2013 · 1 comment

Comments

@jstenar
Copy link
Member

jstenar commented Jul 22, 2013

%-d is not a valid strftime format on windows.

C:\Users\jorgenst\notebooks> ipython nbconvert --format=basic_html .\Simple_pylab.ipynb
Traceback (most recent call last):
  File "c:\Python27\Scripts\ipython-script.py", line 8, in <module>
    load_entry_point('ipython==1.0dev', 'console_scripts', 'ipython')()
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\__init__.py", line 118, in start_ipython
    return launch_new_instance(argv=argv, **kwargs)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\config\application.py", line 539, in launch_instance
    app.start()
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\terminal\ipapp.py", line 362, in start
    return self.subapp.start()
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\nbconvertapp.py", line 176, in start
    self.convert_notebooks()
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\nbconvertapp.py", line 197, in convert_notebooks
    config=self.config)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 61, in decorator
    return f(*args, **kwargs)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 214, in export_by_name
    return globals()[function_name](nb, **kw)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 61, in decorator
    return f(*args, **kwargs)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 149, in export_basic_html
    return export(BasicHTMLExporter, nb, **kw)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 61, in decorator
    return f(*args, **kwargs)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\export.py", line 122, in export
    output, resources = exporter_instance.from_filename(nb, resources)
  File "c:\python27\lib\site-packages\ipython-1.0dev-py2.7.egg\IPython\nbconvert\exporters\exporter.py", line 218, in from_filename
    resources['metadata']['modified_date'] = modified_date.strftime("%B %-d, %Y")
ValueError: Invalid format string

If you suspect this is an IPython bug, please report it at:
    https://github.com/ipython/ipython/issues
or send an email to the mailing list at ipython-dev@scipy.org

You can print a more detailed traceback right now with "%tb", or use "%debug"
to interactively debug it.

Extra-detailed tracebacks for bug-reporting purposes can be enabled via:
    c.Application.verbose_crash=True
jstenar added a commit to jstenar/ipython that referenced this issue Jul 22, 2013
%-d is not a valid strftime format on windows.
@llawall
Copy link

llawall commented Jul 22, 2013

@jstenar beat me to it - I saw this too and confirm that his fix corrects the problem

@minrk minrk closed this as completed in 8d0a6b7 Jul 27, 2013
mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this issue Nov 3, 2014
%-d is not a valid strftime format on windows.
mattvonrocketstein pushed a commit to mattvonrocketstein/ipython that referenced this issue Nov 3, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants