Skip to content

FileUpload counter with multiple=False #2480

Closed
@jtpio

Description

@jtpio

It looks a bit odd that the FileUpload counter is increasing every time a file is uploaded, even when multiple=False is set:

fileupload-counter

When multiple=False is set shouldn't the counter equal to 1?

Can be tested with:

from ipywidgets import FileUpload, Output

out = Output()

@out.capture()
def show_content(change):
    print(change['new'].keys())

w = FileUpload(multiple=False)
w.observe(show_content, 'value')
with out:
    display(w)
out

Metadata

Metadata

Assignees

No one assigned

    Labels

    resolved-lockedClosed issues are locked after 30 days inactivity. Please open a new issue for related discussion.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions