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

[BUG]: If raw text = cleaned text, app crashes #43

Closed
1 task done
Kostis-S-Z opened this issue Dec 5, 2024 · 0 comments · Fixed by #45
Closed
1 task done

[BUG]: If raw text = cleaned text, app crashes #43

Kostis-S-Z opened this issue Dec 5, 2024 · 0 comments · Fixed by #45
Labels
bug Something isn't working

Comments

@Kostis-S-Z
Copy link
Contributor

Description

If there is no cleaning to be done in the input text of the document, the app crashes.

Reproduction

  1. Run demo app
  2. Create empty file file.md and inside write This is an example
  3. Upload file to app
  4. Crash

Relevant log output

DuplicateWidgetID: There are multiple identical st.text_area widgets with the same generated key.

When a widget is created, it's assigned an internal key based on its structure. Multiple widgets with an identical structure will result in the same internal key, which causes this error.

To fix this error, please pass a unique key argument to st.text_area.
Traceback:

File "/.../demo/app.py", line 81, in <module>
    st.text_area(f"Total Length: {len(clean_text)}", f"{clean_text[:500]} . . .")

Expected behavior

Not to crash

System Info

  • OS: Ubuntu
  • Branch: main

Have you searched for similar issues before submitting this one?

  • Yes, I have searched for similar issues
@Kostis-S-Z Kostis-S-Z added the bug Something isn't working label Dec 5, 2024
@Kostis-S-Z Kostis-S-Z linked a pull request Dec 6, 2024 that will close this issue
3 tasks
@daavoo daavoo closed this as completed in #45 Dec 9, 2024
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

Successfully merging a pull request may close this issue.

1 participant