Open flanabode opened 1 year ago
@flanabode Please provide all relevant version information
@bryevdv I'll provide everything I can on Monday. Off the top of my head, I know that I'm running 3.0.4 of jupyter_bokeh because my notebook uses modules that break if I have ipywidgets 8 installed. FWIW, in my notebook I have overwritten the function call in question and can confirm that it works if the Boolean argument is labeled, but I hate running things with a bespoke patch.
Here's the requested version information: Python 3.10.6 bokeh 3.0.2 jupyter_bokeh 3.0.4 Jupyter 1.21.0
Can also confirm that I get the same error with jupyter_bokeh 3.0.5, and that it occurs regardless of whether I'm using JupyterLab or classic notebook.
Right, there are definitely still updates required for Bokeh 3.x compatibility, probably over and above this if I had to guess. But if you'd like to submit a PR for the change you describe above, that would be a helpful start.
cc @ndmlny-qs
This issue was fixed in PR https://github.com/bokeh/jupyter_bokeh/pull/165. However, jupyter_bokeh
compatible with bokeh 3 was never released due to issues with ipywidgets 8. That was fixed in jupyter_widgets
3.0.5 (2.4 only). I started PR https://github.com/bokeh/jupyter_bokeh/pull/178 to prepare for 3.0.6 relase.
Excellent, so no need for a PR from me, then?
@flanabode seems not, thanks!
I'm running into the same TypeError: standalone_docs_json_and_render_items() takes 1 positional argument but 2 were given
error.
EDIT: I noticed that for some reason jupyter_bokeh
was 2.0.4, reinstalling it while adding a >=3
constraint seems to fix the issue.
Good afternoon!
For the past several days, I have been getting the following error when trying to instantiate a BokehModel from jupyter_bokeh:
(docs_json, [render_item]) = standalone_docs_json_and_render_items([model], True) TypeError: standalone_docs_json_and_render_items() takes 1 positional argument but 2 were given.
That function (from bokeh.embed.util) is called when the BokehModel instantiation runs the following line from update_from_model: self.render_bundle = self._model_to_traits(model)
Looking at the documentation for standalone_docs_json_and_render_items, the function setup is:
standalone_docs_json_and_render_items(models: 'Model | Document | Sequence[Model | Document]', *, suppress_calback_warning: 'bool' = False)
It seems to me that the issue could be fixed by just having the function call label the Boolean argument like so:
(docs_json, [render_item]) = standalone_docs_json_and_render_items([model], suppress_callback_warning=True)
If you agree that this would fix the issue without causing any problems, it would be much, much appreciated!