Skip to content

Commit

Permalink
fixes #8, version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
timkpaine committed Sep 17, 2018
1 parent 09493e3 commit bd7923f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions jupyterlab_email/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
__version__ = '0.0.10'

from .nbconvert import run as run_nbconvert
from ._email import email as email_notebook
from .attachments import attach, latex
Expand All @@ -9,3 +7,5 @@ def _jupyter_server_extension_paths():
return [{
"module": "jupyterlab_email.extension"
}]

__version__ = '0.0.11'
5 changes: 4 additions & 1 deletion jupyterlab_email/attachments.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import pandas as pd
from IPython.display import HTML
from io import BytesIO

from html import escape

CUSTOM_TAG = 'jupyterlab_email_data'
EXCEL_ENGINE = 'xlsxwriter'
Expand All @@ -21,6 +21,9 @@ def attach(data, filename, type):
data.to_excel(writer)
writer.save()
data = base64.b64encode(io.getvalue()).decode('ascii')
elif type == 'html':
data = escape(data)

if type not in ('csv', 'tsv',
'png', 'pdf',
'xls', 'xlsx',
Expand Down
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@

setup(
name='jupyterlab_email',
version='0.0.10',
version='0.0.11',
description='Sending emails from JupyterLab',
long_description=long_description,
url='https://github.com/timkpaine/jupyterlab_email',
download_url='https://github.com/timkpaine/jupyterlab_email/archive/v0.0.10.tar.gz',
download_url='https://github.com/timkpaine/jupyterlab_email/archive/v0.0.11.tar.gz',
author='Tim Paine',
author_email='t.paine154@gmail.com',
license='Apache 2.0',
Expand Down

0 comments on commit bd7923f

Please sign in to comment.