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

Error Export Bokeh figure with Python 3.5 #979

Closed
hervo63 opened this issue Nov 8, 2016 · 2 comments
Closed

Error Export Bokeh figure with Python 3.5 #979

hervo63 opened this issue Nov 8, 2016 · 2 comments
Labels
tag: backend: bokeh type: bug Something isn't correct or isn't working
Milestone

Comments

@hervo63
Copy link

hervo63 commented Nov 8, 2016

Hi,

There is the following error when I am trying to export an HTML image with Python 3.5 (holoviews 1.6.2)

import numpy as np
import holoviews as hv
hv.notebook_extension(bokeh=True)

x,y = np.meshgrid(np.linspace(-5,5,101), np.linspace(5,-5,101))
test=hv.Raster(np.sin(x**2+y**2))

renderer = hv.Store.renderers['bokeh'].instance(fig='html');
renderer.save(test, 'example_I')

I have the following error:

renderer.save(test, 'example_I')
Traceback (most recent call last):

  File "<ipython-input-19-7e2a8a193726>", line 2, in <module>
    renderer.save(test, 'example_I')

  File "C:\Work\Anaconda\lib\site-packages\holoviews\plotting\renderer.py", line 467, in save
    f.write(encoded)

TypeError: a bytes-like object is required, not 'str'

it is working just fine on Python 2.7

Is there a work around for Python 3.5 ?
Thanks

@jlstevens
Copy link
Contributor

Thanks for reporting this!

It should definitely work the same on Python 3.5 as 2.7 so this is a bug.

@jlstevens jlstevens added the type: bug Something isn't correct or isn't working label Nov 8, 2016
@philippjfr philippjfr added this to the v1.7.0 milestone Dec 10, 2016
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
tag: backend: bokeh type: bug Something isn't correct or isn't working
Projects
None yet
Development

No branches or pull requests

3 participants