☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Dynamically changing GroupFilter.group does not update table view

Community Support
zsolt
zsolt

I am trying to use CDSView with a GroupFilter(…) instance in a DataTable. It looks like an awesome abstraction. But I have some trouble make it work for my dynamic case.

The initial view is properly filtered per my initial group specifier. I have a Select() widget which I wanted to use to control which group is displayed in the table. I tried both Python side and JS side linking, and I verified that the view’s group attribute gets updated. But the table does not update.

Is this supposed to work? Am I missing something? Bug? Unfinished feature?

Relevant code:

    options = sorted(df.col1.unique())
    select = Select(title='Please chose:', value=options[0], options=options)
    cds = ColumnDataSource(df)
    group_filter = GroupFilter(column_name='col1', group=select.value)
    view = CDSView(source=cds, filters=[group_filter])
    columns = [TableColumn(filter=n, title=n) for n in df.columns]
    table = DataTable(columns=columns, source=cds, view=view)

I tried to link the selection in the following two ways, none of them achieving an update to the table upon selection change:

Python side:

    select.on_change('value', lambda a, o, n: group_filter.update(group=n))

Browser side:

    select.js_link('value', group_filter, 'group')
⌁   Link to post
zsolt
zsolt

Yes, I looked at the code (filers.ts) since and there is no sign of any connect calls. I will write a ticket. May even try to fix it. Just wanted to be sure the intent is clear. I see Matt has reworked the code ~15d ago.

⌁   Link to post

End of archived discussion · Replies are disabled