You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been iterating on some code. The errors that are coming from ui are complete misdirections. Below I have some broken code plus the error that came with it. I made some changes towards resolving the problem, and then I get a different cryptic error. In the end, my code was completely broken, and it had to do with passing in the wrong number of arguments and doing other dumb things. If you iterate through trying to fix the code below, you will see that the error messages are complete misdirections for the user.
Code:
# TODO: pydocimportloggingfromtypingimportTuple, Callable, Anyfromdeephavenimportui, dtypesfromdeephaven.tableimportTable, PartitionedTablefromdeephaven.plot.figureimportFigure# This function is to avoid UI bugs in rendering tables with non-primitive columns# TODO: https://github.com/deephaven/deephaven-plugins/issues/701# TODO: https://github.com/deephaven/deephaven-core/issues/5708def_retain_primitive_cols(name: str, table: Table) ->Table:
"""Return a new table with only primitive columns. This function is to avoid UI bugs in rendering tables with non-primitive columns. Args: name (str): The name of the table. table (Table): The table to filter. """defretain_col(col):
retain=col.data_type.is_primitiveorcol.data_typein [dtypes.string, dtypes.bool_, dtypes.Instant]
ifnotretain:
logging.warning(f"REMOVING COLUMN FOR VISUALIZATION: table={name} column={col.name} type={col.data_type}.")
returnretainreturntable.view([col.nameforcolintable.columnsifretain_col(col)])
defnull_note(t: Table, note: str, func: Callable[[], Any]) ->Any:
""" Return a note if the table is empty; otherwise, return the element from the function. """returnfunc() iftelseui.text(note)
# TODO: this is commented out because it fails if it is not# @ui.componentdef_symbol_picker(table: PartitionedTable, label: str="Symbol") ->Tuple[ui.Element, str]:
symbol_table=ui.use_memo(lambda: table.table.view("symbol").select_distinct().sort("symbol"), [])
symbol, set_symbol=ui.use_state("")
pick_table=ui.picker(
symbol_table,
label=label,
on_change=set_symbol,
selected_key=symbol,
)
text=ui.text_field(
value=symbol,
on_change=set_symbol,
label=label,
)
returnui.flex(pick_table, text), symbol@ui.componentdef_tab_table_view(tables: dict[str, PartitionedTable], symbol: str) ->ui.BaseElement:
defmake_component(table):
t=table.get_constituent([symbol])
returnnull_note(t, f"No data for {symbol}", lambda: t)
returnui.stack([ui.panel(make_component(table), title=name) forname, tableintables.items()])
@ui.componentdefplot_shares(shares: Table) ->Figure:
p=Figure()
forcolinshares.columns:
if"shares_"incol.nameand"dilution_factor"notincol.name:
p=p.plot_xy(col.name, shares, x="timestamp", y=col.name)
returnp.show()
@ui.componentdefplot_prices(prices: Table) ->Figure:
return (
Figure()
.plot_xy("close_split_div_adj", prices, x="timestamp", y="close_split_div_adj")
.y_axis(log=True)
.show()
)
@ui.componentdefplot_fundamentals(fundamentals: Table, series: str):
return (
Figure()
.plot_xy(series, fundamentals, x="timestamp", y=series)
.show()
)
@ui.componentdefplot_model_preds(model_preds: Table, symbol: str, active: bool) ->Figure:
#TODO: get rid of active as an input?mp=model_preds.where("active"ifactiveelse"!active")
ifmp.size==0:
returnui.text(f"No {'active'ifactiveelse'inactive'} model predictions for {symbol}")
mp=mp.update_view([
"pred_price_sdp = pred_price + pred_price_stdev_uncorr", # TODO: which stdev?"pred_price_sdm = pred_price - pred_price_stdev_uncorr", # TODO: which stdev?
])
p=Figure()
p=p.plot_xy("Pred", t=mp, x="pred_time", y="pred_price",
y_low="pred_price_sdm", y_high="pred_price_sdp", by=["full_name"])
# # TODO: *** meta_preds# # TODO: select meta pred# meta = (# meta_preds# .where(["stdev_calc == `uncorr`", "meta_weights_func == `sd`"])# .update_view([# "pred_price_sdp = pred_price + pred_price_stdev",# "pred_price_sdm = pred_price - pred_price_stdev",# ]))# # p = p.plot_xy("Meta", t=meta, x="pred_time", y="pred_price", y_low="pred_price_sdm", y_high="pred_price_sdp") #TODO: add full name?, by=["full_name"])p=p.y_axis(log=True)
returnp.show()
@ui.componentdefplot_meta_preds(meta_preds: Table, symbol: str) ->Figure:
ifmeta_preds.size==0:
returnui.text(f"No {'active'ifactiveelse'inactive'} meta predictions for {symbol}")
meta= (
meta_preds
.where(["stdev_calc == `uncorr`", "meta_weights_func == `sd`"])
.update_view([
"full_name = stdev_calc + ` ` + meta_weights_func",
"pred_price_sdp = pred_price + pred_price_stdev",
"pred_price_sdm = pred_price - pred_price_stdev",
])
)
p=Figure()
p=p.plot_xy("Meta", t=meta, x="pred_time", y="pred_price", y_low="pred_price_sdm", y_high="pred_price_sdp", by=["full_name"])
p=p.y_axis(log=True)
returnp.show()
@ui.componentdef_input_plots(tables: dict[str, PartitionedTable], symbol: str) ->ui.BaseElement:
# TODO: this doesn't work --> need to have calls to the same number of hooks# if not symbol:# return ui.panel(ui.text("Select a symbol"))# TODO: filter on dateshares=tables["shares"].get_constituent([symbol])
prices=tables["prices"].get_constituent([symbol])
fundamentals=tables["fundamentals"].get_constituent([symbol])
model_preds=tables["model_preds"].get_constituent([symbol])
meta_preds=tables["meta_preds"].get_constituent([symbol])
error_msg=f"No data for {symbol}"outputs= []
outputs.append(ui.panel(null_note(shares, error_msg, lambda: plot_shares(shares)), title="shares"))
outputs.append(ui.panel(null_note(prices, error_msg, lambda: plot_prices(prices)), title="prices"))
forcolintables["fundamentals"].constituent_table_columns:
ifcol.namein ["date", "timestamp", "symbol"]:
continueoutputs.append(ui.panel(null_note(fundamentals, error_msg, lambda: plot_fundamentals(fundamentals, col.name)), title=col.name))
outputs.append(ui.panel(null_note(model_preds, error_msg, lambda: plot_model_preds(model_preds, meta_preds, symbol, active=True)), title="model_preds_active"))
outputs.append(ui.panel(null_note(model_preds, error_msg, lambda: plot_model_preds(model_preds, meta_preds, symbol, active=False)), title="model_preds_inactive"))
outputs.append(ui.panel(null_note(meta_preds, error_msg, lambda: plot_meta_preds(meta_preds, symbol)), title="meta_preds"))
returnui.stack(
*outputs,
)
@ui.componentdefmy_panel(tables: dict[str, PartitionedTable]) ->ui.BaseElement:
model_preds=tables["model_preds"]
symbol_picker, symbol=_symbol_picker(model_preds, label="Symbol")
# TODO: thinks this should be fine --> Doesn't work because new stuff is garbage at the bottom# if not symbol:# return ui.column(symbol_picker)ttv=_tab_table_view(tables, symbol)
ip=_input_plots(tables, symbol)
returnui.column(
symbol_picker,
ttv,
ip,
)
defmy_dashboard(tables: dict[str, Table]) ->ui.DashboardElement:
part_tables= {name: _retain_primitive_cols(name, table).partition_by("symbol") forname, tableintables.items()}
returnui.dashboard(my_panel(part_tables)) # TODO: Bad type hint or should failif__name__=="__main__":
fromcecropia.lynchmungerimportcliglobals().update(cli.debug_values)
dashboard=my_dashboard(cli.debug_values)
Error:
TypeError
plot_model_preds() got multiple values for argument 'active'
Traceback (most recent call last):
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/object_types/ElementMessageStream.py", line 189, in _render
node = self._renderer.render(self._element)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 153, in render
return _render_element(element, self._context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 27, in _render_child_item
return _render_list(item, parent_context.get_child_context(index_key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 68, in _render_list
_render_child_item(value, context, str(key))
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 27, in _render_child_item
return _render_list(item, parent_context.get_child_context(index_key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 68, in _render_list
_render_child_item(value, context, str(key))
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 120, in _render_element
props = element.render(context)
^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/elements/FunctionElement.py", line 43, in render
children = self._render()
^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/components/make_component.py", line 23, in <lambda>
return FunctionElement(component_type, lambda: func(*args, **kwargs), key=key)
^^^^^^^^^^^^^^^^^^^^^
TypeError: plot_model_preds() got multiple values for argument 'active'
Screenshot:
NameError
name 'active' is not defined
Traceback (most recent call last):
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/object_types/ElementMessageStream.py", line 189, in _render
node = self._renderer.render(self._element)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 153, in render
return _render_element(element, self._context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 27, in _render_child_item
return _render_list(item, parent_context.get_child_context(index_key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 68, in _render_list
_render_child_item(value, context, str(key))
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 27, in _render_child_item
return _render_list(item, parent_context.get_child_context(index_key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 68, in _render_list
_render_child_item(value, context, str(key))
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 123, in _render_element
props = _render_dict_in_open_context(props, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 103, in _render_dict_in_open_context
return {key: _render_child_item(value, context, key) for key, value in item.items()}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 45, in _render_child_item
return _render_element(item, parent_context.get_child_context(key))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/renderer/Renderer.py", line 120, in _render_element
props = element.render(context)
^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/elements/FunctionElement.py", line 43, in render
children = self._render()
^^^^^^^^^^^^^^
File "/Users/chip/dev/ccpy/venv3.12-v2/lib/python3.12/site-packages/deephaven/ui/components/make_component.py", line 23, in <lambda>
return FunctionElement(component_type, lambda: func(*args, **kwargs), key=key)
^^^^^^^^^^^^^^^^^^^^^
File "<string>", line 100, in plot_model_preds
NameError: name 'active' is not defined
The text was updated successfully, but these errors were encountered:
I've been iterating on some code. The errors that are coming from
ui
are complete misdirections. Below I have some broken code plus the error that came with it. I made some changes towards resolving the problem, and then I get a different cryptic error. In the end, my code was completely broken, and it had to do with passing in the wrong number of arguments and doing other dumb things. If you iterate through trying to fix the code below, you will see that the error messages are complete misdirections for the user.Code:
Error:
Screenshot:
The text was updated successfully, but these errors were encountered: