Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

callbacks on fileNames are not triggered #1

Closed
drahnreb opened this issue May 11, 2020 · 1 comment
Closed

callbacks on fileNames are not triggered #1

drahnreb opened this issue May 11, 2020 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@drahnreb
Copy link

pip list | grep 'dash'

dash 1.11.0
dash-bootstrap-components 0.10.0
dash-core-components 1.9.1
dash-html-components 1.0.3
dash-renderer 1.4.0
dash-table 4.6.2
dash-uploader 0.1.0

The display_files-function of the MWE is not called after each upload.
It does work for the first time, but any successive call won't update the Output.

Files are uploaded to UPLOAD_FOLDER and the Complete Label is also changed.

Strangely it seems like no component prop is changed though.

@fohrloop fohrloop self-assigned this May 13, 2020
@fohrloop fohrloop added the bug Something isn't working label May 13, 2020
@fohrloop
Copy link
Owner

Thanks for reporting the issue! If I understood correctly, the problem was in python, the fileNames is a list which will not "change" (the id is the same), if a string is appended into it. Therefore, I added another property isCompleted that is a boolean and tells when the upload is complete. The fileNames is still a list of strings. Maybe someday there will be a possibility for the user to select multiple files to be uploaded. Until then, the length of the fileNames will always be one.

I put the changes into the v.0.1.1 (commit 1ea6096) and updated the example in the README.md.

Hope it works for you now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants