Skip to content

[BUG] #509

@NinetyNineBunny

Description

@NinetyNineBunny

Describe the bug
Unexpected error in rendering Lux widget and recommendations. Falling back to Pandas display.
Please report the following issue on Github: https://github.com/lux-org/lux/issues

To Reproduce
Please describe the steps needed to reproduce the behavior. For example:

  1. Using this data: df = ... csv from https://open.toronto.ca/dataset/parks-and-recreation-facilities/
  2. in miniconda3 pip install lux
  3. activate environment and read csv using pandas
  4. See error
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\core\frame.py", line 581, in ipython_display
    self.maintain_metadata()
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\core\frame.py", line 146, in maintain_metadata
    self.compute_metadata()
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\core\frame.py", line 126, in compute_metadata
    lux.config.executor.compute_dataset_metadata(self)
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\executor\PandasExecutor.py", line 448, in compute_dataset_metadata
    self.compute_data_type(ldf)
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\executor\PandasExecutor.py", line 506, in compute_data_type
    elif check_if_id_like(ldf, attr):
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\lux\utils\utils.py", line 104, in check_if_id_like
    diff = series.diff()
    ^^^^^^^^^^^^^
    File "c:\Users\username\miniconda3\envs\earth-analytics-python\Lib\site-packages\pandas\core\series.py", line 3120, in diff
    ...
    out_arr[res_indexer] = op(arr[res_indexer], arr[lag_indexer])
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    TypeError: unsupported operand type(s) for -: 'str' and 'float'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions