Closed ollyhensby closed 2 years ago
Describe the bug When there's no data in the grid, the data getter produces an error.
To Reproduce Steps to reproduce the behavior:
from ipydatagrid import DataGrid import pandas as pd
df = pd.DataFrame([1], columns=["a"]) grid = DataGrid(df) grid
We get this output:
We can also call the data getter:
grid.data
grid.data = grid.data.drop(0)
We see that the DataGrid UI object reflects those changes (we only have the columns):
Expected behavior I expect an empty dataframe to be returned like this when calling the data getter:
Environment (please complete the following information):
Any help with this is much appreciated. Cheers!
Hello :wave: @ollyhensby and welcome to the ipydatagrid community! Many thanks for reporting - I'll get this fixed!
ipydatagrid
Closed via #358 Awesome work @ollyhensby 🙏 Thank you!
Describe the bug When there's no data in the grid, the data getter produces an error.
To Reproduce Steps to reproduce the behavior:
We get this output:
We can also call the data getter:
We see that the DataGrid UI object reflects those changes (we only have the columns):
Expected behavior I expect an empty dataframe to be returned like this when calling the data getter:
Environment (please complete the following information):
Any help with this is much appreciated. Cheers!