miranov25 / RootInteractive

4 stars 12 forks source link

Bokeh3 migration #345

Closed pl0xz0rz closed 6 months ago

pl0xz0rz commented 7 months ago

This PR adds support for Bokeh 3.3.1. However, the changes are NOT back compatible, and I'll probably make another pull request with a few bug fixes that can go to a release before this migrations.

Will fix #296

miranov25 commented 6 months ago

There are problems in unit test:

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================================================================================== short test summary info ===============================================================================================================================
FAILED test_Compression.py::test_CompressionCDSPipeDraw - NameError: name 'linear_cmap' is not defined
FAILED test_bokehClientHistogram.py::testBokehClientHistogram - NameError: name 'linear_cmap' is not defined
FAILED test_bokehDrawSA.py::testBokehDrawArrayWidget - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayWidgetNoScale - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayDownsample - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayQuery - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_surface3d.py::test_Surface3d_select - AttributeError: unexpected attribute 'plot_width' to figure, similar attributes are outer_width, width or min_width
=============================================================================================================== 7 failed, 36 passed, 20 warnings in 507.58s (0:08:27) ================================================================================================================
miranov25 commented 6 months ago

still failures in the test:

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================================================================================== short test summary info ===============================================================================================================================
FAILED test_bokehDrawSA.py::testBokehDrawArrayWidget - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayWidgetNoScale - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayDownsample - AttributeError: 'Categorical' object has no attribute 'flags'
FAILED test_bokehDrawSA.py::testBokehDrawArrayQuery - AttributeError: 'Categorical' object has no attribute 'flags'
=============================================================================================================== 4 failed, 39 passed, 20 warnings in 596.79s (0:09:56) ================================================================================================================
miranov25 commented 6 months ago

Template is not autoscaling already in the test:

Example test: file:///Users/miranov25/lustre/alice/users/miranov/github/RootInteractive/RootInteractive/InteractiveDrawing/bokeh/test_histogramTemplateMultiDiff.html Example dashboard:

image
miranov25 commented 6 months ago

Migration to Bokeh 3.3.2

Summary

Actions

Notes

(venv7) Singularity> pytest -n 24
================================================================================================================================ test session starts =================================================================================================================================
platform linux -- Python 3.10.13, pytest-7.4.4, pluggy-1.3.0
rootdir: /u/miranov/github/RootInteractive
plugins: regressions-2.5.0, nbval-0.10.0, parallel-0.1.1, datadir-1.5.0, json-report-1.5.0, anyio-4.2.0, tornasync-0.6.0.post2, metadata-3.0.0, xdist-3.5.0
24 workers [43 items]
...........................................

==================================================================================================================== 43 passed, 180 warnings in 86.05s (0:01:26) ===========================================================================================
miranov25 commented 3 months ago

New bokeh used in master since #296