Relevant Versions: Bokeh 2.2.3, Python 3.8.5, Mac OSX Big Sur
Issue Summary: A complex data analysis and visualization app includes some functionality to patch source data used for UIs and plots based on user selections.
The very first time one of these patch actions occurs on a data source, the Python terminal for the bokeh shows a warning related to Pandas dataframes and setting-with-copy. See below for log info.
/Users/x/opt/anaconda3/lib/python3.8/site-packages/bokeh/core/property/wrappers.py:463: SettingWithCopyWarning:
A value is trying to be set on a copy of a slice from a DataFrame
See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy
self[name][ind] = value
The referenced line number (wrappers.py:463) confirms other debugging steps that this is happening in the bokeh patch operation. Despite the warning, the code appears to work as expected.
The warning does not appear on any subsequent interactions or patching operations.
My data setup does include as Pandas dataframe, which is wrapped in ColumnDataSource() for the plots and UIs that require access. I did try to change this to a dict instead, but still encountered the error.
Unfortunately, I have not been able to generate a smaller example to expose the observed behavior.
