Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Hideable columns disappear after pasting data into table? #611

Closed
chriddyp opened this issue Oct 2, 2019 · 2 comments · Fixed by #621
Closed

Hideable columns disappear after pasting data into table? #611

chriddyp opened this issue Oct 2, 2019 · 2 comments · Fixed by #621
Assignees
Labels
dash-type-bug Something isn't working as intended size: 1
Milestone

Comments

@chriddyp
Copy link
Member

chriddyp commented Oct 2, 2019

as per https://community.plot.ly/t/hideable-columns-disappear-after-pasting-data-into-table/29342

i haven't attempted to reproduce this.

@alexcjohnson
Copy link
Collaborator

possible duplicate of #576

@alexcjohnson alexcjohnson added the dash-type-bug Something isn't working as intended label Oct 3, 2019
@alexcjohnson
Copy link
Collaborator

Still an existing bug, not a duplicate of #576, though I bet it's the same underlying issue repeated in a different part of the code.

  • run the app below
  • hide some columns
  • paste new data into the table
  • hidden columns are gone
import dash
from dash_table import DataTable

app = dash.Dash(__name__)

app.layout = DataTable(
    columns=[{
        'name': x,
        'id': x,
        'hideable': True,
        'clearable': True,
        'deletable': True
    } for x in ['a', 'b', 'c', 'd']],
    editable=True,
    include_headers_on_copy_paste=True,  # or False, same bug
    data=[{
        'a': 'a' + str(x),
        'b': 'b' + str(x) + str(x),
        'c': 'c' + str(x) + 'c',
        'd': 'd' + str(x) + '-' + str(x)
    } for x in range(0, 100)]
)

if __name__ == '__main__':
    app.run_server(debug=True)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
dash-type-bug Something isn't working as intended size: 1
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants